Hi people
i try to add a database support the the js script in syncrhonet
i use (at moment) sqlite as backend.
i thinking in an object that may be used to easy storage data for door or modules and easy access via sql standard commands.
an simple example of script code :
db = new Sqlite("/tmp/tu_base.db");
db.open();
db.stmt = "CREATE TABLE prueba (field1 int , field2 varchar(100))"; db.exec();
Re: database objectnow, it work as exec(query) too.
By: Ragnarok to DOVE-Net.Sync_JavaScript on Sun Apr 08 2007 05:32 pm
Hi people
i try to add a database support the the js script in syncrhonet
i use (at moment) sqlite as backend.
i thinking in an object that may be used to easy storage data for door
or modules and easy access via sql standard commands.
an simple example of script code :
db = new Sqlite("/tmp/tu_base.db");
db.open();
db.stmt = "CREATE TABLE prueba (field1 int , field2 varchar(100))"; db.exec();
Why not just db.exec("CREATE TABLE prueba (field1 int , field2 varchar(100))") ?
db = new Sqlite("/tmp/tu_base.db");
db.open();
db.stmt = "CREATE TABLE prueba (field1 int , field2 varchar(100))";
db.exec();
Why not just db.exec("CREATE TABLE prueba (field1 int , field2
varchar(100))") ?
now, it work as exec(query) too.
Sysop: | digital man |
---|---|
Location: | Riverside County, California |
Users: | 1,067 |
Nodes: | 17 (1 / 16) |
Uptime: | 07:33:06 |
Calls: | 501,266 |
Calls today: | 13 |
Files: | 109,409 |
D/L today: |
13,049 files (9,094M bytes) |
Messages: | 302,263 |
Posted today: | 10 |