July 6, 2009 at 7:44 pm
remove the extra quotes from the xml if there are some, replace for the scape code for xml, i dont remember the code, but, that should work. there are some at the inch numbers for disk size.
regards.
July 6, 2009 at 7:50 pm
PEPEPACO_1980 (7/6/2009)
remove the extra quotes from the xml if there are some, replace for the scape code for xml, i dont remember the code, but, that should work. there are some at the inch numbers for disk size.regards.
What do you mean "replace for the scape code for xml"?
July 6, 2009 at 7:56 pm
removed the quotes, still no luck.
July 6, 2009 at 8:08 pm
Would you be willing to connect to my machine via netmeeting so we could figure out what is wrong?
July 6, 2009 at 8:52 pm
This web site has a history of mucking up xml text. I suggest that you attach a file with your xml code in it - save it as a .txt file and use the "Edit Attachments" button at the bottom of the message composer dialog screen to attach it to this message.
Some of the problems is that some browsers change the case of the xml elements to upper code, while other browsers change it to lower case. Since XML is case sensitive, it can easily throw everyone off.
Note that they are working on the problem, but for now this is your best bet. Give it a try.
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
July 6, 2009 at 9:05 pm
If you go back to the original post, and press the quote button, you well see that the element are in mixed case. Your browser may display them as upper or lower case... this is a glitch with the code windows on this web site.
So, this code posted previously:
select Tbl.C.value('@name', 'nvarchar(50)') as [name] ,
Tbl.C.value('@val', 'nvarchar(50)') as val,
Tbl.C.value('@count', 'nvarchar(50)')as [count],
(select Tbl.C.value('@rsid', 'nvarchar(50)')as rsid
from @FileContents2.nodes('/solution/specifications/sessiondata') AS Tbl(C) ) as rsid
from @FileContents2.nodes('/solution/results/financialresults/modelstotal/product') AS Tbl(C)
will always return zero rows. Because it should be "nodes('/Solution/Specifications/SessionData')" and "nodes('Solution/Results/FinancialResults/ModelsTotal/Product')". And "value('@Name')", "value('@Val')", "value('@Count')" and "value('@RSID')"
However, if you change the case of the elements referenced in the nodes(), and the element names prefixed by a @ to match what is in your file, I think this may work for you. XML is case sensitive, and this alone may fix your issue.
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
July 6, 2009 at 9:36 pm
Thank You! That fixed it. This is a super forum.
July 6, 2009 at 10:23 pm
im glad it works for you!
regards.
Viewing 8 posts - 31 through 37 (of 37 total)
You must be logged in to reply to this topic. Login to reply