[Gdal-dev] OCI-Import

Frank Warmerdam warmerdam at pobox.com
Wed Jan 4 10:28:05 EST 2006


On 1/4/06, Stephan Holl <sholl at gmx.net> wrote:
> I was also told, that this results from the initial CREATE TABLE
> statement, which was done by OGR, where the attribute-columns
> were enclosed in quotes, something like this:
>
> create table dataset (
>      OGR_FID number(38),
>      ORA_GEOMETRY MDSYS.SDO_GEOMETRY,
>      "cat" number(38),
>      "column" number(38),
>      [...]
>   ..... ) storage (...) tablespace ... ;
>
> For a select-statement the columns needs to be in quotes as well,
> otherwise Oracle does not recognize the column-name correct.
>
> Is this a bug or a feature? Does anybody can give me a hint how to get
> arround this?

Stepan,

I suspect the problem is that lower case field names are
being preserved by the quoting of the field name when they
are created (in OGROCIWritableLayer::CreateField()s
ALTER TABLE command.

If this is the issue, then I think a reasonable solution would
be to launder lower case names to upper, either all the time
in CreateField(), or perhaps only when the layer creation option
"LAUNDER" is set true.

Are you building from source?  If so, I could try committing a
change to do this, and you could test it.

Best regards,
--
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent




More information about the Gdal-dev mailing list