Arc Forumnew | comments | leaders | submitlogin
Need help with sqlite interface
4 points by uvl 6082 days ago | 3 comments
Is anybody successfully using the sqlite interface (http://arclanguage.org/item?id=2186) on linux? I have installed and compiled everything. Then started sqarc and typed some test queries like this:

uvl@DL:~$ arc Use (quit) to quit, (tl) to return here after an interrupt.

arc> (= ff (db+ "test3"))

(#<input-port> #<output-port>)

arc> (sql ff "create table foo (id integer primary key, text varchar(255))")

nil

arc> (sql ff" insert into foo (text) values ('first');")

Error: "tcp-write: error writing (Broken pipe; errno=32)"

arc>

What's my error?



3 points by stefano 6080 days ago | link

IMO it would be better to use directly the C SQLite API through ffi.arc.

-----

3 points by wfarr 6082 days ago | link

It's been a little broken for a while. Not sure what the deal is.

-----

1 point by uvl 6082 days ago | link

Thanks for the answer wfarr.

Just for completeness:

  uvl@DL:~/prog/sqarc$ ./sqarc 
  sqarc listening on port 49153
  Child 4465 started
  4465 < test3
  4465 < create table foo (id integer primary key, text varchar(255
  Child 4465 stopped
The process seems to stop during the sql statement. The database "test3" was created as an empty file in the sqarc folder.

-----