From the course: SQL for Testers

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Validate data integrity

Validate data integrity - SQL Tutorial

From the course: SQL for Testers

Start my 1-month free trial

Validate data integrity

- [Instructor] We've seen how you can use SQL to validate that certain workflows are correct but now let's dive a little deeper into validating data integrity in different tables. So in order to do this, sometimes it's helpful to see data across multiple tables at the same time. For example, in the text application that we were looking at, we know that if we add an item to our cart, that data should be added to the cart table but we should also see a change in the stock column on the products table. So we know that we can query that data as individual queries but it would be nice to do it all together in one query. The command that lets us do this in SQL is called JOIN. There's a couple of types of joins and joining can feel like a pretty complicated concept in SQL but we'll proceed with starting with the most common type of join, the INNER JOIN and then we'll take a look at that in practice. So don't worry if you…

Contents