Getting ErrorCode from ErrorNumber
I am getting errornumber from ssis packages using system variables likes system::errorCode. I would also like to have errorCode(hexacode). We capture this info into a table. I could not get the hexa error code during the runtime. So, I made a column ErrorCode varbinary(20) and after the package finished running, I run the below update query to get the hexa errocode. Update table set HexaErrorCode = ErrorNumber and I see hexaErroCode ErrorNumber Column is int data type. Example: I have a ErrorNumber -2146828218 and when I ran the update command, I got 0x800A0046 as ErrorCode. similarly for ErroNumber -1073548540, I got ErrorCode 0xC002F304 . I double checked to see if the conversion code right, and it turned out to be right.Is this a right way to get errorCode?? Thanks.
August 8th, 2012 6:07pm

Hi Anu, Yes this is the right way to get the correct hex error code. Refer to the link to get more information on the same. Regards, Vinaya
Free Windows Admin Tool Kit Click here and download it now
August 8th, 2012 6:43pm

System::ErrorCode provides it, see an example in this blog post on how to configure custom logging: http://consultingblogs.emc.com/jamiethomson/archive/2005/06/11/ssis_3a00_-custom-logging-using-event-handlers.aspxArthur My Blog
August 8th, 2012 6:45pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics