From: Manisha Tripathy Date: 2009-01-27T22:53:27+09:00 Subject: Re: Need help for Ruby DBI and PostgreSQl Brian Candler wrote: > Manisha Tripathy wrote: >> ok, here is the error : >> >> config: unknown option --with=dbi,dbd_pg >> Try 'ruby setup.rb --help' for detailed usage. > > You didn't show the command line you typed. But the following works just > fine for me: > > $ ruby setup.rb config --with=dbi,dbd_pg > entering config phase... > config done. > > This is dbi-0.2.0, ruby-1.8.6p111, Ubuntu Hardy. And I just took this > command from the README file. > >> When i checked for help, it just doesnt have an option --with= > > It does for me. > > $ ruby setup.rb config --help > config: unknown option --help > try "ruby setup.rb --help" for usage > > $ ruby setup.rb --help > > Usage: > ... > Options for config: > ... > --with=name,name... package name(s) you want to install [ALL] > --without=name,name... package name(s) you do not want to install [] > > So in this case maybe it's a good idea to list the exact platform, > version of Ruby, version of ruby-dbi you have unpacked, and to > copy-paste both the command you have typed *and* the responses you get. > > Regards, > > Brian. Thanks Brian. But the same doesnt work for me i.e. $ ruby setup.rb config --with=dbi,dbd_pg But however, i was so messed up that, now i removed the installation i did manually. I installed pg, dbi and dbd-pg gems using $ gem install......... Then tried the Ruby program i wrote again, and the wonder is that it worked!! I can connect to the PostgreSQL database from the Ruby program with statement dbh = DBI.connect('DBI:Pg:database_name','username','password') Honestly speaking I dont understand completely the reason,but it works.If you can explain it, I will be thankful. -- Posted via http://www.ruby-forum.com/.