I''ve tried several techniques to importing data, no success.
I don''t have much SQL, do I need to do something like "load
infile"
through SQL to import data? Or, can I do something through rails with
the "source foo.sql" command, which looks promising but I, for one,
can''t
figure out the syntax :(
thufir@arrakis ~/goodfellow-tool/db $
thufir@arrakis ~/goodfellow-tool/db $ sqlite3 development.sqlite3 <
data.sql
SQL error near line 1: near "/": syntax error
thufir@arrakis ~/goodfellow-tool/db $
thufir@arrakis ~/goodfellow-tool/db $ cat data.sql
insert into db/development.sqlite3.calls (name) values ("goodfellow");
thufir@arrakis ~/goodfellow-tool/db $
thufir@arrakis ~/goodfellow-tool/db $ source data.sql
bash: data.sql: line 1: syntax error near unexpected token `(''
bash: data.sql: line 1: `insert into db/development.sqlite3.calls (name)
values ("goodfellow");''
thufir@arrakis ~/goodfellow-tool/db $
thufir@arrakis ~/goodfellow-tool/db $
thufir@arrakis ~/goodfellow-tool/db $ sqlite3 development.sqlite3
SQLite version 3.4.1
Enter ".help" for instructions
sqlite> .schema
CREATE TABLE calls ("id" INTEGER PRIMARY KEY NOT NULL,
"start" integer
DEFAULT NULL, "end" integer DEFAULT NULL, "name"
varchar(255) DEFAULT
NULL, "avaya_login" integer DEFAULT NULL);
CREATE TABLE schema_info (version integer);
sqlite> .quit
thufir@arrakis ~/goodfellow-tool/db $
thanks,
Thufir
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---