[QGIS-trac] [Quantum GIS] #1525: graticule creator: don't use reserved SQL words as column names

Quantum GIS qgis at qgis.org
Tue Feb 3 08:38:30 EST 2009


#1525: graticule creator: don't use reserved SQL words as column names
---------------------------------------------------------+------------------
   Reporter:  neteler                                    |              Owner:  nobody       
       Type:  bug                                        |             Status:  new          
   Priority:  critical: causes crash or data corruption  |          Milestone:  Version 1.0.1
  Component:  Vectors                                    |            Version:  1.0.0        
   Keywords:  graticule                                  |   Platform_version:               
   Platform:  All                                        |           Must_fix:  No           
Status_info:  0                                          |  
---------------------------------------------------------+------------------
 The changeset r8183 introduced the use of a reserved SQL word ('Column')
 as column name which renders the import of a graticule (SHAPE) file rather
 hard:

 {{{
 GRASS 6.5.svn (latlong_tbe_climate):~ > v.in.ogr italy_white_box_LL.shp
 out=italy_white_box_LL
 Projection of input dataset and current location appear to match
 Layer: italy_white_box_LL
 DBMI-DBF driver error:
 SQL parser error: syntax error, unexpected COLUMN, expecting NAME
 processing 'Column'
 in statement:
 create table italy_white_box_LL (cat integer, LabelX double precision,
 LabelY double precision, LblOffsetX integer, LblOffsetY integer, Label
 varchar ( 80 ), Row varchar ( 80 ), Column varchar ( 80 ), RowCol varchar
 ( 80 ))
 Error in db_execute_immediate()

 ERROR: Unable to create table: 'create table italy_white_box_LL (cat
        integer, LabelX double precision, LabelY double precision,
        LblOffsetX integer, LblOffsetY integer, Label varchar ( 80 ), Row
        varchar ( 80 ), Column varchar ( 80 ), RowCol varchar ( 80 ))'

 }}}

 Ref: http://developer.mimer.com/validator/sql-reserved-words.tml

 Please select a different column name - suggestion: e.g., add a preceding
 "g" for graticule.

-- 
Ticket URL: <http://trac.osgeo.org/qgis/ticket/1525>
Quantum GIS <http://qgis.org>
Quantum GIS is an Open Source GIS viewer/editor supporting OGR, PostGIS, and GRASS formats


More information about the QGIS-trac mailing list