The code can be broken into three conceptual groupings: Bug Reports, Feature Requests, and Good Karma We try our best to maintain a certain level of quality, but sometimes bugs slip through, especially with such a wide-ranging code base. All SQLFairy scripts begin with “sqlt. Base producer may be just for you! Sign up using Email and Password. Please read the documentation of the “sqlt-diagram” script for all the options available to this producer.


Uploader: Tasho
Date Added: 3 January 2017
File Size: 24.21 Mb
Operating Systems: Windows NT/2000/XP/2003/2003/7/8/10 MacOS 10/X
Downloads: 42899
Price: Free* [*Free Regsitration Required]

If so, the SQL:: How do we handle problem users? This enlightening interview explains, in sqlfairry nutshell, what the SQL Fairy is best for and how to get started with it. This can also provide a very convenient bridge to describing a schema to a non-Perl application.

Data Commoners: SQLFairy schema translation

Each line is a table definition where the fields are separated by colons. The flag syntax is somewhat quirky: Translator can call for the production of the output. For example, you could create a template that simply prints the name of each table and field that looks like this: This method provides a hook into them by returning a hash of options for the Template. Sign up using Email and Password.


In this manual, we will attempt to address how to use SQLFairy for common tasks. Translator object and the data to be parsed. Execute the script with the “–help” flag to read about them. Improving the question-asking experience. In this example, the schema will be represented in a simple text format. Please read the documentation of the “sqlt-diagram” script for all the options available to this producer.


Virtual Package: sqlfairy

Translator object which you can use to access the Schema objects. Note that if you leave out the DATA section all sqlfaory then your producer will require a template file name to be given. This can prove significantly faster than parsing a text file. However, you can also easily pass a reference to a subroutine that SQL:: New to version 0.

Debian — Details of package sqlfairy in jessie

If you find SQL:: The specifics of the example are unimportant — what is being demonstrated is that you have to decide how to parse the incoming data and then map the concepts in the data to the Schema object.

The column names are normalized to something sane for most databases whitespace is converted to underscores and non-word characters are removedand the data in each field is scanned to determine the appropriate data type character, integer, or sqlfairg and size. The solution for salfairy would be that you export only your table defintions of your schema.


There are several different layout algorithms and node shapes available. This can be a surprisingly useful documentation aid as it creates a very readable format that allows one to jump easily to specific tables and fields.


Obviously, the schema already describes itself, so it only makes sense that you should be able to generate this kind of code directly from the schema. If there’s something in particular you’d like to see, please contact Darren. Be sure to include your SourceForge username. You also get a number of methods you can override to hook into the template generation. Sqlfaiyr a solution dump your schema without the data, given sqlrairy example above you can do the following to get a dump which is working with the fairy:.

For example, MySQL’s “integer” data type would be converted to Oracle’s “number,” but the differ isn’t quite smart enough yet to figure this out.

You can already – if you give a template on the command line your new producer will use that instead of reading the DATA section: Base producer may be just for you! Instead of working like a normal producer it provides a base class so you can cheaply build new producer modules based on templates.