Discussion:
How to backup database ?
(too old to reply)
Arctic Wolf
2003-07-22 15:43:40 UTC
Permalink
I'm using FreeBSD 5.1, PRC-Tools 2.2, Palm OS SDK 4.0 plus update.
I'm trying to set the database attribute so that it'll backup during sync.

UInt16 attributes;
dbID = DmFindDatabase(memCardNo, dbName);
DmDatabaseInfo(memCardNo, dbID, dbName, &attributes, NULL, NULL,...
attributes |= dmHdrAttrBackup;
DmSetDatabaseInfo(memCardNo, dbID, dbName, &attributes, NULL, NULL,...

This doesn't work.
The database isn't in c:\Program Files\Palm\User\Backup\
As a matter of fact, the command
attributes |= dmHdrAttrBackup;
has no effect on the value of the variable attributes.
Is there an easier way to obtain a database file created on the POSE?
Arctic Wolf
2003-07-23 17:59:20 UTC
Permalink
Post by Arctic Wolf
I'm using FreeBSD 5.1, PRC-Tools 2.2, Palm OS SDK 4.0 plus update.
I'm trying to set the database attribute so that it'll backup during sync.
UInt16 attributes;
dbID = DmFindDatabase(memCardNo, dbName);
DmDatabaseInfo(memCardNo, dbID, dbName, &attributes, NULL, NULL,...
attributes |= dmHdrAttrBackup;
DmSetDatabaseInfo(memCardNo, dbID, dbName, &attributes, NULL, NULL,...
This doesn't work.
The database isn't in c:\Program Files\Palm\User\Backup\
As a matter of fact, the command
attributes |= dmHdrAttrBackup;
has no effect on the value of the variable attributes.
Is there an easier way to obtain a database file created on the POSE?
I figured out how to backup the database.
First, there's no need to specify the database names, so dbName can be
substituted with NULL.
The 8th argument of DmSetDatabaseInfo specifies when the database is to be
backed up. Here's a fix to the above code.

UInt16 attributes;
UInt32 backupTime = TimGetSeconds();
dbID = DmFindDatabase(memCardNo, dbName);
DmDatabaseInfo(memCardNo, dbID, NULL, &attributes, NULL, NULL, NULL,...
attributes |= dmHdrAttrBackup;
DmSetDatabaseInfo
(memCardNo, dbID, NULL, &attributes, NULL, NULL, NULL, &backupTime, NULL,...

Above will allow backup of the database on next sync.

Another way is to right click on the POSE and choose Export Database.
Loading...