Atlas Knowledge Base
Dashboard
Getting Started

Getting Started


The Compilers are cross-platform command-line tools for compiling SQL, managing database configurations, and running upgrades against Innovative's SBN environments. Self-contained binaries run on Windows, Linux, and macOS, with a built-in self-updater.

Repository Access

The Compilers live in the private GitHub repository innovative247/compilers. You must have authorization from Innovative before you can access it. Without authorization, the install URL returns 404.

To request access:

  1. Have a personal GitHub account ready (or create one at github.com/signup — GitHub also lets you sign up during invitation acceptance).
  2. Contact your Innovative point of contact with your GitHub username.
  3. Innovative will add you as a collaborator. Accept the invitation email within 7 days.
  4. Verify by visiting https://github.com/innovative247/compilers while signed in.

You will also need a working copy of the SBN_IR SVN tree — see Source Code (SBN_IR).

Installation

Pick the platform-specific guide:

  1. Windows Setup
  2. Ubuntu Setup (covers native Linux and WSL)

The installer ends by offering to run configure for you. If you accepted that prompt, the Configuration step below is already done.

Configuration

If you skipped configure at install time, run it now:

set_profile configure # Verify install + add compilers to PATH

Then add a database connection profile and verify the binary is reachable:

set_profile # Interactive wizard — adds a database connection profile
runsql version # Verify install (no DB connection)

For a real DB connectivity check after creating a profile:

set_profile --test SBNA --what connection

settings.json

Profiles are stored in settings.json alongside the binaries:

  1. Windows: %LOCALAPPDATA%\ibs-compilers\settings.json
  2. Linux / macOS: ~/ibs-compilers/settings.json
{
  "Profiles": {
    "SBNA": {
      "ALIASES": [
        "A"
      ],
      "COMPANY": 999,
      "DEFAULT_LANGUAGE": 1,
      "PLATFORM": "SYBASE",
      "HOST": "10.10.10.10",
      "PORT": 5000,
      "USERNAME": "user",
      "PASSWORD": "your_password",
      "SQL_SOURCE": "/path/to/your/ir_local"
    }
  }
}

SQL_SOURCE must point at the SVN working copy from Source Code. Use set_profile to manage profiles rather than editing the file directly.

Commands


Command

What it does

set_profile

Interactive profile configuration wizard

isqlline

Execute a single SQL command

runsql

Execute a SQL script with placeholder resolution

runcreate

Orchestrate multi-file builds

i_run_upgrade

Apply database upgrade scripts

set_options / eopt

Edit and compile database options

set_table_locations / eloc

Edit and compile table locations

set_actions / eact

Edit and compile actions

set_required_fields / compile_required_fields

Edit and compile required-fields

set_messages / compile_msg

Compile message tables (set_messages is interactive; compile_msg is the same dispatcher with a separate binary name)

extract_msg

One-shot export of message tables to source files (round-trippable)

transfer_data

Bulk data transfer (interactive only)

bcp_data

Bulk copy in/out for individual tables (native-bcp flags: -t, -b, --truncate, datafile positional)

iplan

Query plan viewer for a SPID

iplanext

Extended plan viewer (process info + SQL text + plan)

iwho

Show connected users (sp_who)

iwatch

Tail a log file live

Common subcommands

All compiler binaries support:

  1. version — print version
  2. configure — verify install, add to PATH
  3. update / install — self-update from GitHub Releases
  4. help — show usage

Background builds with live tail

runcreate create_all SBNA my_run.log -bg # launches in background
iwatch my_run.log.out # follows the log live

runcreate writes both .out (everything) and .err (failures only) when given a log file. iwatch tails the file until the process exits.

Bulk copying table data

bcp_data <table...> <IN|OUT> [datafile] <profile> [-t field_terminator] [-b batchsize] [--truncate]
  1. IN appends by default, exactly like native bcp. --truncate empties the table first.
  2. -t sets the field terminator (default tab). It accepts the \t, \n, \\ and \0 escapes, or a literal such as -t"|".
  3. -b N commits every N rows, traditional bcp style. Without it the whole file loads as a single unit, so a failure leaves the table unchanged — a transaction on MSSQL and PostgreSQL, the server's own bulk batch on Sybase ASE, which does not allow bulk copy inside a transaction.
  4. The datafile positional names the file, and applies to a single table only. Omitted, the file is <table>.bcp in the current directory.
  5. Data files are UTF-8 (no BOM, LF line ends). On Sybase imports the server's character set is detected and reported.

Examples:

bcp_data ba_options OUT SBNA # writes ba_options.bcp
bcp_data ba_options IN backup.dat SBNA -t"|" -b 1000 --truncate

Updating

The Compilers self-update from GitHub Releases. Run update (or install) from any binary — the dispatcher accepts the verb with any prefix:

runsql update runsql -update runsql --update
isqlline install set_profile -install runcreate /update

Downloads and extracts the latest platform asset if newer. Your settings.json is never overwritten.

A daily background check also runs on first invocation each day. If a newer release exists, you'll be prompted interactively.

MSSQL Initialization Script

For Microsoft SQL Server, the Compilers honor the SQLCMDINI environment variable. If it points to a SQL file, that file runs at the start of every connection.

Example mssql_setup.sql:

SET ARITHABORT ON
SET ANSI_NULL_DFLT_ON OFF
SET ANSI_NULL_DFLT_OFF OFF
SET CONCAT_NULL_YIELDS_NULL OFF
SET ANSI_WARNINGS ON
SET QUOTED_IDENTIFIER OFF

Set the variable on Windows:

[Environment]::SetEnvironmentVariable("SQLCMDINI", "C:\path\to\mssql_setup.sql", "User")

On Ubuntu:

echo 'export SQLCMDINI="$HOME/mssql_setup.sql"' >> ~/.bashrc

Troubleshooting


Symptom

Fix

Profile 'XYZ' not found

Run set_profile --view XYZ. Use set_profile to create.

Company Option File Missing! .../css/setup/options.NNN

Profile's SQL_SOURCE doesn't have populated css/setup/, or COMPANY doesn't match an existing options file.

Self-update succeeds but version unchanged

An older copy is earlier on PATH — the running binary updates itself but PATH lookup hits a different one. Run which runsql (Linux/macOS) or where runsql (Windows).

macOS: cannot be opened — developer cannot be verified

xattr -d com.apple.quarantine * in the install dir.

Linux: permission denied after self-update

chmod +x ~/ibs-compilers/*

Bash hash cache holding an old path

hash -r

Windows: "Symbolic link creation requires elevated privileges" warning on first compile

Enable Windows Developer Mode (Settings → For Developers) so the Compilers can create the lowercase symlinks they need.

  1. Source Code (SBN_IR) — the SVN tree the Compilers consume.
  2. Windows Setup — install + configure on Windows.
  3. Ubuntu Setup — install + configure on Ubuntu (native or WSL).




Was this helpful?