Reputation: 635
quick question - my ruby application is freezing at the query command in the below script. Any ideas why?
Cheers Martin
require "mysql"
con = Mysql.new('127.0.0.1', 'root', 'password', 'database')
con.select_db('database')
queryresult = con.query("SELECT * FROM table")
#puts queryresult.inspect
queryresult.free
con.close
Upvotes: 1
Views: 115
Reputation: 35493
Is your table really named "table"?
Try using a different table name - MySQL sometimes has quirks when it tries to parse reserved words.
Upvotes: 1