cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Roman1
Level 9

Extract packed script.sql from msi

Hello,
I have build a MSI setup with sql - Script.
Now, I am trying to edit msi file to see (extract) the original Sql text file.

I try to export sql script from ISSQlScriptFile [Binary Data] to a text file as target.
No SQl text is exported.
The same if I use orca as msi editor.

Is this possible to do this?
Labels (1)
0 Kudos
(3) Replies
Marwan
Level 7

For security, the script is encrypted and then stored in the MSI package.
0 Kudos
Roman1
Level 9

How to decrypt it?
0 Kudos
JesseBearden
Level 5

I'd really like to look at this too. I'm having issues where a patch isn't running the correct SQL script, and it'd be nice to compare the the patch version and the original version.

For what it's worth Roman, you can look at it by:
1) Run the installation with a log file.
2) After the sql scripts have run, press the cancel button to pause the installation(This may not actually be necessary, I don't know).
3) Open the log file and find the part where the sql scripts are running. You should see the name of the sql script, and what the temp file for it is. For example:

1: Prepare executing SQL script file: 'MyScript.sql'. Path: 'C:\DOCUME~1\admin\LOCALS~1\Temp\~39.tmp' 


Find that file and open it. If you do it after the SQL script has been run, then it should be un-encrypted.
0 Kudos