0

I want to save the result of the same query done on using Data Explorer using a script but it doesn't seem to work properly because I get the same set of results.

wget -q --timestamp http://data.stackexchange.com/superuser/csv/73895  -O data-active-users-superuser.csv
wget -q --timestamp http://data.stackexchange.com/apple/csv/73895  -O data-active-users-apple.csv

Note: I need a scriptable solution :)

1
  • After executing that, both files are empty for me apart from the headings. Same for direct download in the browser. The respective query URLs seem to work, however.
    – user154510
    Jun 26, 2012 at 22:10

1 Answer 1

3

If you're trying to get the CSV files of this query, you're using the wrong URL. The correct one (for the current version of the query) would be:

https://data.stackexchange.com/stackoverflow/csv/82441

Swapping in the appropriate site names in the URL should produce the right results for each site.

Also, I'm not sure that script-based access to the CSV files is necessarily an intended use-case, so I'd recommend against requesting the results for too many queries too quickly.

2
  • Is there a way of getting the URL of the latest version of a query? Or the only way to link is to a specific version?
    – sorin
    Jul 4, 2012 at 14:07
  • You have to request the results of a specific revision. Since you don't necessarily know what changed between revisions without checking for yourself, using a particular manually-selected revision seems like the safer approach anyway.
    – Tim Stone
    Jul 4, 2012 at 14:09

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .