Hi all! As a proof of concept, I created a table in sqlite database. Very simple table "test" having fields "Id", "TestName", and "FTestVar". Non-standard, I know, but that is because I will be working with a crazy legacy database.
So...... I run a hobo generate statement: ./script/generate hobo_model_resource test TestName:string FTestVar:boolean and then go into the model and add: set_table_name "test" I fire up the server, and as soon as I try to hit the main page, I get this error: Read error: #<ActiveRecord::StatementInvalid: Could not find table 'tests'> /var/lib/gems/1.8/gems/activerecord-2.3.8/lib/active_record/ connection_adapters/sqlite3_adapter.rb:29:in `table_structure' Can anyone shed some light? What should I do in working with legacy tables? BTW, I did my code generation using this script: http://pastie.org/1097156 by executing the following command: ./script/get_fields test Test | xargs ruby script/generate hobo_model_resource Test If that helps anything.... And here is the exact create statement for the sqlite table: CREATE TABLE "test" ("Id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "TestName" varchar(40), "FTestVar" bit); -- You received this message because you are subscribed to the Google Groups "Hobo Users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/hobousers?hl=en.
