Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separating indexes and DB schemas into different SQLs #6

Closed
stirringhalo opened this issue Sep 28, 2016 · 2 comments
Closed

Separating indexes and DB schemas into different SQLs #6

stirringhalo opened this issue Sep 28, 2016 · 2 comments

Comments

@stirringhalo
Copy link

stirringhalo commented Sep 28, 2016

I'm doing large fills (currently 250k buildings) of 3DCityDB from wavefront OBJ files in a custom reader into Postgres. As part of this, I drop all indexes ahead of time (except for the primary key ones).

It'd be great to have the CREATE_DB.sh script separate db and index building into different scripts so it would be easy to rebuild them on demand.

@clausnagel
Copy link
Member

We use pgModeler as main tool for designing the 3DCityDB schema under PostgreSQL and for automatically exporting it to an SQL script file. We wanted to minimize any pre or post processing outside pgModeler as much as possible. That's why there is no separate CREATE_INDEX.sql script at the moment.

For batch imports, we have good experience with just dropping the main spatial indexes. The function citydb_pkg.drop_spatial_indexes() is useful here. When using the importer/exporter tool, dropping normal indexes may even slow down the import as they are needed for resolving CityGML XLinks (e.g. when importing appearance information).

@stirringhalo
Copy link
Author

Makes sense about the sluggishness with appearances. I'll just do the index dropping + re-add manually.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants