I'm having problems with MySQL queries in Ruby. I am using gem mysql.
The configuration is stored in a separate yml file and loaded into the @conf variable. This is my code:
Mysql::new(@conf['sql_host'], @conf['sql_user'], @conf['sql_password'], @conf['sql_base'])
my.query("SELECT * FROM `my_table`") do |e|
end
my.query("SELECT * FROM `my_table_2`")
Windows XP
ruby 1.8.6 (2008-08-11 patchlevel 287) [i386-mswin32]
mysql (2.8.1, 2.7.3)
MySQL client version: 5.0.51a
Request a second request request: not connected. '
source
share