Hi Ken, I was pretty sure you were a Mac person, and therefore, SQLT probably worked fine on a Mac. I'll try to simplify and figure out what the problem is and get back to you on the skip_tables stuff, though I suspect I'd like to have it. :-)
Thanks, Scott On Aug 25, 2009, at 4:01 PM, Ken Youens-Clark wrote: > Scott, > > This works for me. I've been on OS X for years and have developed > SQLT on it no problem. I used "sqlfairy/t/data/pgsql/turnkey.sql" > for my test data. I had to comment out the skip_tables stuff, of > course. Does it work for you if you comment that out, too? > > BTW, I added a "--skip-tables" option to "sqlt-graph" since I needed > that for a project. Want me to add this to "sqlt-diagram," too? I > think that would be easier than the script you've written here. > > ky > > On Aug 19, 2009, at 9:21 AM, Scott Cain wrote: > >> Hello, >> >> I recently switched from Linux to Mac OS X as my main development >> machine, and I'm having some problems getting sqlfairy running. I'm >> guessing it's due to both my forgetting what I did on the Linux side >> years ago to set it up, as well as my lack of familiarity with the >> Mac >> OS. I installed sqlfairy 0.10 from the cpan shell. >> >> So, the problem I'm having is that the producers aren't producing >> anything, but aren't giving me any feedback in the form of warnings >> or >> errors. Below is a simple script I use to generate diagrams from >> input sql files. If I set $SQL::Translator::DEBUG to 1, I get some >> feedback, including a dumpout of the entire schema, so I know that >> sqlfairy is at least reading and parsing the sql file. It just stops >> after that. >> >> I know that libgd is installed and working correctly (I use it for >> another app). I also installed GraphViz (from a pkg file) and >> GraphViz.pm (from cpan). The html producer doesn't do anything >> either. >> >> Does anybody have debugging suggestions? >> >> Thanks, >> Scott >> >> Here's the script: >> >> #!/usr/bin/perl >> >> use SQL::Translator; >> use Data::Dumper; >> use lib './bin'; >> use Skip_tables qw( @skip_tables ); >> >> $SQL::Translator::DEBUG = 0; >> >> my $in = shift; >> open(IN,$in) || die "couldn't open $in: $!"; >> >> my @create = <IN>; >> my $create = join '', @create; >> >> my $tr = SQL::Translator->new( >> parser => "PostgreSQL", >> producer => "Diagram", >> producer_args => {add_color=>1}, >> filters => [ >> sub { >> my $schema = shift; >> foreach (@skip_tables) { >> $schema->drop_table($_); >> } >> }, >> ], >> >> ); >> >> print $tr->translate(\$create); >> >> ----------------------------------------------------------------------- >> Scott Cain, Ph. D. scott at scottcain dot net >> GMOD Coordinator (http://gmod.org/) 216-392-3087 >> Ontario Institute for Cancer Research >> >> >> >> >> >> ------------------------------------------------------------------------------ >> Let Crystal Reports handle the reporting - Free Crystal Reports >> 2008 30-Day >> trial. Simplify your report design, integration and deployment - >> and focus on >> what you do best, core application coding. Discover what's new with >> Crystal Reports now. http://p.sf.net/sfu/bobj-july >> -- >> sqlfairy-developers mailing list >> sqlfairy-developers@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/sqlfairy-developers > ----------------------------------------------------------------------- Scott Cain, Ph. D. scott at scottcain dot net GMOD Coordinator (http://gmod.org/) 216-392-3087 Ontario Institute for Cancer Research ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july -- sqlfairy-developers mailing list sqlfairy-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sqlfairy-developers