Skip to content

Different dates on the updated timestamp #647

@likp

Description

@likp

Describe the bug
When using the API I get

To Reproduce
When lsiting the database content with

GET: https://api.scb.se/OV0104/v1/doris/sv/ssd/START/TK/TK1001/TK1001Z

I get

[
                             {
                                                          "id": "PersBilarDeso",
                                                          "type": "t",
                                                          "text": "Personbilar, registrerade på folkbokförda personer 31 december, efter status och region. År 2015 - 2023",
                                                          "updated": "2024-04-12T08:00:00"
                             }
]

But when I extract data with

POST: https://api.scb.se/OV0104/v1/doris/sv/ssd/START/TK/TK1001/TK1001Z/PersBilarDeso

{
  "query": [
    {
      "code": "Region",
      "selection": {
        "filter": "vs:DeSoHE",
        "values": [
          "0180C1010"
        ]
      }
    },
...
  ],
  "response": {
    "format": "json"
  }
}

I get

{
                             "columns": [
                                                          {
                                                                                       "code": "Region",
                                                                                       "text": "region",
                                                                                       "type": "d"
                                                          },
...
                             ],
                             "comments": [],
                             "data": [
                                                          {
                                                                                       "key": [
                                                                                                                    "0180C1010",
                                                                                                                    "ITRAF",
                                                                                                                    "2023"
                                                                                       ],
                                                                                       "values": [
                                                                                                                    "336"
                                                                                       ]
                                                          }
                             ],
                             "metadata": [
                                                          {
                                                                                       "infofile": "TK1001",
                                                                                       "updated": "2024-04-11T06:53:00Z",
                                                                                       "label": "Personbilar i trafik registrerade på folkbokförda personer 31 december efter region, status, år och tabellinnehåll",
                                                                                       "source": "Trafikanalys"
                                                          }
                             ]
}

Expected behavior
I whould expect that the date should be the same

Actual behavior
They differ

Additional context
Use the publishing only the Publish date.

Original question by user of Statistics Swedens Statistikdatabasen service.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions