Hi, all. I have a strongly encrypted db and need to run dbunload for it (Sybase 16). As I understand connection string should be something like this: "DBA=dba;PWD=sql;DBF=mydb.db;DBKEY=theKey". But there is a workflow for dbeng16 to load theKey from file, which could be encrypted with dbfhide. The question is: is it possible to specify encryption key to dbunload via file instead of doing this explicitly?
another question is: how to decrypt from command line file encrypted with dbfhide? is there a command to the utility?
another question is: is it possible to clean up transaction history and clean up logically deleted parts of the data base without using dbunload utility (e.g. via some sql code)?
asked 25 May '15, 12:52
To put the database encryption key in a file and then use the file as part of a connection string (for the purposes of autostarting a database) you need to use a FILEDSN.
E.g. Put these lines in a file (say "mydb.key"):
Then use the connection string:
If you want you may then obfuscate the file containing the key. Example:
You would then use this connection string:
There is no command to de-obfuscate the obfuscated file created by dbfhide (that would defeat the purpose, wouldn't it!).
I think your last question is about recovering space in your database file? If this is the question then the only way to "shrink" the database file is to rebuild it (e.g. via dbunload -an|-ar). But note that there is rarely a reason to do this since the unused space in the database file will get reused when you add more data into the database.
Note: In the future I would suggest that you put each of your questions in a separate question on this forum. This makes it easier for people to answer your questions as well as future visitors to find answers to their questions that are similar to yours.
If you have separate questions, usually it's a better idea to post multiple questions on the forum. In this case, I know the answers to the first two questions but not the third.