Skip to main content

High-Level Database Client for OpenGov Permitting & Licensing

Project description

ogplc

High-Level Database Client for OpenGov Permitting & Licensing

install

pip install ogplc

cli usage

# dump to a datasets folder
ogplc dump --username="myusername" --password="mypassword" --server="myserver" --database="mydatabase" --output="$PWD/datasets"

python usage

import ogplc

ogplc.dump(
    server = "server_host",
    database = "database_name",
    username = "username",
    password = "password",

    # folder where to save output files
    output = "/home/users/documents/datasets",

    # optional parameters below
    driver = "SQL Server",

    # only include these record types in results
    record_types = ["Skyscraper Permit"],

    # exclude these record types from results
    skip_record_types = ["Orchard Permit"],

    # maximum number of rows in output dataset for each record type
    max_rows = 1000,

    # number of seconds to wait between database queries
    wait = 0,

    # remove new line from databse results
    # this can help improve readibility
    remove_new_lines = True,

    # delimiter to pass to csv writer
    delimiter = ",",

    # logging level
    debug_level = 1
)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ogplc-0.0.0.tar.gz (8.9 kB view details)

Uploaded Source

File details

Details for the file ogplc-0.0.0.tar.gz.

File metadata

  • Download URL: ogplc-0.0.0.tar.gz
  • Upload date:
  • Size: 8.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.0

File hashes

Hashes for ogplc-0.0.0.tar.gz
Algorithm Hash digest
SHA256 0ef336bbc912ff7e82c738b92c8fe8622b9e317d89fbc8c8bc19ca3cea71b3fc
MD5 8446724ccb6bb84bf8a0e1421f0d93d1
BLAKE2b-256 00fb79b9b64dffa7aeb07c0e84b4a7e4d357bad7695a72f18fb950dd12f899fc

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page