<!DOCTYPE html>
<html lang="en-US">

  <head>
    <meta charset='utf-8'>
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width,maximum-scale=2">
    <link rel="stylesheet" href="assets/css/style.css?v=">
    <script src="https://code.jquery.com/jquery-3.3.0.min.js" integrity="sha256-RTQy8VOmNlT6b2PIRur37p6JEBZUE7o8wPgMvu18MC4=" crossorigin="anonymous"></script>
    <script src="assets/js/main.js"></script>
<!-- Begin Jekyll SEO tag v2.6.1 -->
<title>BIRDS | Bidirectional Transformation for Relational View Update Datalog-based Strategies</title>
<meta name="generator" content="Jekyll v4.0.0" />
<meta property="og:title" content="BIRDS" />
<meta property="og:locale" content="en_US" />
<meta name="description" content="Bidirectional Transformation for Relational View Update Datalog-based Strategies" />
<meta property="og:description" content="Bidirectional Transformation for Relational View Update Datalog-based Strategies" />
<meta property="og:site_name" content="BIRDS" />
<script type="application/ld+json">
{"@type":"WebPage","url":"/cli-installation.html","headline":"BIRDS","description":"Bidirectional Transformation for Relational View Update Datalog-based Strategies","@context":"https://schema.org"}</script>
<!-- End Jekyll SEO tag -->

  </head>

  <body>

    <!-- HEADER -->
    <div id="header_wrap" class="outer">
        <header class="inner">
          
            <a id="forkme_banner" href="https://github.com/dangtv/BIRDS">View on GitHub</a>
          
          <a id="project_title" href="/BIRDS">BIRDS</a>
           <!-- <h1 id="project_title">  BIRDS </h1>  -->
          <h2 id="project_tagline">Bidirectional Transformation for Relational View Update Datalog-based Strategies</h2>

          
        </header>
    </div>

    <!-- MAIN CONTENT -->
    <div id="main_content_wrap" class="outer, wrapper">
      <div class="inner">
          <nav>
              <h3>Contents</h3>
              <ul></ul>
            </nav>
        <section id="main_content">
          <h1 id="birds-command-line-tool">BIRDS Command Line Tool</h1>

<h2 id="installation">Installation</h2>

<ul>
  <li>It is necessary to install external tools including Lean &gt;= 3.4.1 and Z3 &gt;= 4.7.1 before installing the command line tool <code class="highlighter-rouge">birds</code>.</li>
  <li>The tool <code class="highlighter-rouge">birds</code> can be downloaded at <a href="https://github.com/dangtv/BIRDS/releases">https://github.com/dangtv/BIRDS/releases</a>,
<!-- * [For Macosx](https://github.com/dangtv/BIRDS/releases/download/0.0.2/birds_macos_v0.0.2.zip) -->
<!-- * [For Ubuntu](https://github.com/dangtv/BIRDS/releases/download/0.0.2/birds_ubuntu_v0.0.2.zip) -->
<!-- * [Older versions](https://github.com/dangtv/BIRDS/releases) -->
or build an executable file from the source code available at <a href="https://github.com/dangtv/BIRDS">https://github.com/dangtv/BIRDS</a> (along with instructions)</li>
</ul>

<h2 id="usage">Usage</h2>

<div class="language-bash highlighter-rouge"><div class="highlight"><pre class="highlight"><code>birds <span class="o">[</span>OPTIONS]
<span class="nt">--version</span>               Print version
<span class="nt">--log</span>                   Print running information
<span class="nt">--debug</span>                 Enable debugging mode
<span class="nt">--explain</span>               Show only explanations <span class="k">in </span>the debugging mode
<span class="nt">-f</span> &lt;file&gt;               Input program file, <span class="k">if </span>not chosen, <span class="nb">read </span>from stdin
<span class="nt">-b</span> &lt;file&gt;               Shell script file specifying the action, which will be executed when there is an update on the view, <span class="k">if </span>not chosen, execute nothing
<span class="nt">-o</span> &lt;file&gt;               Output SQL file, <span class="k">if </span>not chosen, print to stdout
<span class="nt">-l</span> &lt;file&gt;               Output verification file <span class="o">(</span>optional<span class="o">)</span>
<span class="nt">-s</span> &lt;schema&gt;             Database schema name to connect to <span class="o">(</span>default: public<span class="o">)</span>
<span class="nt">-h</span> &lt;host&gt;               Database server host <span class="o">(</span>default: <span class="s2">"localhost"</span><span class="o">)</span>
<span class="nt">-c</span>                      Connect and run the generated SQL on the database server
<span class="nt">--import</span>                Connect and import the data schema from the database server
<span class="nt">-v</span>                      Enable verifications
<span class="nt">-x</span> &lt;size&gt;               Get a counterexample with the maximum size <span class="k">if </span>the program is not well-behaved
<span class="nt">--counterexample</span> &lt;size&gt; The same as <span class="nt">-x</span>
<span class="nt">-i</span>                      Optimize the update propagation by incremental rewriting rules
<span class="nt">--incrementalization</span>    The same as <span class="nt">-i</span>
<span class="nt">-e</span>                      Optimize datalog rules
<span class="nt">--optimization</span>          The same as <span class="nt">-e</span>
<span class="nt">-u</span>                      Speed up the verifications
<span class="nt">--speedup</span>               The same as <span class="nt">-u</span>
<span class="nt">-p</span> &lt;port&gt;               Database server port <span class="o">(</span>default: <span class="s2">"5432"</span><span class="o">)</span>
<span class="nt">-U</span> &lt;user&gt;               Database user <span class="o">(</span>default: <span class="s2">"postgres"</span><span class="o">)</span>
<span class="nt">-g</span> &lt;user&gt;               The special user <span class="k">for </span>global dejima synchronization <span class="o">(</span>default: <span class="s2">"dejima"</span><span class="o">)</span>
<span class="nt">--dejima</span>                Detect updates on dejima views to perform pre-defined actions <span class="k">in </span>the shell script file
<span class="nt">-w</span> &lt;password&gt;           Database user password <span class="o">(</span>default: 12345678<span class="o">)</span>
<span class="nt">-d</span> &lt;dbname&gt;             Database name to connect to <span class="o">(</span>default: <span class="s2">"datalogdb"</span><span class="o">)</span>
<span class="nt">-t</span> &lt;<span class="nb">timeout</span><span class="o">&gt;</span>            Timeout <span class="o">(</span>second<span class="o">)</span> <span class="o">(</span>default: 120s<span class="o">)</span>
<span class="nt">-help</span>                   Display this list of options
<span class="nt">--help</span>                  Display this list of options
</code></pre></div></div>

<p>For example, this command transforms the update strategy described in <code class="highlighter-rouge">test1.dl</code> to <code class="highlighter-rouge">test1.sql</code>:</p>
<div class="language-bash highlighter-rouge"><div class="highlight"><pre class="highlight"><code>birds <span class="nt">-s</span> public <span class="nt">-f</span> test1.dl <span class="nt">-o</span> test1.sql
</code></pre></div></div>

        </section>
      </div>
    </div>
    
    <!-- FOOTER  -->
    <div id="footer_wrap" class="outer">
      <footer class="inner">
        <p style="margin-bottom:0em"><small>
          
          Maintained by <a href="https://dangtv.github.io">Vandang Tran</a>, Hiroyuki Kato, Zhenjiang Hu</small>.
        
        <small>Theme based on <a href="https://github.com/pages-themes/slate">Slate</a></small>.
        <small>Last updated on 2 Dec 2020</small></p>
      </footer>
    </div>

    
  </body>
</html>