mirror of
https://github.com/maplibre/martin.git
synced 2024-12-20 21:31:49 +03:00
6b7bcabe49
* Rename `TileCopierOptions` -> `TileCopier` * remove a few un-needed sqlite open to detect mbtiles type * move `open_and_detect_type` to `MBTiles` * add `attach_to` to `MBTiles` * move various table creation fn to mbtiles_queries file * a few sql format
21 lines
1.2 KiB
JSON
21 lines
1.2 KiB
JSON
{
|
|
"db_name": "SQLite",
|
|
"query": "SELECT (\n -- Has a 'tiles_with_hash' table\n SELECT COUNT(*) = 1\n FROM sqlite_master\n WHERE name = 'tiles_with_hash'\n AND type = 'table'\n --\n ) AND (\n -- 'tiles_with_hash' table's columns and their types are as expected:\n -- 5 columns (zoom_level, tile_column, tile_row, tile_data, tile_hash).\n -- The order is not important\n SELECT COUNT(*) = 5\n FROM pragma_table_info('tiles_with_hash')\n WHERE ((name = 'zoom_level' AND type = 'INTEGER')\n OR (name = 'tile_column' AND type = 'INTEGER')\n OR (name = 'tile_row' AND type = 'INTEGER')\n OR (name = 'tile_data' AND type = 'BLOB')\n OR (name = 'tile_hash' AND type = 'TEXT'))\n --\n ) as is_valid;",
|
|
"describe": {
|
|
"columns": [
|
|
{
|
|
"name": "is_valid",
|
|
"ordinal": 0,
|
|
"type_info": "Int"
|
|
}
|
|
],
|
|
"parameters": {
|
|
"Right": 0
|
|
},
|
|
"nullable": [
|
|
null
|
|
]
|
|
},
|
|
"hash": "4905d37cd3818e2fe9f65fdd20437901cbe4b6421bac3cf671e86d4b5d8dc0f3"
|
|
}
|