hi, i have this statement User.find_by_sql ("SELECT Users.id, COUNT(Howtos.user_id) FROM Howtos, Users WHERE Howtos.user_id = Users.id GROUP BY Users.id") this works on my local setup, but when i moved my application to another server, i get an error message that my Howtos table does not exist. thoughts?
on 2006-12-31 06:15
on 2006-12-31 06:51
Was your migrations successful? Did you check the database to see if it really is there?
on 2006-12-31 07:08
yes, i have other functions that i call that accesses the howto table and display that in a view.. hmmmm.
on 2006-12-31 07:21
Hi, please try running the SQL query on the remote machine at the command line for the db engine. Then report the error message that you're receiving. -Conrad
on 2006-12-31 07:28
hello, here is what i got mysql> SELECT Users.id, Users.login, COUNT(Howtos.user_id) as numhowtos FROM Howtos, Users WHERE Howtos.user_id = Users.id GROUP BY Users.id; ERROR 1146 (42S02): Table 'myname_myfirstapp.Howtos' doesn't exist Conrad Taylor wrote: > Hi, please try running the SQL query on the remote machine at the > command line for the db engine. Then report the error message that > you're receiving. > > -Conrad
on 2006-12-31 07:31
i have other functions that i call on my howtos table that populate my index page. after i comment out the sql statement, my other functions work fine..im not sure what is happening.
on 2006-12-31 07:47
Hi, try using 'howtos' instead of 'Howtos' for your table name. Let me know what happens. -Conrad
on 2006-12-31 16:30
Hi Conrad, Awesome thanks! it started working when i made everything lower case. much appreciation to all!