Working with semi-structured data in Snowflake provides great advantages, specially around the continuous ingestion approach. Let's take a look at a simple way of having a single ingestion endpoint and splitting this data into multiple tables with one single insert while having the data at the ingestion level in a VARIANT data type. This approach … Continue reading Multi-Table inserts with Semi-Structured Inputs in Snowflake
A quick Date Dimension with Snowflake
In most data warehouse implementations, a date dimension is created to standardize dates and make time bucketing easier. In this quick example I will discuss how to create a simple query that can generate a table for a Date Dimension. Creating the Ranges & Session Variables ALTER SESSION SET WEEK_START = 0; SET (START_DATE,END_DATE) = … Continue reading A quick Date Dimension with Snowflake
A look into your SQL Server Agent Schedules
Here is a very simple script to see all your SQL Agent Jobs and their corresponding schedules, Enjoy! USE msdb; GO SELECT DISTINCT J.job_id , J.name AS JobName , COUNT(st.step_id) OVER (PARTITION BY st.job_id) AS StepCount , J.enabled , ISNULL(C.name, '--') AS ScheduleName , CAST(CASE C.freq_type WHEN 1 THEN 'Once' WHEN 4 THEN 'Daily' WHEN … Continue reading A look into your SQL Server Agent Schedules
Azure Data Studio for Mac + Windows Auth
I use a MacBook Pro for my day to day and personal work and use Azure Data Studio as my SQL Server development and scripting tool. Working across multiple domains can be a challenge while working on a Mac and here are some simple steps I use often. Azure Data Studio Windows authentication requires a … Continue reading Azure Data Studio for Mac + Windows Auth
Ingest, Query and Share Semi-Structured Data with an Azure Stack.
With data growing per second, many companies face the need of consolidating semi structured data for analysis, data marts or simply to be served to other implementations. Working with semi-structured data can result simple to produce and sometimes hard to ingest. Azure Data Explorer is a great solution to query data hosted in several areas … Continue reading Ingest, Query and Share Semi-Structured Data with an Azure Stack.
Database Deployments using Azure DevOps
Azure DevOps (Formerly Visual Studio Team Services) is a great tool that provides a 1 stop shop for feature management, code repositories and build & release pipelines among others. This article will cover how to create Build and Release pipelines. Requirements To follow this article you will need the following tools: Azure account1 SQL Server … Continue reading Database Deployments using Azure DevOps
So I started speaking…
Last February 25 I gave my first technical webinar about technology. I’ve spoken in the past in lunch and learn events at work but never thought about speaking to a bigger audience of people I don’t know. One of the greatest things about the SQL community is that you get to meet awesome people like … Continue reading So I started speaking…
Character Delimited Lists without using XML Path
Usually when a delimited lists is need in T-SQL, XML Path has been the solution for generating a this delimited list in a single column. With the generation of XML, comes the concatenation needed to add the delimiter and the trimming function to remove the leading or trailing delimiter. Using AdventureWorks2017 database, the following snippet … Continue reading Character Delimited Lists without using XML Path
Dynamic SQL, now what?
Many times as DBA or Developers inherit a database that is using a lot of Dynamic SQL, that nifty tool that developers love and most DBA hate. Dynamic SQL scripts are a way of composing a query by concatenating values and logic into a dynamically generated query. During my career every time I have found … Continue reading Dynamic SQL, now what?
Generate Backup/Restore to URL Azure Data Studio Notebook using PowerShell
In the last few weeks I've found myself using Azure Data Studio more, specially the notebooks to organize my scripts in a more explanatory and aesthetically way. About a year ago I wrote a SQL script that I use to backup and restore databases from IaaS to PaaS (Azure VM to Azure Managed Instance) using … Continue reading Generate Backup/Restore to URL Azure Data Studio Notebook using PowerShell