AW: V4MD: Save DB "As"

Florian Bogeschdorfer fb at memedia.de
Tue Feb 15 22:44:05 CST 2005


I have never seen a database behave like this before, I don't think that is
a usual way a database should be treated since it is not like a .psd a
single file but actually every record should be considered as a file.

However how about the other way round:

Before you open the DB, make a copy. This can easily be made. Then if the
user choses "save as" you can flush, close the connection and copy the
current database again to the new file.
If the user decides not to save the original DB, you can restore to the copy
you made before opening. 
If the user selects "save", you can again flush and replace the original DB.

Best regards, Florian



> -----Ursprüngliche Nachricht-----
> Von: valentina-bounces at lists.macserve.net [mailto:valentina-
> bounces at lists.macserve.net] Im Auftrag von Andrew Sinning
> Gesendet: Dienstag, 15. Februar 2005 21:59
> An: Valentina Developers
> Betreff: V4MD: Save DB "As"
> 
> A user open up a database and makes a few changes and then decides to do
> a "Save As".  This means that all the changes they have made need to get
> saved as a NEW database, but the database they have opened needs to
> remain as was the last time they did a "Save".
> 
> I can't copy the the db files to a temporary location because they are
> locked.
> 
> If I do a Dump() without first doing a Flush(), will the recent changes
> be included in the Dump()?  In otherwords, perhaps I need to do:
> 
> Dump()
> LoadDump(dumpFile, NEW_DATABASE_FILE)
> 
> Should this work?
> 
> _______________________________________________
> Valentina mailing list
> Valentina at lists.macserve.net
> http://lists.macserve.net/mailman/listinfo/valentina



More information about the Valentina mailing list