Skip to content

Instantly share code, notes, and snippets.

//=============================================================================
// Set context
//=============================================================================
USE ROLE <YOUR_ROLE>;
USE WAREHOUSE <YOUR_WAREHOUSE>;
USE DATABASE <YOUR_DATABASE>;
CREATE SCHEMA NETFLIX_STREAMS_AND_TASKS;
//=============================================================================
@randypitcherii
randypitcherii / 2020-06-21 -- Structure.rest Snowflake Setup.sql
Created June 21, 2020 18:05
Snowflake SQL for creating an isolated Structure.rest environment
//=============================================================================
// create top level objects
//=============================================================================
USE ROLE SYSADMIN;
// Database
CREATE DATABASE STRUCTURE_WORKSPACE;
// Warehouse
CREATE WAREHOUSE STRUCTURE_WORKSPACE_WH
@randypitcherii
randypitcherii / hashmap_zero_to_snowflake.sql
Last active November 16, 2022 11:31
SQL commands for Hashmap's slightly-modified Zero to Snowflake demonstrations. Find the original, official SQL from Snowflake at https://bit.ly/2JJZl3J
// This SQL file is for the Hands On Lab Guide for the 30-day free Snowflake trial account
// The numbers below correspond to the sections of the Lab Guide in which SQL is to be run in a Snowflake worksheet
// Modules 1 and 2 of the Lab Guide have no SQL to be run
// See the lab guide here - https://s3.amazonaws.com/snowflake-workshop-lab/InpersonZTS_LabGuide.pdf
//=====================================
// MODULE 1
// Steps to Prepare Your Lab Environment
@randypitcherii
randypitcherii / ShareableSnowflakeMonitoring.twbx
Last active April 29, 2019 19:08
Tableau workbook for snowflake cost monitoring
@randypitcherii
randypitcherii / snowflakeStitchBlog.sql
Last active March 26, 2019 21:44
Full guided SQL for the Talend Stitch + Snowflake blog post
// ===========================================================================
// Welcome!
//
// Log in to your Snowflake instance, create a new worksheet, then
// copy and paste the contents of this file into your worksheet.
//
// Make sure you're using the ACCOUNTADMIN role before we get started
// (see the context in the upper right corner of your worksheet)
//
// Next, head over to the Partner Connect page (link in the top right of the snowflake toolbar).
@randypitcherii
randypitcherii / snowflakeDataForBreakfastWorkshop.sql
Last active May 30, 2022 06:27
This SQL file contains the SQL necessary for the March 2019 Hashmap+Snowflake Data for Breakfast workshop demonstrations.
// ===========================================================================
// Welcome!
//
// Log in to your Snowflake instance, create a new worksheet, then
// copy and paste the contents of this file into your worksheet.
// ===========================================================================
// ===========================================================================
@randypitcherii
randypitcherii / hashmap-codeDevFlow.md
Last active November 9, 2018 23:00
Introduction to the Hashmap software development flow and a simple PM-level glossary of terms

Hashmap Software Development Flow

This document explains the general workflow used at Hashmap for software projects on github.

Please feel free to reach out if you'd like me to change any of this.

Github Terms

First, let's discuss some git / github terms that are often confusing.

  • git -> a version control software. This software is what allows developers on different machines to collaborate on the same code base in a really efficient way.
  • github -> github is a website that hosts git repositories. It has a ton of social / communication / PM features that make it a nice way to collaborate on software projects.
@randypitcherii
randypitcherii / .bash_profile
Last active April 29, 2019 15:50
Dot files on mac
# Shorten Bash Prompt
PS1='$ '
# Env Vars
export JAVA_HOME=$(/usr/libexec/java_home)
export GREP_OPTIONS="--color=auto"
# Init jenv
if which jenv > /dev/null; then eval "$(jenv init -)"; fi
@randypitcherii
randypitcherii / javascript.json
Created October 16, 2018 20:09
VS Code javascript snippet for bootstrapping a new react component
{
"New Component": {
"prefix": "newComponent",
"body": [
"import React, { Component } from 'react';",
"",
"import { withStyles } from '@material-ui/core/styles';",
"",
"const styles = {",
"\t//customStyle: {",
@randypitcherii
randypitcherii / aws_s3_rates.md
Last active August 20, 2018 18:10
Table of s3 rates for blog post embedding.
Storage Tier Storage Cost (monthly per Gigabyte) Read Cost (per 1K requests + per Gigabyte read) Write Cost (per 1K requests)
S3 Standard $0.023 $0.0004 + $0.0007 $0.005
S3 IA $0.0125 $0.001 + $0.01 $0.01
S3 IA One Zone $0.01 $0.001 + $0.01 $0.01
Glacier Standard $0.004 $0.05 + $0.01 $0.05