cockroachdb / cockroachdb/cockroach
Range type support with CDC trigger
- Dominant language
- Go
- Stars
- 32.5k
- Forks
- 4.1k
- PR merge metrics
- PR metrics pending
Description
**Is your feature request related to a problem? Please describe.**
I'm working with event objects that have an start and end date time. Support for the range type as seen in postgresql would be very useful.
**Describe the solution you'd like**
I would like to see the range type implemented as in postgresql. For an example see the following video:
https://www.youtube.com/watch?v=eG_9lZrrbEY
I'd also like to see this connected to CDC where we would have an `inrange` event and a `outrange` event for when the range is "in range" and "out of range" respectively. This would allow for applications that have time sensitive data.
**Describe alternatives you've considered**
Right now the only way to deal with this issue is to use an external process that polls the start and stop values:
``` sql
SELECT * FROM MyTable
WHERE current_timestamp >= start AND current_timestamp <= stop;
```
Jira issue: CRDB-41117
Contributor guide
Research direction
No source file, test, or entry point is named. Start by reviewing CRDB-41117 and the PostgreSQL range example, then use the provided polling query to define the expected in-range and out-of-range behavior; done means range support is connected to CDC with both requested events.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, postgresql, sql
- Domain
- databases
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100