• hunchback (11/12/2013)


    Because the requirement is to have an xml file, not a caracter text one, with the prolog / encoding / descriptor or whatever it is. SQL Server does not allow us to do it as of today.

    Question: why not to use the fs to accomplish it?

    I'm not sure what the difference between an xml file and a character text file is from your perspective...

    If you'd use Alans approach (equal to the one you mentioned in your very first post) and save the result set with an xml extension instead of a txt extension, what would be wrong with it?

    From my point of view a xml file is nothing else but a character text file with a specific structure and a dedicated file extension. So, if the content of the file is valid (as it would be with Alans approach) and the file extension is correct (which is easy to accomplish) then I don't see any reason why this file would not getting processed as a xml file.

    There's still a good chance for me being totally off track here. But I'd like to see an actual example from your side where you can't get a xml file using Alans approach (table def, sample data, current code for the complete task and expected result - including file name).

    It seems like the missing link is what you define as "xml file formatted output". Is this the content of a file physically stored on the drive? Or any "representation" of a "Wannabe-file"?

    Please note that we neither have all the information you have nor can we look over your shoulder (except for the folks working for NSA...). All we have ist what you've posted so far. And, at least to me, it's not a clear picture. Yet.



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]