Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: Import excel issues stata12


From   [email protected] (Kevin Crow, StataCorp LP)
To   "[email protected]" <[email protected]>
Subject   Re: st: Import excel issues stata12
Date   Thu, 07 Jun 2012 07:09:15 -0500

Katherine Sawyer <[email protected]> inquired about
using -import excel- to import online files:

>Hello, has anyone been able to import an online excel file directly
>into stata 12 without saving first?  I need to write a loop to pull
>multiple datasets from online, so I am trying to bypass manually
>opening and saving them first.  When I try the following code:
>
>import excel http://www.pcr.uu.se/digitalAssets/64/64466_UCDP_DyadicDataset_v12
>011.xls, sheet("UCDP DyadicDataset") firstrow clear
>
>I get this error:  file
>http://www.pcr.uu.se/digitalAssets/64/64466_UCDP_DyadicDataset_v12011.xls
>could not be loaded
>r(603);
...

-import excel- can not open online Excel files.  We'll make this functionality
available in a future update.  Katherine can use the -copy- command to copy the
file to her local computer and then use the -import excel- command to read in
her data.  Note that there is no performance penalty to first using -copy- to
bring down a file from a URL and then using -import excel- to import it.  When
we add this feature to -import excel- we will use the -copy- command to bring
down the file to a temporary file which would then be imported.


-Kevin Crow
 [email protected]
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index