I'm not sure why this code is breaking:

procedure SaveDatabaseTo(fName:string);
var
  TempDB:tsqlitedatabase;
begin
  TempDB:=TSQLiteDatabase.Create(fName);
  TempDB.ExecSQL('PRAGMA journal_mode = OFF');
  db.Backup(TempDB);
  tempdb.free;
end;

It fails at the PRAGMA statement.  In the CLI, the command works on an
empty database, however setting this to anything causes a fault.  I checked
with SQLite Expert and I can execute the call with the same DLL I'm using
in my application.  I'm using a later version of 3.07 of the amalgamation.

The code I'm using is from here:

http://www.itwriting.com/blog/?page_id=659

Anyone have any ideas?

fName is never :memory: as this procedure is called from a Windows Save
dialogue.

This isn't a huge deal for me.  I would just prefer not seeing the journal
file show up on my desktop, however, for future reference, inquiring minds
would like to know. :]
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to