Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • SharePoint lists: Can STATA consume Web Services?

    Hello everybody,

    I have to download a SharePoint list making some calculations with STATA and then uploading the list again (This is a daily routine).

    My question is: Can STATA consume Web Services?

    At the moment we are using ACCESS has a bridge but this is an unstable system.

    I also read about the possibility to install the 'R' in stata, but I seems complicated

    Thanks a lot,

    Quim Barris


  • #2
    Yes

    Comment


    • #3
      Hi Quim,

      you should clarify your question. What kind of web service is it you want to read from / write to? Especially in terms of: What is the exchange format of the web service? If it is a comma delimited or fixed width plain text format, all you need to do is
      Code:
      import delimited using "<URL>"
      As long as your question is unspecific, Sergiy's answer is totally correct: Stata can consume web services.

      All Stata commands for opening and saving data nowadays are capable of directly accessing online files via URLs. This should be sufficient. If the format your web service exports is more elaborate (like JSON or such), you have to look for a Stata ado package that is capable of reading it (like -insheetjson- from SSC).

      Regards
      Bela

      PS: And please note, as per FAQ, it is "Stata", not "STATA" or "stata".

      Comment


      • #4
        Dear Daniel,

        The URL for our SharePoint web services is https://<HOST_NAME>/<TEAM_SITE>/_vti_bin/Lists.asmx; this web service is a SOAP web service and, thus, returns XML data.

        Thanks a lot,

        Quim

        Comment


        • #5
          I have only recently figured out how to upload/save to sharepoint directly from Stata. Stata cannot save directly to a web address. However, with a sharepoint address such as:
          https://siteadress/foldername/subfolder/docname.dta

          Use the following command to save directly from within Stata:
          Code:
          save "\\siteadress@SSL\foldername\subfolder\docname.dta"
          This also works for export commands such as -export excel- If you are unsure on the correct address open sharepoint folder directly in windows explorer , then SHIFT right click on a file to copy as path.

          Comment

          Working...
          X