Reading from a document without using OPENROWSET

  • Hi,

    I would like to know if there is any method to read from an xml document without using OPENROWSET function.

    This is necessary because I donot have execute permissions for the OPENROWSET function due to security reasons.

    My task is to read from an xml document and insert the contents into the database. As of now I am doing this by copying and pasting the contents of the xml file and assigning it to an nvarchar variable.

    I would like to get this automated by specifying the path of the file without using the Openrowset function.

    Any help would be greatly appreciated

  • if openrowset is disabled, then most likely xp_cmdshell and sp_OACreate are disabled as well, which were your other options...

    I think in this case, the solution is to NOT do it in TSQL, but create an application that opens the document, connects to SQL server, and finally inserts or updates your table with teh document in question... THAT could be automated a lot easier.

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply