Viewing 15 posts - 46 through 60 (of 367 total)
WITH ordered
AS (SELECT UNIT
,ORDER_DATE
,rn1 = ROW_NUMBER...
February 9, 2025 at 10:14 pm
You could change the approach to use a script task to execute your powershell script. However, if you can do this in PS - then you almost certainly can...
February 7, 2025 at 12:54 am
How are you specifying to run PowerShell, as a scripting task? Spitballing here, but could you run it as an Execute Process Task, with powershell.exe as the executable? Then...
February 6, 2025 at 6:12 am
I said 'add another THROW', not 'add another THROW 51000, '2. One or more stored procedures had errors, please investigate', 1;'!
Also, surely you want the INSERT to dbo.RunTimeErrors to...
February 3, 2025 at 8:46 pm
Did you add another THROW in the final CATCH block, like I suggested?
If yes, please post the code.
Yes I did. If I add the second THROW then the table...
February 3, 2025 at 5:49 pm
No, only 1 TV is required. You simply run multiple INSERTS to it in your code.
To make the error appear in the SSIS Output window, you need to add...
February 3, 2025 at 5:33 pm
Instead of logging your errors in a physical table (whose changes are being rolled back, I assume), log them in a table variable and then insert from the table...
February 3, 2025 at 4:23 pm
I swapped things around a bit. Obviously, I cannot test it.
ALTER PROCEDURE dbo.RunStoredProcedures
AS
SET NOCOUNT ON;
DECLARE @FAIL_COUNT INT = 0;
BEGIN TRANSACTION;
BEGIN TRY
BEGIN TRY
...
February 3, 2025 at 3:46 pm
I made some progress on this.
Code:
ALTER procedure [dbo].[RunStoredProcedures]
as
DECLARE @FAIL_COUNT INT = 0
BEGIN TRANSACTION
BEGIN TRY
BEGIN TRY
truncate table dbo.temptable
END TRY
BEGIN CATCH
SET @FAIL_COUNT = @FAIL_COUNT + 1
END CATCH
BEGIN...
February 3, 2025 at 5:29 am
I have been thinking more about this. I don't think relying on SSIS output window is the right way to capture errors. I need a persistent record of errors (not...
February 3, 2025 at 2:06 am
deleted reply
February 3, 2025 at 1:54 am
Thank you!
I have some questions:
1. re the output parameter option solution. Will that message show up in the output window?
2. re the alternative solution. I am getting an error message...
February 2, 2025 at 10:11 pm
Actually...the above two outputs are not that important. The SP is run in SSIS so I never see the above two issues. Ok for now.
The more pressing issue...
February 2, 2025 at 4:18 am
Actually...the above two outputs are not that important. The SP is run in SSIS so I never see the above two issues. Ok for now.
The more pressing issue is that...
February 2, 2025 at 2:58 am
Thanks for the reply. That is the entire code. Not sure where/how it got -6. Any ideas on how it got there?
February 1, 2025 at 9:33 pm
Viewing 15 posts - 46 through 60 (of 367 total)