Viewing 5 posts - 1 through 5 (of 5 total)
The following format will get the desired info.
DECLARE @xmlFile XML
SET @xmlFile = (SELECT * FROM OPENROWSET(BULK 'c:\myxml.xml', SINGLE_CLOB) AS xmldata)
SELECT @xmlFile.value('(//*/process/@currentdb)[1]', 'varchar(10)') AS DatabaseID
Refer to http://msdn.microsoft.com/en-us/library/ms178030.aspx for details.
March 8, 2012 at 4:41 pm
I had the same issue a while back and this got fixed after installing SQL 2008 R2 SP1. Here is the related links-
January 17, 2012 at 12:43 pm
The OP has used bad language. Please do not respond to the post.
July 22, 2009 at 2:54 pm
You can use the PIVOT relational operator to do this.
If the listColumnID is static you can use the following:
select listRowID,[1] as col1, [2] as col2,[3] as col3, [6] as...
March 20, 2009 at 4:35 pm
How about this one?
with cte as
(
select *, Row_Number() OVER(PARTITION BY ID ORDER BY ID) as RowNum
from #TempStk
)
select a.rownum, a.id, a.status, a.date, a.quantity,
...
February 25, 2009 at 4:52 pm
Viewing 5 posts - 1 through 5 (of 5 total)