
Security News
Vite+ Joins the Push to Consolidate JavaScript Tooling
Evan You announces Vite+, a commercial, Rust-powered toolchain built on the Vite ecosystem to unify JavaScript development and fund open source.
@emartech/google-big-query
Advanced tools
Helper library to easily use Google BigQuery in NodeJS
@emartech/google-big-query
uses the config
package for configuration. You should make the following settings available under `"GoogleCloud" namespace:
{
"projectId": "",
"bucket": "",
"dataset": "",
"credentials": {},
"maximumBillingTier": 10
}
The project you'll use for billing.
The default dataset to connect to if it was not specified.
The credentials the connection will use.
Example:
{
"private_key": "-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----\n",
"client_email": "example@my-service.iam.gserviceaccount.com"
}
More info about pricing: https://cloud.google.com/bigquery/pricing
const BigQuery = require('@emartech/google-big-query');
static
Creates a BigQuery instance.
Name | Type | Description |
---|---|---|
datasetName | string | The name of the default dataset. Default: config.GoogleCloud.dataset optional |
Type | Description |
---|---|
BigQuery | Instance of the BigQuery wrapper class. |
Constructor of BigQuery wrapper.
Name | Type | Description |
---|---|---|
datasetName | string | The name of the default dataset. |
client | @google-cloud/bigquery | The BigQuery client. |
Returns a Table instance for the given table name.
Name | Type | Description |
---|---|---|
tableName | string | The name of the table in the dataset |
Type | Description |
---|---|
Table | Google Cloud BigQuery Table class instance. |
This is a wrapper of the original createQueryStream() method.
Name | Type | Description |
---|---|---|
query | string or object | The query to run. More info about the parameter. |
Type | Description |
---|---|
ReadableStream |
This is a wrapper of the original query() method.
Name | Type | Description |
---|---|---|
query | string or object | The query to run. More info about the parameter. |
Type | Description |
---|---|
Promise |
generator
This is a wrapper of the original createQueryJob() method.
Name | Type | Description |
---|---|---|
options | object or string |
Type | Description |
---|---|
Promise |
let [job] = yield BigQuery.create().createQueryJob(query);
job.getQueryResultsStream({ maxResults: 100000, startIndex: 0 }).pipe(processRow);
generator
Creates the table with the specified schema.
Name | Type | Description |
---|---|---|
table | Table | The table instance |
schema | object | Schema definition of the table |
Type | Description |
---|---|
Table | The new Table. |
generator
Drops the given table if exists.
Name | Type | Description |
---|---|---|
table | Table | The table instance that should be dropped. |
generator
This is a wrapper of the original createTable() method.
Name | Type | Description |
---|---|---|
tableName | string | The name of the table. |
options | object | More info in the original documentation. optional |
Type | Description |
---|---|
Table | The new Table. |
static
static
static
generator
static
generator
static
static
generator
static
generator
static
static
generator
FAQs
Helper library to easily use Google BigQuery in NodeJS
The npm package @emartech/google-big-query receives a total of 2 weekly downloads. As such, @emartech/google-big-query popularity was classified as not popular.
We found that @emartech/google-big-query demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 125 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Evan You announces Vite+, a commercial, Rust-powered toolchain built on the Vite ecosystem to unify JavaScript development and fund open source.
Security News
Ruby Central’s incident report on the RubyGems.org access dispute sparks backlash from former maintainers and renewed debate over project governance.
Research
/Security News
Socket researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.