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

remove pgdata dependency #73

Open
smnorris opened this issue Mar 28, 2021 · 1 comment
Open

remove pgdata dependency #73

smnorris opened this issue Mar 28, 2021 · 1 comment

Comments

@smnorris
Copy link
Collaborator

I would like to retire this package. Much of the db interaction can now be done with psycopy2 built in methods.
Not a priority at the moment though.

@smnorris
Copy link
Collaborator Author

Note that loading complex data can bail due to smnorris/pgdata#21.
Easy fix but I'd prefer to retire the package.
If data load fails due to presence of multisurface records, manually run the ogr2ogr command, something like this:

    ogr2ogr \
        -f PostgreSQL \
        PG:"host=localhost port=5433 user=postgres dbname=designatedlands password=postgres" \
        -lco OVERWRITE=YES \
        -overwrite \
        -lco SCHEMA=public \
        -nlt PROMOTE_TO_MULTI \
        -nlt CONVERT_TO_LINEAR \
        -nln cef_human_disturbance \
        -sql "SELECT * FROM BC_CEF_Human_Disturb_BTM_2021_merge WHERE CEF_DISTURB_GROUP_RANK IN (1,2,3,4,5,6,7,8,9,10)" \
        source_data/BC_CEF_Human_Disturbance_2021.gdb

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

1 participant