Viewing 15 posts - 46 through 60 (of 13,838 total)
If you import the data into a table using all of the available outputs, is the data you require imported as part of that (contained in one of the imported...
April 10, 2025 at 9:45 am
What this is really supposed to do is making a dynamic pivot table.
This might be of interest:
https://www.sqlservercentral.com/articles/cross-tabs-and-pivots-part-2-dynamic-cross-tabs
April 9, 2025 at 3:08 pm
I think that the temp table is scoped to the subprocess spawned by the EXEC statement.
If you concat the INSERT and SELECT statements to your @sql variable, with semicolon delimiters,...
April 9, 2025 at 1:57 pm
Is this a SQL Server question? Not sure I follow.
April 4, 2025 at 4:33 pm
I've now tried migrating from SSIS to Data Factory twice. The first time (three years ago) failed because DF could not do the things we needed. The second time was...
April 3, 2025 at 9:32 pm
Hi Phil - this is adding an ID of zero into the 'unioned' result - I need the second part of this union to effectively inherit the ID from...
April 3, 2025 at 3:34 pm
No problem. Just create a fake matching column in the STRUCTURE dataset (make sure its datatype matches what's in SOURCE)
SELECT Cols, Id
from Source
UNION ALL
Select Cols, Id...
April 3, 2025 at 2:57 pm
SELECT cols FROM TableA
UNION ALL
SELECT Cols FROM TableB b
WHERE NOT EXISTS (SELECT 1 FROM TableA a WHERE a.START = b.START)
April 3, 2025 at 1:10 pm
Something like this, perhaps?
UPDATE dt
SET dt.tagid = nt.id
FROM dbo.DataTable dt
JOIN dbo.OldTable ot
ON ot.id = dt.tagid
...
April 2, 2025 at 9:15 pm
Oh wait, I got it sorry
Bravo!
April 2, 2025 at 1:29 pm
Once you have created your set-based update code, consider adding an OUTPUT clause to it. This will allow you to capture the before and after state of the rows which...
April 2, 2025 at 12:05 pm
Not sure who marked your last post as spam, it wasn't me.
That is a mega query. Not one for someone who is 'new to the development side', in my opinion...
April 1, 2025 at 2:15 pm
I tried that and the columns still don't show up. It must be deeper in this mess. I'm still looking and again I appreciate your input.
There must be more...
April 1, 2025 at 1:29 pm
Right after the final ), add the following and see what happens:
SELECT d.Code
,d.CoName
,d.TerName
...
April 1, 2025 at 12:53 pm
Well, it should work, but without seeing your code, we cannot diagnose your issue. Try running this, for example
DROP TABLE IF EXISTS #SomeData;
CREATE TABLE #SomeData
(
...
April 1, 2025 at 12:19 pm
Viewing 15 posts - 46 through 60 (of 13,838 total)