|
|
# DeStatis fetcher
|
|
|
|
|
|
## Glossary
|
|
|
- Wert: value
|
|
|
- Fall: default value
|
|
|
- Ganz: whole
|
|
|
- Jahr: Year
|
|
|
|
|
|
## Categories
|
|
|
Category ids selected by Thomas are:
|
|
|
_Chosen by Thomas_
|
|
|
- 51 Foreign Trades
|
|
|
- 61 Prices
|
|
|
- 62 Earnings, Labour costs
|
... | ... | @@ -10,9 +15,22 @@ Category ids selected by Thomas are: |
|
|
- 71 Public finances
|
|
|
- 81 National accounts of the federation
|
|
|
|
|
|
## Glossary
|
|
|
- Wert: value
|
|
|
- Fall: default value
|
|
|
- Ganz: whole
|
|
|
- Jahr: Year
|
|
|
## Download
|
|
|
Download operation needs an account (username, password).
|
|
|
|
|
|
For each category, a datacubes file is downloaded from URL
|
|
|
```
|
|
|
curl "https://www-genesis.destatis.de/genesisWS/web/RechercheService_2010?method=DatenKatalog&kennung={USER_NAME}&passwort={PASSWORD}&filter={CAT}*&bereich=Alle&listenLaenge=&sprache=en" -o {CAT}/{CAT}.datacubes.xml
|
|
|
```
|
|
|
|
|
|
Parsing the datacubes file, we extract datacube ids for this category and retrieve all datacube structure file:
|
|
|
̀```
|
|
|
curl "https://www-genesis.destatis.de/genesisWS/web/ExportService_2010?method=DatenAufbau&kennung={USER_NAME}&passwort={PASSWORD}&namen={DATACUBE_CODE}&bereich=Alle&sprache=en" -o {CAT}/{DATACUBE_CODE}.structure.xml
|
|
|
```
|
|
|
and datacube value file:
|
|
|
```
|
|
|
curl "https://www-genesis.destatis.de/genesisWS/web/ExportService_2010?method=DatenExport&kennung={USER_NAME}&passwort={PASSWORD}&namen={DATACUBE_CODE}&bereich=Alle&format=csv&werte=true&metadaten=false&zusatz=false&startjahr=&endjahr=&zeitscheiben=&inhalte=®ionalmerkmal=®ionalschluessel=&sachmerkmal=&sachschluessel=&sachmerkmal2=&sachschluessel2=&sachmerkmal3=&sachschluessel3=&stand=&sprache=en" -o {CAT}/{DATACUBE_CODE}.xml
|
|
|
`̀``
|
|
|
|
|
|
|
|
|
|