New test data for SQLite parser.
[dbsrgits/SQL-Translator.git] / README
1                       SQL::Translator README
2
3 SQL::Translator is a group of Perl modules that converts
4 vendor-specific SQL table definitions into other formats, such as
5 other vendor-specific SQL, ER diagrams, documentation (POD and HTML),
6 XML, and Class::DBI classes.  The main focus of SQL::Translator is
7 SQL, but parsers exist for other structured data formats, including
8 Excel spreadsheets and arbitrarily delimited text files.  Through the
9 separation of the code into parsers and producers with an object model
10 in between, it's possible to combine any parser with any producer, to
11 plug in custom parsers or producers, or to manipulate the parsed data
12 via the built-in object model.  Presently only the definition parts of
13 SQL are handled (CREATE, ALTER), not the manipulation of data (INSERT,
14 UPDATE, DELETE).
15
16 As of version 0.03, parsers exist for the following:
17
18     Databases:
19         MySQL
20         Oracle
21         PostgreSQL
22         Sybase
23
24     Other:
25         xSV         : arbitrarily delimited text files
26         Excel       : Microsoft Excel spreadsheets
27         XML-SQLFairy: SQLFairy's XML format
28
29 And the following producers exist:
30
31     Databases:
32         MySQL
33         Oracle
34         PostgreSQL
35         SQLite
36         Sybase
37
38     
39     Code Generators:
40         ClassDBI: Class::DBI classes
41
42     Documentation:
43         Diagram     : quasi-ER diagrams using libgd
44         GraphViz    : ER diagrams using GraphViz
45         HTML        : HTML documentation of schema
46         POD         : Plain Old Documenation of schema
47
48     Other:
49         XML-SQLFairy: structure of the schema described in SQLFairy's XML
50
51 Included in this distribution are a few scripts designed to be user
52 interfaces for the actual SQL::Translator modules.  In the "bin"
53 directory, you will find:
54
55 *   sqlt-diagram
56 *   sqlt-graph
57 *   sqlt-dumper
58 *   sqlt
59 *   sqlt.cgi
60
61 All scripts not ending in ".cgi" are meant to be run from the command
62 line with various switches to control the input and output of the
63 scripts, while the ".cgi" script is a web-form frontend.  The script
64 you'll probably find most useful is "sqlt" which is meant to be the
65 main interface for translating from text-to-text.  The graphic
66 producers, however, have many extra switches, so there are scripts
67 specific for each of the the GraphViz and ER-diagram producers.  All
68 scripts start with "sqlt" so it will be easier to identify them on
69 your system.  All the non-CGI scripts will be installed in a system
70 path when you "make install," but you'll have to manually place the
71 CGI script into your web CGI directory to use it.
72
73 If you're more interested in using the SQL::Translator modules
74 directly, then you might be more interested to examine some of the
75 test scripts in the "t" directory.  The test suite is relatively
76 thorough and should give you an idea of how to parse a file and
77 manipulate the SQL::Translator::Schema objects.
78
79 INSTALLATION
80
81 The regular method:
82
83     $ perl Makefile.PL
84     $ make
85     $ make test
86     $ su -
87     # make install
88
89 COPYRIGHT
90
91 This program is free software; you can redistribute it and/or modify it
92 under the terms of the GNU General Public License as published by the
93 Free Software Foundation; version 2.
94
95 This program is distributed in the hope that it will be useful, but
96 WITHOUT ANY WARRANTY; without even the implied warranty of
97 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
98 Public License for more details.
99
100 You should have received a copy of the GNU General Public License along
101 with this program; if not, write to the Free Software Foundation, Inc.,
102 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
103
104 BUGS
105
106 Please use http://rt.cpan.org/ for reporting bugs.
107
108 PRAISE
109
110 If you find this module useful, please use 
111 "http://cpanratings.perl.org/rate/?distribution=SQL-Translator" to rate it.
112
113 SEE ALSO
114
115 Check out the SQLFairy homepage at Sourceforge for more information,
116 mailing lists, etc.:
117
118     http://sqlfairy.sourceforge.net/