author | mickeyl <mickeyl> | 2003-08-10 15:42:26 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2003-08-10 15:42:26 (UTC) |
commit | 90dbd3e9e7139c1280e71f9c77ed4362b8d0f367 (patch) (unidiff) | |
tree | 22f0947337ea9b21a1d8f56d04ce3292c9d6f19e /libsql/test/zeilenweise.cpp | |
parent | 616e919ff6aea6a30e18edb37128c229e806beae (diff) | |
download | opie-90dbd3e9e7139c1280e71f9c77ed4362b8d0f367.zip opie-90dbd3e9e7139c1280e71f9c77ed4362b8d0f367.tar.gz opie-90dbd3e9e7139c1280e71f9c77ed4362b8d0f367.tar.bz2 |
libsql is now a part of libopie2
-rw-r--r-- | libsql/test/zeilenweise.cpp | 84 |
1 files changed, 0 insertions, 84 deletions
diff --git a/libsql/test/zeilenweise.cpp b/libsql/test/zeilenweise.cpp deleted file mode 100644 index e538c9f..0000000 --- a/libsql/test/zeilenweise.cpp +++ b/dev/null | |||
@@ -1,84 +0,0 @@ | |||
1 | #include <qdir.h> | ||
2 | |||
3 | #include <qpe/qpeapplication.h> | ||
4 | #include "../osqlmanager.h" | ||
5 | #include "../osqlquery.h" | ||
6 | #include "../osqldriver.h" | ||
7 | #include "../osqlresult.h" | ||
8 | |||
9 | int main( int argc, char* argv[] ) { | ||
10 | |||
11 | QPEApplication app( argc, argv ); | ||
12 | OSQLManager man; | ||
13 | man.registerPath( QDir::currentDirPath() ); | ||
14 | OSQLBackEnd::ValueList list = man.queryBackEnd(); | ||
15 | |||
16 | OSQLDriver *driver = man.standard(); | ||
17 | qWarning("testmain" + driver->id() ); | ||
18 | driver->setUrl("/home/ich/zeilenweise"); | ||
19 | if ( driver->open() ) { | ||
20 | qWarning("could open"); | ||
21 | }else | ||
22 | qWarning("wasn't able to open"); | ||
23 | OSQLRawQuery raw2("BEGIN TRANSACTION"); | ||
24 | OSQLRawQuery *raw = new OSQLRawQuery("create table todolist(uid,key,value)"); | ||
25 | OSQLResult res = driver->query( &raw2 ); | ||
26 | res = driver->query( raw ); | ||
27 | delete raw; | ||
28 | for (int i = 0; i< 10000; i++ ) { | ||
29 | int uid = i; | ||
30 | OSQLRawQuery *raw; | ||
31 | raw = new OSQLRawQuery("insert into todolist VALUES("+QString::number(uid)+",'Categories',"+"'-122324;-12132')"); | ||
32 | OSQLResult res = driver->query(raw ); | ||
33 | delete raw; | ||
34 | |||
35 | raw = new OSQLRawQuery("insert into todolist VALUES("+QString::number(uid) + | ||
36 | ",'Completed',1)" ); | ||
37 | res = driver->query(raw ); | ||
38 | delete raw; | ||
39 | |||
40 | raw = new OSQLRawQuery("insert into todolist VALUES("+ | ||
41 | QString::number(uid)+",'Progress',100)" ); | ||
42 | res = driver->query( raw ); | ||
43 | delete raw; | ||
44 | |||
45 | raw = new OSQLRawQuery("insert into todolist VALUES("+ | ||
46 | QString::number(uid)+",'Summary',"+ | ||
47 | "'Summary234-"+ QString::number(uid) + "')"); | ||
48 | res = driver->query( raw ); | ||
49 | delete raw; | ||
50 | |||
51 | raw = new OSQLRawQuery("insert into todolist VALUES("+ | ||
52 | QString::number(uid)+",'HasDate',1)"); | ||
53 | res = driver->query( raw ); | ||
54 | delete raw; | ||
55 | |||
56 | raw = new OSQLRawQuery("insert into todolist VALUES("+ | ||
57 | QString::number(uid)+",'DateDay',5)"); | ||
58 | res = driver->query( raw ); | ||
59 | delete raw; | ||
60 | |||
61 | raw = new OSQLRawQuery("insert into todolist VALUES("+ | ||
62 | QString::number(uid)+",'DateMonth',8)"); | ||
63 | res = driver->query( raw ); | ||
64 | delete raw; | ||
65 | |||
66 | raw = new OSQLRawQuery("insert into todolist VALUES("+ | ||
67 | QString::number(uid)+",'DateYear',2002)"); | ||
68 | res = driver->query( raw ); | ||
69 | delete raw; | ||
70 | |||
71 | raw = new OSQLRawQuery("insert into todolist VALUES("+ | ||
72 | QString::number(uid)+",'Priority',1)"); | ||
73 | res = driver->query( raw ); | ||
74 | delete raw; | ||
75 | |||
76 | raw = new OSQLRawQuery("insert into todolist VALUES("+ | ||
77 | QString::number(uid)+",'Description','" + | ||
78 | QString::number(uid) + "Description\n12344')"); | ||
79 | res = driver->query( raw ); | ||
80 | delete raw; | ||
81 | } | ||
82 | OSQLRawQuery raw3("COMMIT"); | ||
83 | res = driver->query(&raw3 ); | ||
84 | }; | ||