Error when adding to database

Login to reply to this topic.
Fri, 2005-03-11 18:15
Joined: 2004-08-19
Forum posts: 109
I create a database the usual way — just for reference:

Code:
 FileStore = CPermanentFileStore::ReplaceL (FsSession, databasePath, EFileRead | EFileWrite);
 FileStore->SetTypeL (FileStore->Layout ());
 TStreamId id = Database.CreateL (FileStore);
 FileStore->SetRootL (id);
 FileStore->CommitL ();

then issue the following SQL statement:

Code:
CREATE TABLE Table (F1 CHAR(50), F2 CHAR(60))

The database is created all right. Now I try to add a record with:

Code:
INSERT INTO Table VALUES ('xxx', 'yyy')

and I get a "System error (1)" error — yes, the number one, not a negative value. The data I'm trying to add does appear in the database if I peek into it. What am I doing wrong?

Thanks,
Gábor

djgtram

  • Login to reply to this topic.