QueryStash

QueryStash

How can I share my SQL queries?

Blakey

Blakey

How can I share my SQL queries?

Sharing is fundamental to QueryStash, the goal is to create an environment where the community of users can help each other develop and share knowledge.

To facilitate this making sharing queries easier and more appealing definitely warrants a little bit of attention. To start with some initial steps we have made a few updates this week to help fulfil this dream.

First the easy part, we have added a simple share to Twitter button right on the query page. You can find this by clicking on the blue share button within the dropdown menu.

Share Your SQL

However this is not all, now for the exciting part.

Now every time you create or update a new public query, we automatically generate an image. This is specifically designed for sharing content in a more appealing fashion, for example with the use of Twitter cards.

The actual image generated will look something like this.

SQL Query Snippet

So next time you edit or create a new query your image will be ready within a few seconds of pressing the "Save" button. Ready to share to the world.

Need a refresher on creating queries, don't forget to checkout our intro guide

How do we generate these images?

So you might be curious how we can generate beautiful images like this of your SQL code. The answer is Snaippify.io an incredible tool for creating amazing code snippet images to help you create content to share.

Anki & Dominik are building a great product to help people share in a beautiful way and we are privileged to be able to leverage their product to help enhance QueryStash.

snappify.io


Explore some example SQL queries...

QUALIFY by ROW_NUMBER for cleaner queries

Using QUALIFY you can greatly simplify your query when dealing with RANK and ROW_NUMBER, and avoid having multiple sub queries.

QUALIFY by ROW_NUMBER for cleaner queries

Spike Detection for Website Visits

To demonstrate one approach to spike detection, we are exploring website visitor data from the BigQuery Public Google Analytics sample data.

Spike Detection for Website Visits

Merge Statements BigQuery

The combination of insert and update in a merge statement simplifies data processing where we don't know if a record already exists.

Merge Statements BigQuery

Create a Persistent Function on BigQuery

Persistent user-defined functions allow users to create custom functions that can be used across multiple queries and shared amongst users.

Create a Persistent Function on BigQuery

BigQuery Create ML Regression Model

Creating ML models has become even easier with BigQuery ML, create a new model in a few lines of SQL.

BigQuery Create ML Regression Model

BigQuery Create Array of Structs

Working with flattened data might not always be the optimal way to work with data in BigQuery, use arrays to group data together into a single field.

BigQuery Create Array of Structs
QueryStash

QueryStash

Made with ❤️ by @Yekalb

© 2023 Query Stash. All rights reserved

TwitterFacebookEmail

Resources

BlogPricingYour First QuerySearch Your Stash

Stay up to date

Terms of ServicePrivacy Policy