Viewing 15 posts - 2,581 through 2,595 (of 13,853 total)
I don't know the answer, but if the problem you are having is specifically because of the XML datatype, have you considered casting the XML to NVARCHAR() and then casting...
June 18, 2020 at 10:35 pm
Can you take the XSD out of the equation and parse the source XML directly, using T-SQL (after importing the XML into a staging table)?
Or, as suggested above, a Script...
June 17, 2020 at 10:25 pm
And the problem with your question is that you did not give me the full picture.
Now you are drip-feeding clues into the thread as they come up, which is not...
June 17, 2020 at 9:02 pm
How about this?
SET @qry
= 'SET NOCOUNT ON Declare @days INT select @days=LongValue from ' + @db_name
+ '.dbo.Settings
where...
June 17, 2020 at 8:51 pm
I don't approve of doing this – it wouldn't get past me in a code review – but you can do something like this:
BEGIN TRY
...
June 17, 2020 at 6:59 pm
Sorry for wasting your time all, turns out this package has never been scheduled! There are very similar named packages in the same project, one letter difference! My eyes...
June 17, 2020 at 6:56 pm
Has the history vanished for all projects, or just this one? Or is it just for this one package?
June 17, 2020 at 4:41 pm
Rather than ignoring the error, it would be better to avoid it by first checking for the table's existence:
IF OBJECT_ID('dbo.Test', 'U') IS NOT NULL
BEGIN
-- Add code here
END; June 17, 2020 at 4:37 pm
Wait, dancing? Are we getting a video posted somewhere?
I'm sure he's on Tik Tok already.
June 16, 2020 at 9:37 pm
Another version:
CREATE TABLE #X
(
SomeXML XML
);
INSERT #X
(
SomeXML
)
VALUES
('<Parameters xmlns="http://www.www.com/WebFramework/WorkflowParameters.xsd">
<Parameter Name="ClientID" StringValue="12903166" />
<Parameter Name="Workflow_ActiveSlide" StringValue="317" />
<Parameter Name="Document_First_UserID" StringValue="8577430" />
<Parameter Name="Program" StringValue="120555" />
<Parameter...
June 16, 2020 at 3:07 pm
Jeff, to which article are you referring?
June 15, 2020 at 2:19 pm
Brilliant. Absolutely brilliant! Thank you so much, I'm new to working with JSON in SQL and just couldn't find the right technique. I was able to write a c#...
June 12, 2020 at 1:17 pm
Does this help?
DECLARE @json NVARCHAR(MAX);
SET @json
= N'[{"id":349978,"resource_uri":"https:\/\/api.myapi.com\/rest\/v1.0\/vehicle\/349978","name":"Test Vehicle",
"code":"12345","status":1,"taxable":"state","tank_capacity":0,"product_type":"Allow All","product":[],"custom_data_field":[{"id":1,"label":"Company","value":"2"},
{"id":2,"label":null,"value":null},{"id":3,"label":null,"value":null}],"access_groups":[],"drivers":[]},
{"id":349979,"resource_uri":"https:\/\/api.myapi.com\/rest\/v1.0\/vehicle\/349979","name":"TestVehicle_ONRD","code":"TES123",
"status":1,"taxable":"none","tank_capacity":0,"product_type":"Allow All","product":[],
"custom_data_field":[{"id":1,"label":"Company","value":"70"},{"id":2,"label":null,"value":null},{"id":3,"label":null,"value":null}],"access_groups":[],"drivers":[]}]';
SELECT d.id, cd.value
FROM
OPENJSON(@json)
WITH
...
June 11, 2020 at 9:34 pm
I decided to check this out by running a package in debug mode in VS2019.
When I do this, I see two debug processes, one 32-bit and one 64-bit, suggesting both...
June 11, 2020 at 12:46 pm
Whenever I need to perform this sort of task, I usually do the work in Notepad++, rather than VS.
From what you are saying, I think my approach would be something...
June 11, 2020 at 12:30 pm
Viewing 15 posts - 2,581 through 2,595 (of 13,853 total)