[WiX-users] Debugging ExecuteSqlStrings

2008-12-01 Thread Rui Fan (MDT InfoTech)
Hi experts,
I’m using WiX 3. I’m trying to debug a possible error in the sql custom 
action:
MSI (s) (68:B4) [15:49:43:129]: Executing op: 
CustomActionSchedule(Action=ExecuteSqlStrings,ActionType=25601,Source=BinaryData,Target=**,CustomActionData=**)
MSI (s) (68:F8) [15:49:43:139]: Invoking remote custom action. DLL: 
D:\Windows\Installer\MSI612C.tmp, Entrypoint: ExecuteSqlStrings
ExecuteSqlStrings:  CustomActionData: 
CoreSqlDatabase€RUIFANRED280B\MAA€€CoreDB€3€1€€€GrantNetworkServiceAdmin€17€EXEC
 sp_addsrvrolemember NT AUTHORITY\NETWORK SERVICE, ……
MSI (c) (58:30) [15:49:45:118]: Font created.  Charset: Req=0, Ret=0, Font: 
Req=MS Shell Dlg, Ret=MS Shell Dlg

Error 26204. Error -2147217900: failed to execute SQL string, error detail: 
Incorrect syntax near the keyword 'with'. ……
MSI (s) (68!24) [15:49:56:154]: Product: Microsoft MAA - Core Database -- Error 
26204. Error -2147217900: failed to execute SQL string, error detail: Incorrect 
syntax near the keyword 'with'. If this statement is a common table expression, 
an xmlnamespaces clause or a change tracking context clause, the previous 
statement must be terminated with a semicolon., SQL key: CoreDBSBSQLScript SQL 
string: riginal error information.
……
Action ended 15:49:56: InstallFinalize. Return value 3.

I found a function called “ExecuteSqlStrings” under serverca\scaexec. I can’t 
find the generated scaexec.dll in wix3-binaries.zip. But I can find it in the 
msi package. Where did this file come from? And I also tried to add 
“DebugBreak()” in “ExecuteSqlStrings” but it doesn't work.
Which can I find the correct entry point of ExecuteSqlStrings? Which is the 
correct file and line to set break points?
And do you have any best practice to debug a running custom action?

Thanks,
Rui
-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/
___
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users


Re: [WiX-users] Debugging ExecuteSqlStrings

2008-12-01 Thread Bob Arnson
Rui Fan (MDT InfoTech) wrote:
 Error 26204. Error -2147217900: failed to execute SQL string, error detail: 
 Incorrect syntax near the keyword 'with'. ……
 MSI (s) (68!24) [15:49:56:154]: Product: Microsoft MAA - Core Database -- 
 Error 26204. Error -2147217900: failed to execute SQL string, error detail: 
 Incorrect syntax near the keyword 'with'. If this statement is a common table 
 expression, an xmlnamespaces clause or a change tracking context clause, the 
 previous statement must be terminated with a semicolon., SQL key: 
 CoreDBSBSQLScript SQL string: riginal error information.
 ……
   

The error message is coming from SQL, not the custom action. You'll have 
better luck debugging the SQL strings.

 I found a function called “ExecuteSqlStrings” under serverca\scaexec. I can’t 
 find the generated scaexec.dll in wix3-binaries.zip. 

It's embedded in WixSqlExtension.dll. If you want to debug the code, 
you'll need to rebuild the scaexec.dll and WixSqlExtension.dll.

-- 
sig://boB
http://joyofsetup.com/



-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/
___
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users