[gdal-dev] GDAL SQLITE ID reserved column issue

MRRAJESH rajeshreddy82 at gmail.com
Fri Jul 10 01:38:50 PDT 2020


Developers,
I am using ogr2ogr.

My Test json file is having ID property -

{"type":"Feature","id":"XX","geometry":{"type":"Point","coordinates":[-9944478.9237651918,5330546.6922583049]},"properties":{*"ID"*:"NorthWest
Territory","ToolTip":"NorthWest","Label":"Corporate Operations Boundary
7679755"}}}

My VRT file is -

<?xml version="1.0" encoding="utf-8"?>
<OGRVRTDataSource>
  <OGRVRTLayer name="Schematic">
    <SrcDataSource>C:\Test.json</SrcDataSource>    
    <SrcSQL dialect="sqlite">SELECT * FROM "Test"</SrcSQL>
  </OGRVRTLayer>
</OGRVRTDataSource>

SQLITE is unable to create a virtual table with "ID" property column since
"id" is already there as reserved index column hence the problem.

How to overcome this issue?

Regards,
Rajesh



--
Sent from: http://osgeo-org.1560.x6.nabble.com/GDAL-Dev-f3742093.html


More information about the gdal-dev mailing list