SAS Data Integration Studio, DataFlux Data Management Studio, SAS/ACCESS, SAS Data Loader for Hadoop and others

import file from network device

Accepted Solution Solved
Reply
New Contributor
Posts: 3
Accepted Solution

import file from network device

Hi,

I can't see server's network device on "Browse" button when I try to create a new "external file".

Can anyone helps me?

Thank


Accepted Solutions
Solution
‎10-08-2013 07:41 AM
New Contributor
Posts: 3

Re: import file from network device

Posted in reply to mario1ghz

OK,

I never can see network device mapped,  But I can use the phisical network path:

\\<nome:server>\<path in the server>\nome_file.csv

It works.

Thanks,

Mario

View solution in original post


All Replies
Respected Advisor
Posts: 4,173

Re: import file from network device

Posted in reply to mario1ghz

Don't forget that this must run on the SAS server not your workstation. So any mapping used must be on the server. You normally need to use UNC paths.

New Contributor
Posts: 3

Re: import file from network device

On server explorer I can see Phisical drive A: C: D: and network location: B: U: L: that I already mapped.

From Data Integration Studio Browse I can see only the phisical ones.

Respected Advisor
Posts: 4,173

Re: import file from network device

Posted in reply to mario1ghz

Currently I don't have access to an environment to replicate what you describe so I can't give you a advise for your concrete question.

The approach I'm usually taking is to define the "root" UNC path as macro variable in an autoexec set up for DI jobs. Then I use this macro variable as part of the file path in the external file definition.

I make always sure that the application specific folder structures are the same in all environments so that I can migrate DI jobs between environments without any changes. I need only to populate the macro vars in the autoexec with different UNC paths.

So a filename used in the external file could look like:

&root_path1\folder1\external_file.csv

And then make sure that you also select "double quotes" for the filename.

The only disadvantage to this approach is that when you click on the external file metadata object you can't access the underlying data as there the macro variable doesn't get resolved. I couldn't figure out yet (and haven't also invested too much time with it) if there would be a way to define the macro variable also somewhere else so that the pathname gets always resolved.

I believe the advantage of this approach is that you don't need to map network drives on the server. In my experience mapping networks on the server is something the server admins in a lot of organisations are very resistant to do.

Super Contributor
Posts: 297

Re: import file from network device

Posted in reply to mario1ghz

You can use the following code to map a network drive to the SAS Server.  \\READYSHARE\USB_Storage is the UNC path you wish to map to t:\.

DATA _NULL_;

X 'NET USE T: \\READYSHARE\USB_STORAGE';

RUN;

If you want to know more then check out How to Map Network Drives From the Command Prompt in Windows.

Solution
‎10-08-2013 07:41 AM
New Contributor
Posts: 3

Re: import file from network device

Posted in reply to mario1ghz

OK,

I never can see network device mapped,  But I can use the phisical network path:

\\<nome:server>\<path in the server>\nome_file.csv

It works.

Thanks,

Mario

🔒 This topic is solved and locked.

Need further help from the community? Please ask a new question.

Discussion stats
  • 5 replies
  • 2472 views
  • 0 likes
  • 3 in conversation