Skip to main content

Pyplatform-datawarehouse package provides functions for querying, writing and managing data in Google BiqQuery.

Reason this release was yanked:

incompetible with bigquery client 1.27.2

Project description

Pyplatform-datawarehouse package provides functions for querying, writing and managing data in Google BiqQuery.

Installation

pip install pyplatform-datawarehouse

Authentication and environment variables

Refer to main page for documentation on authentication

Exploring the modules

from pyplatform.datawarehouse import *
show_me()

Usage

querying BigQuery table

import pyplatform.datawarehouse as dw
sql = """SELECT Order_ID, Order_Date, Ship_Date, Ship_Mode, Customer_ID, Customer_Name, Segment 
FROM `project_id.dataset.sample_superstore` """
df = dw.bq_to_df(sql)
df.head()

# select statemet is enclosed in the stored procedure
sql = """CALL `project_id.dataset.spoc_sample_superstore`();"""
df = dw.bq_to_df(sql)
df.head()

writing dataframe BigQuery table

import pyplatform.datawarehouse as dw
# df #TODO create dataframe as source
table_id = 'project_id.dataset.sample_superstore'
job = dw.df_to_bq(df,table_id)

print(dw.bq_get_job_info(job))

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

pyplatform-datawarehouse-2020.8.1.tar.gz (14.6 kB view details)

Uploaded Source

Built Distribution

File details

Details for the file pyplatform-datawarehouse-2020.8.1.tar.gz.

File metadata

  • Download URL: pyplatform-datawarehouse-2020.8.1.tar.gz
  • Upload date:
  • Size: 14.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.7.7

File hashes

Hashes for pyplatform-datawarehouse-2020.8.1.tar.gz
Algorithm Hash digest
SHA256 b36e4429eefa4758aae653f1dedee8ca3f8ff26fb52da8dd324b3212184215d6
MD5 95b6a6b9ee82c93ec10cdc12cfda7afa
BLAKE2b-256 16e2c0e16ad0bbae8525aeec8e624ebc4c9cfcde9c8160efc20fdaf0152a6e06

See more details on using hashes here.

File details

Details for the file pyplatform_datawarehouse-2020.8.1-py3-none-any.whl.

File metadata

  • Download URL: pyplatform_datawarehouse-2020.8.1-py3-none-any.whl
  • Upload date:
  • Size: 14.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.7.7

File hashes

Hashes for pyplatform_datawarehouse-2020.8.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e3e727110f7371653aef3451d8209b79f6e370d2bd32b5a8d3862a07b53a5a46
MD5 ef9ea1b13632b59506bef08142cc0396
BLAKE2b-256 41635f095dbfa9134ce63774e8134e817e6bcacf67eee7c0a2b052f5a9234602

See more details on using hashes here.

Supported by

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