Skip to content

Commit

Permalink
Merge pull request #10 from PDOK/add-externalfid-index
Browse files Browse the repository at this point in the history
Create index on external_fid if it is created
  • Loading branch information
kad-korpem authored Oct 21, 2024
2 parents db94043 + 071a348 commit 9003763
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions optimizer.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ func optimizeOAFGeopackage(sourceGeopackage string, config string) {
if layerCfg.ExternalFidColumns != nil {
addColumn(tableName, "external_fid", "TEXT", db)
setColumnValue(tableName, "external_fid", fmt.Sprintf("uuid5('%s', '%s'||%s)", pdokNamespace, tableName, strings.Join(layerCfg.ExternalFidColumns, "||")), db)
createIndex(tableName, []string{"external_fid"}, fmt.Sprintf("%s_external_fid_idx", tableName), false, db)
}

if layerCfg.TemporalColumns != nil {
Expand Down

0 comments on commit 9003763

Please sign in to comment.