rschmehl
asked on
how do i read this sql code
hello,
I think i'm having a brain cramp. but the exec @failing stored proc ..output
followed by if @failing > 0
is throwing me off here. Can someone explain how to "read" the code .
Is the output stATEMENT rEPLACING THE @FAILING WITH THE return code being st in the stored proc if it errors out?
set @LocalProcedure = 'up_XL_zUpdateStgSiteToSit e'
exec @Failed = JabilDBImport.dbo.up_zUpda teImportJo bEvent
@ImportJobID = @ImportJobID,
@Event = 'Update Site',
@StartDTS = @CreateUpdateDTS,
@AddMessage = 'Started',
@Status = 'Processing...',
@EndDTS = null
exec @Failed = up_XL_zGetDataSourceID @ImportJobID, @DataSourceID OUTPUT
if @Failed <> 0
begin
-- ams 7/9/02 c1/a2
--RAISERROR('up_zUpdateStg SiteToSite ',18,1)
set @ErrorMessage = @LocalProcedure + ' - Error calling up_XL_zGetDataSourceID'
RAISERROR(@ErrorMessage,18 ,1)
return 1
end
I think i'm having a brain cramp. but the exec @failing stored proc ..output
followed by if @failing > 0
is throwing me off here. Can someone explain how to "read" the code .
Is the output stATEMENT rEPLACING THE @FAILING WITH THE return code being st in the stored proc if it errors out?
set @LocalProcedure = 'up_XL_zUpdateStgSiteToSit
exec @Failed = JabilDBImport.dbo.up_zUpda
@ImportJobID = @ImportJobID,
@Event = 'Update Site',
@StartDTS = @CreateUpdateDTS,
@AddMessage = 'Started',
@Status = 'Processing...',
@EndDTS = null
exec @Failed = up_XL_zGetDataSourceID @ImportJobID, @DataSourceID OUTPUT
if @Failed <> 0
begin
-- ams 7/9/02 c1/a2
--RAISERROR('up_zUpdateStg
set @ErrorMessage = @LocalProcedure + ' - Error calling up_XL_zGetDataSourceID'
RAISERROR(@ErrorMessage,18
return 1
end
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks alot
ASKER