Re: Getting results of a FOR Command



Guillem

"FOR XML AUTO" is a Microsoft Command to format the results of
the select as XML.

After I execute the full select statement I want to be able to
access the resulting XML Formated data.

Mark Moss


"Guillem" <guillemvicens-nospam@xxxxxxxxxxxxxxxxxx> wrote in message
news:xn0elvczk2odbo000@xxxxxxxxxxxxxxxxxxxxxxxxx
Mark Moss wrote:

Help


I can issue the following command in SQL


Select *
From Customer FOR XML AUTO
Where CustomerID = 19934590

But how do I get the results in my program?


Mark Moss

without knowing what RDBMS you use (not sure what FOR XML AUTO is
either) any select statement will return a set of records, and you can
have it loaded into a TADOQuery or TADODataset without problems using a
TADOConnection to connect to the database, assigning the command to
your dataset and executing it.


--
Best regards :)

Guillem Vicens Meier
Dep. Informatica Green Service S.A.
www.clubgreenoasis.com
--
Contribute to the Indy Docs project: http://docs.indyproject.org
--
In order to contact me remove the -nospam



.



Relevant Pages

  • Re: Getting results of a FOR Command
    ... I can issue the following command in SQL ... From Customer FOR XML AUTO ...
    (borland.public.delphi.database.ado)
  • Re: Retrieve XML Data
    ... Create a SqlCommand object with your select command. ... string query = "SELECT website.websiteID, website.description, ... > FOR XML AUTO, ELEMENTS ...
    (microsoft.public.dotnet.framework.adonet)
  • XML
    ... Have a look at the 'FOR XML' command on BOL for select ... select * from myTable for XML auto ... Peter ...
    (microsoft.public.sqlserver.server)
  • Simple number formatting question
    ... When I execute the command below I get the 'long' format ... laptop running XP. ...
    (comp.soft-sys.matlab)
  • Re: SSIS - Creating an XML File
    ... I see what your trying to do, but I get a syntax error with the format ... > for xml auto, type) as myColumn ... >> XML with the OLEDB Source. ... >> Dave. ...
    (microsoft.public.sqlserver.dts)