From the course: ChatGPT and SQL

Unlock this course with a free trial

Join today to access over 25,000 courses taught by industry experts.

Explain a SQL query

Explain a SQL query

- [Instructor] Hi, everyone. In this video we're going to talk through how you can use ChatGPT or Google Bard or any other chat-based AI tool to explain a SQL query that you're working with if you don't know exactly what's going on. Like anytime we're using these tools, I'm going to prompt the AI tool with a little context. So, I'm going to ask it to act as a senior analyst who's an expert in SQL and tell it that it will be helping me, a junior analyst on the team, understand SQL queries that we'll use together on the job. And so then I'm going to ask it, can you please explain the following query to me? And I always like to put a delimiter in here. It can sometimes help the AI understand that something else is going on. So you can do that in a number of ways. That's something that I found to be pretty effective. So here's the query that we want help with. It's not too complicated. Let's start running that and I'll walk you through this. So basically, we are pulling data from the…

Contents