![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I have done quite a bit of research on this, but could not find a good answer. I need to get the UNC path from a mapped drive letter where the drive is mapped to another machine (not the SQL Server). The drive is mapped the same on the server and all client stations. My main course was to use sp_OACreate to create a filesystemobject and use the ShareName property of the Drive object. The problem with that is that this only works for the server's local C drive. When I try to use any mapped drive, it fails. Here's what I've tried: |
#3
| |||
| |||
|
|
I have done quite a bit of research on this, but could not find a good answer. I need to get the UNC path from a mapped drive letter where the drive is mapped to another machine (not the SQL Server). The drive is mapped the same on the server and all client stations. My main course was to use sp_OACreate to create a filesystemobject and use the ShareName property of the Drive object. The problem with that is that this only works for the server's local C drive. When I try to use any mapped drive, it fails. Here's what I've tried: |
#4
| |||
| |||
|
|
Actually in this case the server has the same mapped drives as all the users so my question is still applicable. |
#5
| |||
| |||
|
#6
| |||
| |||
|
|
I have done quite a bit of research on this, but could not find a good answer. I need to get the UNC path from a mapped drive letter where the drive is mapped to another machine (not the SQL Server). The drive is mapped the same on the server and all client stations. My main course was to use sp_OACreate to create a filesystemobject and use the ShareName property of the Drive object. The problem with that is that this only works for the server's local C drive. When I try to use any mapped drive, it fails. Here's what I've tried: |
#7
| |||
| |||
|
|
Actually in this case the server has the same mapped drives as all the users so my question is still applicable. |
#8
| |||
| |||
|
|
Matthew Wells (matthew.wells (AT) firstbyte (DOT) net) writes: Actually in this case the server has the same mapped drives as all the users so my question is still applicable. I don't see your machine, but disk mappings are set up when you login, or because you run NET USE manually. I still don't think the service account has any disks mapped. What happens if you try: exec xp_cmdshell 'DIR F:\' assuming that you think F is a mapped disk? |
![]() |
| Thread Tools | |
| Display Modes | |
| |