Skip to content

Instantly share code, notes, and snippets.

-- Note: All variables that look like <VARIABLE_NAME> need to be changed to user's preferences
-- Pipelines to migrate from non-partitioned to daily partitioned tables
-- This example illustrates partitioning only the past three days; try to modify it to partition dates between any date range!
DEFINE ({
"connection": "<YOUR_CONNECTION>",
"mode": "bigquery-v2",
"pipelineRenderer": "MUSTACHE",
"bigquery-v2": {
-- Note: All variables that look like <VARIABLE_NAME> need to be changed to user's preferences
-- Pipelines to migrate from non-partitioned to daily partitioned tables
-- This example illustrates partitioning only the past three days
-- Modify the invocation queries to partition dates between any date range
DEFINE ({
"connection": "<YOUR_CONNECTION>",
"mode": "bigquery-v2",
"pipelineRenderer": "MUSTACHE",
@ras44
ras44 / keyring_create.R
Created March 8, 2019 23:00
Securing Credentials using Keyrings in R
library(keyring)
# Set variables to be used in keyring.
kr_name <- "my_keyring"
kr_service <- "my_database"
kr_username <- "my_username"
# Create a keyring and add an entry using the variables above
kb <- keyring::backend_file$new()
# Prompt for the keyring password, used to unlock keyring