SQlite3 hoopup issues on mac os x

friends of the int-arweb.

what does this mean:

(in bold) ActiveRecord::StatementInvalid in Contact#create

SQLite3::SQLException: SQL logic error or missing database: INSERT
INTO contacts

Context:
this happened after I had finished setting up RoR as per the tutorial
at http://maczealots.com/tutorials/ruby-on-rails/

the database, is like, there. is there a nice ruby command like deal
to test if everything is hooked up correctly?

grough…
thanks,
-sjh

On Mar 4, 2006, at 7:05, Silas Hundt wrote:

Context:
this happened after I had finished setting up RoR as per the
tutorial at http://maczealots.com/tutorials/ruby-on-rails/

the database, is like, there. is there a nice ruby command like
deal to test if everything is hooked up correctly?

Can you paste config/database.yml and the output of

ls db

to make apparent everything looks fine?

– fxn

Interestingly, I have a similar problem. I can select from the
database
just fine, and insert into the database from the sqlite shell (i.e:
sqlite>…). But when I attempt to insert into the database from a
form, in
otherwords using
ActiveRecord’s create method, I get the same error message as above,
albeit
different table.

per the requested information:

ls db yeilds
datadef.sql dev.db prod.db test.db

cat database.yml yeilds
development:
adapter: sqlite3
database: db/dev.db

test:
adapter: sqlite3
database: db/test.db

production:
adapter: sqlite3
database: db/prod.db

Once again, I can select both from rails and the sqlite shell, but only
insert from the sqlite shell. I have not tried to update nor delete.

  • thank you, Travis.

Its a simple permission problem, make sure that your database can be
written
to by the webserver. duh.

I’m having the same problem, using Rails set up using the directions
here:

http://tonyarnold.com/articles/2005/12/14/ruby-on-rails-1-0-installer

After dealing with all sorts of permission problems (had to give
permission to the www user to access the tmp/sessions directory in the
Rails app’s folder), trying to get a simple Rails app running, that I
have in a folder in my desktop, when I try to update or create a
record I get the same error.

I went so far as to set the permissions of the whole rails apps files
and folders to 777, but that didn’t help.

On 3/28/06, John T. [email protected] wrote:

I’m having the same problem, using Rails set up using the directions here:

I went so far as to set the permissions of the whole rails apps files
and folders to 777, but that didn’t help.

Yeah, still a permissions problem. I set the permissions of the app’s
folder to 777:

chmod 777 test

and restarted Apache and it started working.

There’s got to be a better way to serve an app out of a folder in my
home directory without having to open the whole hierarchy wide open…

jt

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs