Skip to content
sqlkitty

sqlkitty

sql for everyone

Menu
  • Home
  • About
  • Auditing
  • Code
  • Presentations
  • Publications
  • Contact

Category: postgresql

Using Cron in Postgres Flex

  • Posted onApril 24, 2025June 16, 2025
  • azure

pg_cron is a simple cron-based job scheduler for PostgreSQL that runs inside the database as an extension. It allows you to schedule PostgreSQL commands directly from your database, similar to using cron jobs at the operating system level. pg_cron on PG Flex is pretty easy…

Continue Reading

Using SQLFluff

  • Posted onMarch 18, 2025March 18, 2025
  • azure

I thought I didn’t care about linting, and lately, I haven’t written a lot of SQL, but for the SQL I do write, I have SQLFluff to help me format it. A friend of mine is big into SQLFluff and finally talked me into installing…

Continue Reading

Save Azure PostgreSQL Backup to Storage

  • Posted onMarch 14, 2025
  • azure

This may or may not be helpful in the long term, but since I’m doing it to be super cautious, I figured I would blog about it. We migrated to Flex last week, and to be abundantly cautious, we’re putting the last single server backup…

Continue Reading

Migrating from Azure PG Single Server to Flex with Azure VM and pg_dump/restore

  • Posted onFebruary 9, 2025February 9, 2025
  • azure

This is more complicated than using the Azure Migration method, but because it’s maxed out on resources for the last week in the east regions (and possibly central), and who knows when they will fix it, I had to resort to other methods. I’m getting…

Continue Reading

Drop roles in Postgres

  • Posted onJanuary 27, 2025March 5, 2025
  • postgresql

Let me start by saying that there are some issues with these scripts. They aren’t deal breakers, but I will loop back after my migrations to fix them—hopefully. You can’t just exec DROP ROLE your_role_name; if it’s granted perms or other roles are granted to…

Continue Reading

Checking table size in Postgres

  • Posted onJanuary 23, 2025February 9, 2025
  • postgresql

It’s easy to do with this query. That’s all I have to say on this topic for now.

Continue Reading

How I Migrated to Azure PostgreSQL Flex from Single Server

  • Posted onJanuary 7, 2025February 9, 2025
  • azure

I did a couple of posts previously on dumping/restoring Azure PostgreSQL databases and also using the Azure migration tool. I had to ultimately do a combo of those because of the limitations of the Azure migration tool. Getting your roles in place The Azure migration…

Continue Reading

How to find free space in Azure PostgreSQL

  • Posted onNovember 21, 2024December 2, 2024
  • azure

I wanted to figure out how big (or approximately how big) my dump file would be. In QA, I have (relatively) large dbs (compared to prod). Enter the pgstattuple extension to help me determine how much free space is in my tables. Step 1: Installing…

Continue Reading

Migrate to Azure PostgreSQL Flexible Server

  • Posted onOctober 17, 2024December 20, 2024
  • azure

Warning: It appears the migration doesn’t apply perms in the database related to global roles as part of the Azure migration. https://learn.microsoft.com/en-us/azure/postgresql/migrate/migration-service/concepts-user-roles-migration-service. I will be using pg_dumpall for scripting out the perms. You can refer to my last post under dumping from command line for…

Continue Reading

Dumping and Restoring Azure PostgreSQL Databases

  • Posted onSeptember 25, 2024December 2, 2024
  • azure

I wanted to test a migration of Azure PostgreSQL from simple to flexible. I wanted a simple db to restore onto my single server. I may not have needed to do this, but I was then curious how one would go about dumping and restoring…

Continue Reading

Posts pagination

Page 1 Page 2 Next Page

Newletter Signup

Loading

Recent posts

  • Terraform Commands
  • Capturing errors and auditing in Azure SQL DB
  • T-SQL Tuesday #186 Invitation – Managing Agent Jobs
  • Query multiple Azure SQL Databases
  • Azure Vulnerability Assessments

Categories

  • audit (3)
  • azure (47)
  • containerization (14)
  • datawarehousing (4)
  • dba (54)
  • editorial (8)
  • excel and others (3)
  • IT Certifications (1)
    • network+ (1)
  • linux (2)
  • network administration (15)
  • newjob (7)
  • other (8)
  • performance (1)
  • postgresql (16)
  • powershell (1)
  • security (3)
  • sql server (23)
  • sql server administration (124)
    • jobs (4)
  • sql sever syntax (78)
  • terraform (6)
  • tsql2sday (2)
  • web dev (6)
  • zen (2)

Archives

  • August 2025 (1)
  • July 2025 (1)
  • June 2025 (1)
  • May 2025 (2)
  • April 2025 (2)
  • March 2025 (3)
  • February 2025 (3)
  • January 2025 (4)
  • November 2024 (3)
  • October 2024 (1)
  • September 2024 (2)
  • August 2024 (1)
  • July 2024 (5)
  • June 2024 (4)
  • May 2024 (4)
  • April 2024 (3)
  • March 2024 (2)
  • February 2024 (1)
  • January 2024 (5)
  • December 2023 (2)
  • November 2023 (5)
  • October 2023 (1)
  • September 2023 (1)
  • August 2023 (2)
  • July 2023 (2)
  • June 2023 (3)
  • May 2023 (4)
  • April 2023 (3)
  • March 2023 (5)
  • January 2023 (1)
  • October 2022 (2)
  • April 2022 (1)
  • December 2021 (1)
  • May 2021 (1)
  • April 2021 (2)
  • February 2021 (7)
  • January 2021 (4)
  • December 2020 (2)
  • November 2020 (1)
  • January 2020 (2)
  • December 2019 (3)
  • August 2019 (2)
  • February 2019 (1)
  • June 2018 (1)
  • January 2018 (1)
  • September 2017 (1)
  • May 2016 (4)
  • January 2016 (2)
  • December 2015 (2)
  • August 2015 (2)
  • July 2015 (4)
  • June 2015 (3)
  • May 2015 (9)
  • April 2015 (4)
  • November 2014 (7)
  • October 2014 (19)
  • September 2014 (3)
  • July 2014 (2)
  • July 2013 (1)
  • December 2012 (1)
  • October 2012 (1)
  • December 2011 (6)
  • October 2011 (6)
  • September 2011 (5)
  • July 2011 (1)
  • June 2011 (1)
  • May 2011 (2)
  • April 2011 (1)
  • February 2011 (15)
  • January 2011 (19)
  • December 2010 (14)
  • November 2010 (16)
  • October 2010 (3)

RSS SQL Kitty RSS

  • Terraform Commands
  • Capturing errors and auditing in Azure SQL DB
  • T-SQL Tuesday #186 Invitation – Managing Agent Jobs
  • Query multiple Azure SQL Databases
  • Azure Vulnerability Assessments
© Copyright 2026 – sqlkitty
Chip Life Theme by TutorialChip ⋅ Powered by WordPress