#74 Golang - PostgreSQL with PGX in Go: Step-by-Step Tutorial
Buy my book 'Functional Programming with Go' here: https://bit.ly/fp-with-go In this episode, we dive deep into the pgx package, one of the most powerful PostgreSQL drivers and toolkits for Go developers. Whether you're just starting with PostgreSQL in Go or looking to level up your database skills, this episode has got you covered. Here's what you'll learn: ✅ How to set up and connect to a PostgreSQL database using pgx ✅ The difference between single connections and connection pooling ✅ How to perform INSERT, SELECT, UPDATE, and DELETE operations ✅ Managing transactions effectively to ensure data integrity ✅ Querying multiple rows and mapping them to Go structs ✅ Handling advanced features like parameterized queries and error handling By the end of this video, you’ll have a solid understanding of the pgx package and be ready to use it in your own Golang projects! 💡 Don’t forget to like, comment, and subscribe for more Golang tutorials, and hit the 🔔 to stay updated on new videos. Timestamps: 00:00 Introduction 00:41 Installing and Setting Up pgx 00:51 Creating Tables 01:24 Connection Pooling with pgx 03:17 Insert Data into PostgreSQL 04:07 Using Transactions with pgx 05:51 Querying Multiple Rows 08:03 Querying a Single Row 08:55 Updating Records 09:48 Deleting Records 10:32 Wrap-Up 📚 Resources: 📹 Original video: https://www.codeheim.io/courses/Episo... 📝 Source code: https://github.com/code-heim/go_74_pgx PGX Documentation: https://github.com/jackc/pgx Thanks for watching, and see you in the next episode! 🚀

#75 Golang - Master WebSockets in Go: Build an Echo Server & Client with Coder WebSocket

Go Structured Logging with the slog Package (Golang)

SQLC in Go - Auto-Generating Database Code in Golang

SQLc is the perfect tool for those who don't like ORMs

#71 Golang - Master SQLX: Simplify Database Operations

Go Kafka: How To Manually Commit Offsets The Right Way. Database Idempotency.

Graceful Shutdown in Go: Key Patterns you need to know!

PGX Top to Bottom

Creating custom struct tags in Golang is awesome!

This is the BEST Golang Context Package Tutorial

99% of Developers Don't Get PostgreSQL

Billionaire's WARNING: I'm SELLING. The Crash Is Already Here!

This Is The BEST Way To Structure Your GO Projects

Go - SQL Databases in Golang with the database/sql package

Turing Award Winner: Disagreeing with Google, Postgres, Future Problems | Mike Stonebraker

PostgreSQL Crash Course - Beginner Tutorial

The standard library now has all you need for advanced routing in Go.

I replaced my entire stack with Postgres...

Golang + HTMX - Creating a Go webserver / HTMX Integration / Template Fragments

