Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

FOR XML AUTO

Status
Not open for further replies.

mbde

Programmer
Mar 14, 2005
55
US
Here is the challenge (that's reverse psychology I am really asking for help), using only Sql 2000

I have a SqlStatement that I want to turn into a xml doc.

select
A.Name
, A.Id
, B.StartDate
, B.EndDate
, B.Value

from
A
INNER JOIN
B
ON A.Name = B.IndexName
where A.Name ='C'
for xml auto

All columns must be attributes. Export a well formatted xml document.

Let me Add where I failed. A and B have a 1 to many relationship. The text comes out fine in QA or QA->TextFile The one problem is the hardline breaks in the middle of data, that makes it not well formatted.
When I try to use DTS to export to a text file, it is base 64 encoded and I do not know how to turn that off.

I visited and that did not help much because even with DBCC Trace on there are still line wraps.

TY
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top