From the course: Advanced SQL for Application Development
Unlock the full course today
Join today to access over 24,000 courses taught by industry experts.
Range partitioning
From the course: Advanced SQL for Application Development
Range partitioning
- [Instructor] There are a few different kinds of horizontal partitioning or different ways that we can come up with how we decide on how to group rows. The first one we'll look at is called partitioning by range. Now, partitioning by range, as I'd said, is a type of horizontal partitioning, and the basic idea is that we create these partitions using non-overlapping keys. So in this example, I'm showing how we can partition based on month and year. And that's a common thing. Partitioning by date is often used, for example, in data warehousing. Similarly, you can partition based on date in IoT or time series data, although you may actually have even more fine grain partitions if you have a lot of data, say, coming in at the minute or hour level. You can also range partitioning for numeric ranges. So anything that has, say, an integer ID, and has a min and max value. That's often a good candidate for using as a criteria…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
(Locked)
Overview of partitioning7m 10s
-
(Locked)
Range partitioning5m 52s
-
List partitioning3m 7s
-
(Locked)
Hash partitioning4m 27s
-
(Locked)
Querying partitioned tables1m 3s
-
(Locked)
Using read-only replicas1m 41s
-
(Locked)
Challenge: Define a partitioned table37s
-
(Locked)
Solution: Defining a partitioned table54s
-
(Locked)
-
-
-