Skip to main content

I'm trying to write ~20m records to a Geopackage format file. If I remove all but a unique identifier column the output is created and FME runs correctly.

 

If I try adding the original columns the process fails with the following errors. What can I do to fix this?

 

2024-01-04 10:57:31|  1.8| 0.0|ERROR |OGCGEOPACKAGE writer: sqlite3_exec(CREATE TABLE "Table1" ( "id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "geom" POLYGON, "Toid" TEXT(20), "Version" MEDIUMINT, "VerDate" DATETIME, "FeatCode" MEDIUMINT, "Theme" TEXT(80), "CalcArea" REAL, "Change" TEXT(80), "DescGroup" TEXT(150), "DescTerm" TEXT(150), "Make" TEXT(20), "PhysLevel" MEDIUMINT, "PhysPres" TEXT(20), "Broken" SMALLINT, "LoadDate" DATETIME, "OBJECTID" MEDIUMINT, "OSMMSTYLE_NAME" TEXT(70), "Style_Code" SMALLINT, "SHAPE_Length" REAL, "SHAPE_Area" REAL, "_predicate" TEXT(200), "SHAPE_STArea__" REAL, "xml_type" TEXT(12), "TOID" TEXT(16), "VersionDate" TEXT(10), "ThemeCount" SMALLINT, "FeatureCode" SMALLINT, "CalculatedAreaValue" REAL, "ChangeDate" TEXT(10), "ReasonForChange" TEXT(36), "DescriptiveGroup" TEXT(64), "DescriptiveGroupCount" SMALLINT, "DescriptiveTerm" TEXT(128), "DescriptiveTermCount" SMALLINT, "PhysicalLevel" SMALLINT, "PhysicalPresence" TEXT(16), "broken" TEXT(5))) failed: duplicate column name: TOID

2024-01-04 10:57:31|  1.8| 0.0|ERROR |OGCGEOPACKAGE writer: Unable to write feature, aborting write process

2024-01-04 10:57:31|  1.8| 0.0|STATS |Storing feature(s) to FME feature store file `F:\\Temp\\FME_Merging_All_Topo_Area\\Merging_All_Topo_Area_log.ffs'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Feature Type: `Table1'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(16 bit integer): `Broken' has value `0'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(64 bit real)  : `CalcArea' has value `140.062544'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `Change' has value `2003-09-26 New'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `DescGroup' has value `General Surface'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `DescTerm' has value `Multi Surface'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(32 bit integer): `FeatCode' has value `10053'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `LoadDate' has value `20210717123011'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `Make' has value `Multiple'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(32 bit integer): `OBJECTID' has value `27075'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `OSMMSTYLE_NAME' has value `Multi Surface Fill'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(32 bit integer): `PhysLevel' has value `50'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `PhysPres' has value `'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(64 bit real)  : `SHAPE_Area' has value `140.06250000068454'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(64 bit real)  : `SHAPE_Length' has value `89.69451734727787'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(16 bit integer): `Style_Code' has value `1'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `Theme' has value `Land'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `Toid' has value `1000000100719452'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `VerDate' has value `20040730120000'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(32 bit integer): `Version' has value `1'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `_predicate' has value `INTERSECTS'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `fme_feature_type' has value `Topographic_Area_SK1'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `fme_geometry' has value `fme_undefined'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `fme_type' has value `fme_no_geom'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(64 bit integer): `id' has value `1'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `multi_reader_full_id' has value `0.0'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(32 bit integer): `multi_reader_id' has value `0'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `multi_reader_keyword' has value `OGCGEOPACKAGE_1'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `multi_reader_type' has value `OGCGEOPACKAGE'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Attribute(string: UTF-8) : `multi_writer_id' has value `0'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Coordinate System: `OSGB-GPS-2015-OSTN15'

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Geometry Type: IFMENull

2024-01-04 10:57:31|  1.8| 0.0|ERROR |Coordinate Dimension: 2

2024-01-04 10:57:31|  1.8| 0.0|ERROR |===========================================================================

2024-01-04 10:57:31|  1.8| 0.0|ERROR |OGCGEOPACKAGE writer: An error has occurred. Check the logfile above for details

2024-01-04 10:57:31|  1.8| 0.0|INFORM|OGCGEOPACKAGE writer: Committing transaction of 1 features to feature types 'Table1'...

2024-01-04 10:57:31|  1.8| 0.0|ERROR |OGCGEOPACKAGE writer: failed to prepare SQL: SELECT "id", ST_MinX("geom"), ST_MaxX("geom"), ST_MinY("geom"), ST_MaxY("geom") FROM "Table1" WHERE "geom" NOT NULL AND NOT ST_IsEmpty("geom")

2024-01-04 10:57:31|  1.8| 0.0|INFORM|=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

2024-01-04 10:57:31|  1.8| 0.0|INFORM|Feature output statistics for `OGCGEOPACKAGE' writer using keyword `OGCGEOPACKAGE_3':

2024-01-04 10:57:31|  1.8| 0.0|STATS |=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

2024-01-04 10:57:31|  1.8| 0.0|STATS |                Features Written

2024-01-04 10:57:31|  1.8| 0.0|STATS |=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

2024-01-04 10:57:31|  1.8| 0.0|STATS |Table1                                    1

2024-01-04 10:57:31|  1.8| 0.0|STATS |==============================================================================

2024-01-04 10:57:31|  1.8| 0.0|STATS |Total Features Written                            1

2024-01-04 10:57:31|  1.8| 0.0|STATS |=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

2024-01-04 10:57:31|  1.9| 0.1|INFORM|Translation FAILED with 5 error(s) and 4 warning(s) (100000 feature(s) output)

2024-01-04 10:57:31|  1.9| 0.0|STATS |Stored 1 feature(s) to FME feature store file `F:\\Temp\\FME_Merging_All_Topo_Area\\Merging_All_Topo_Area_log.ffs'

2024-01-04 10:57:31|  2.0| 0.1|INFORM|FME Session Duration: 2.2 seconds. (CPU: 1.1s user, 0.9s system)

2024-01-04 10:57:31|  2.0| 0.0|INFORM|END - ProcessID: 101568, peak process memory usage: 159956 kB, current process memory usage: 135516 kB

2024-01-04 10:57:31|   |   |INFORM|OGCGEOPACKAGE writer: An error has occurred. Check the logfile above for details

2024-01-04 10:57:31|   |   |INFORM|Program Terminating

2024-01-04 10:57:31|   |   |INFORM|Translation FAILED.

 

Hey there, looks like you have two columns with the same name due to case insensitivity (TOID and Toid). This causes FME to abort the writing. Removing either one should solve your issue!


Reply