Xplain2sql

More about Xplain2sql

Xplain2sql converts Xplain statements to SQL statements. More about this tool can be found in:

Supported SQL dialects

Xplain2sql supports a very large subset of Xplain already, and it is continually extended until full support is reached. Currently it can convert from Xplain to PostgreSQL, MySQL or MariaDB, Microsoft SQL Server, Embarcadero InterBase, Firebird, DB/2, Oracle, SQLite 3, ANSI-92 SQL, Microsoft Access and FoxPro:

  • PostgreSQL is very well supported. Tested against PostgreSQL 9.5.x.
  • MySQL 5 is also very well supported.
  • Microsoft SQL Server support is very complete.
  • FireBird support is reasonably complete although FireBird still lacks essential features such as the ability to create a temporary table in a stored procedure, so extends only work outside a stored procedure.
  • InterBase support for init works only for literal inits (so attributes don't work). And because InterBase doesn't have the concept of temporary table, the extend and value only work for a single user.
  • Quite complete DB/2 support. Non literal inits are currently missing.
  • Fairly complete Oracle support.
  • Generates good ANSI-92, however inits with non-literal values cannot be supported by ANSI-92 because it doesn't have the concept of before and after insert triggers.
  • Generates Microsoft Access and FoxPro data definition commands. However, it seems impossible to run an entire script against an Access database. Having to run each create table statement by hand is quite tedious.

Contact me if you want support for other databases.

Download official release

Development currently takes place in github, and the software can be easily compiled with gobo.

The latest release is 5.5. It was released on 5 February, 2020. There are downloads of sources, and binaries for various platforms.

The easiest way to install xplain2sql might be using the npm package:

npm install -g node_xplain2sql
xplain2sql source code downloads
DescriptionFile name
Full source, samples and documentation, no binaries. The source is written in Eiffel, you need to have the Gobo compiler installed to compile it. See the docs for details. Eiffel source tarball release
Eiffel zipped release
C source code (translated from Eiffel).
Type make and you have a binary for every platform that has a Standard C compiler.
C source tarball release
C source zipped release
Samples, documentation and the man page in case you downloaded a binary). xplain2sql.doc.zip
User visible changes. NEWS
ChangeLog of xplain2sql. ChangeLog

xplain2sql binary downloads
PlatformFile nameVersion
Windows (compiled on Windows 10 with ISE Eiffel 17.05) xplain2sql.exe 5.2
Linux Intel 64-bit binary (compiled on Unbuntu 19.10). Rename it to xplain2sql. xplain2sql-linux 5.5
Debian package (Ubuntu 17.10). xplain2sql-5.2-1_amd64.deb 5.2
Ubuntu Trusty 14.04 package. xplain2sql-5.2.1-1_amd64_trusty.deb 5.2
Ubuntu Trusty 16.04 package. xplain2sql-5.2.1-1_amd64_xenial.deb 5.2

Try it out line

Try it now

Support

Support for Xplain2sql is provided in the Xplain group.

Subscribe to Xplain
Powered by groups.yahoo.com
Xplain@yahoogroups.com

Older releases

In case an older release has worked for you, but a newer one doesn't, here the previous releases:

  1. xplain2sql-5.0.1-csrc.zip: xplain2sql 5.0 zipped C source.
  2. xplain2sql-3.0-csrc.zip: xplain2sql 3.0 zipped C source.
  3. xplain2sql-2.4-csrc.zip: xplain2sql 2.4 zipped C source.
  4. xplain2sql-2.2-csrc.zip: xplain2sql 2.2 zipped C source.
  5. xplain2sql-2.0-csrc.zip: xplain2sql 2.0 zipped C source.
  6. xplain2sql-1.3.0-csrc.zip: xplain2sql 1.3.0 zipped C source.

Note: on request, source or other format releases are also available.