Link to home
Start Free TrialLog in
Avatar of emailamos
emailamos

asked on

OPENROWSET from a network share drive

SELECT * FROM OPENROWSET (BULK '\\mynetworksharedrive\XML\Output_Files\test.xml', SINGLE_BLOB) AS Data

I'm trying to read the xml from a network sharedrive but wasn't successful, tried using a 'C:\XML\Output_Files\test.xml' is okay, but the xml file would eventually stored in a network drive rather than my c drive or the database server c drive.

Is there a way to mapped it to a network drive?
Avatar of RiteshShah
RiteshShah
Flag of India image

create one windows user, give full permission to "Output_files" folder to that user, create login for that windows user in sql server,

Once you done with that, login to your SSMS with windows authentication and you will be ok
ASKER CERTIFIED SOLUTION
Avatar of RiteshShah
RiteshShah
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of emailamos
emailamos

ASKER

yes, thanks