DATA Step, Macro, Functions and more

How to download excel sheet from sharepoint site?

Reply
New Contributor
Posts: 4

How to download excel sheet from sharepoint site?

Hello All,

 

How to read/download excel sheet from Sharepoint site?

 

Regards,

Trivvikrum

 

Super User
Super User
Posts: 7,401

Re: How to download excel sheet from sharepoint site?

Well, Sharepoint can be mapped to a network drive just like any other network drive.  If you speak to your IT group they should be able to help you with this.  Note that your SAS will need to be able to access that network area - i.e. if your SAS is a network then that network needs access rights to Sharepoint - often that is done locally on your machine.  Again, your IT will be able to help with this.

Once you have it linked as a network path, then you simply import as normal:

proc import datafile="d:\<path>\<filename>.xlsx"...

Where D is mapped to the Sharepoint site.

New Contributor
Posts: 4

Re: How to download excel sheet from sharepoint site?

Hi,

This solution doesn't work and it would be good if you provide code as well.

 

//Trivvikrum

Super User
Super User
Posts: 7,401

Re: How to download excel sheet from sharepoint site?

Hi,

 

Assume thats toward me yes?  What "doesn't work"?  The code you want is a simple proc import of a file once you have sharepoint mapped to network drive.  What did your IT group say?

New Contributor
Posts: 4

Re: How to download excel sheet from sharepoint site?

Hi,
I applied below and it worked fine.
proc import datafile='\\sharepointsite\excel.xls*;
run;

Br
Trivvikrum

Contributor
Posts: 50

Re: How to download excel sheet from sharepoint site?

Hello,

 

Just puzzle pieces  never done this before Smiley Happy

How about using the URL access method to get the file and Sharepoint Excel Services REST.

Using the REST API, you can access workbook parts or elements directly through a URL so hopefully it works with filename url access method.

 

Best regards,

Ask a Question
Discussion stats
  • 5 replies
  • 428 views
  • 0 likes
  • 3 in conversation