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

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…

Contents