Skip to content

[docs] add section for currently unsupported sql operations#5861

Merged
anandbraman merged 3 commits intomainfrom
anandraman/fde-29-document-current-limitations-of-feldera-sql-functions
Mar 19, 2026
Merged

[docs] add section for currently unsupported sql operations#5861
anandbraman merged 3 commits intomainfrom
anandraman/fde-29-document-current-limitations-of-feldera-sql-functions

Conversation

@anandbraman
Copy link
Contributor

Describe Manual Test Plan

Checklist

  • Unit tests added/updated
  • Integration tests added/updated
  • Documentation updated
  • Changelog updated

Breaking Changes?

Mark if you think the answer is yes for any of these components:

Describe Incompatible Changes

@anandbraman anandbraman requested a review from mihaibudiu March 18, 2026 21:58

General-purpose `RANK`, `DENSE_RANK`, and `ROW_NUMBER` outside of TopK
detection are not yet implemented.
See [#3934](https://github.com/feldera/feldera/issues/3934).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, we can support only 1 topK pattern per OVER query.


### `FIRST_VALUE` and `LAST_VALUE` limited to unbounded range

`FIRST_VALUE()` and `LAST_VALUE()` are only supported for windows with
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

An unbounded range is really UNBOUNDED PRECEDING and UNBOUNDED FOLLOWING.
I think we support that too, and up to CURRENT ROW.
But not other things.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would you recommend I change the word choice? I thought unbounded range could mean that unbounded in one direction or both.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

UNBOUNDED usually means in both directions

supported.
See [#457](https://github.com/feldera/feldera/issues/457).

## Correlated subqueries
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, window boundaries must be constant expressions.
There are expressions like RANGE INTERVAL 1 MONTH PRECEDING which look like constants, but they are not really, because the length of a month is not a constant.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that SQL also allows expressions for window boundaries, which don't. We can only handle constant expressions. It is covered by what you way - the example with 1 MONTH looks like a constant expression, but in fact is not.


## Map functions

Several `MAP` functions are not yet implemented:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some of these are really Spark specific. They should be in a Spark-specific documents. MAP itself is a non-standard SQL feature.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I could put these under a spark heading, but I don't think we should move it for now. It's easier to manage one page and send users to a single place for "limitations", especially as we update our sql functionality often.


## Timezone support

`DATE`, `TIME`, and `TIMESTAMP` types have no time zone. There is no
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DATE does not have TIMEZONE ever, not even in standard SQL.
timezones are related to times, they do not apply to dates.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good point, silly error

every step, which can produce large deltas and degrade performance
significantly.

See the [datetime documentation](datetime.md#now) for more details.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PIVOT is only supported with a fixed set of columns (we don't support dynamic pivot).
We don't have UNPIVOT yet.


### `NTILE` is not supported

The `NTILE()` window function is not yet implemented.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, nth_value

every step, which can produce large deltas and degrade performance
significantly.

See the [datetime documentation](datetime.md#now) for more details.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No support for INTERSECT ALL and EXCEPT ALL.

every step, which can produce large deltas and degrade performance
significantly.

See the [datetime documentation](datetime.md#now) for more details.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no support for the MULTISET data type

every step, which can produce large deltas and degrade performance
significantly.

See the [datetime documentation](datetime.md#now) for more details.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sometimes the query decorrelator cannot decorrelate some complex nested subqueries; we cannot execute such queries at all.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm going to leave this out for now, unless we have an example of query that we can't decorrelate

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are several issues with the word "decorrelate".
I think you should mention it, even without examples.
Unlike other databases, we cannot run a query which we cannot decorrelate.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added a note

Copy link
Collaborator

@mythical-fred mythical-fred left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mihai's inline comments identify several factual inaccuracies that need to be incorporated before this merges. Please address all of them.

@anandbraman anandbraman requested a review from mihaibudiu March 19, 2026 17:34
Copy link
Collaborator

@mythical-fred mythical-fred left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Addressed. All of Mihai's factual corrections are in — TopK one-per-OVER, constant window bounds, PIVOT/UNPIVOT, INTERSECT ALL/EXCEPT ALL, MULTISET, NTH_VALUE, the DATE timezone error, and the decorrelation note. LGTM.

@anandbraman anandbraman added this pull request to the merge queue Mar 19, 2026
Merged via the queue into main with commit db79141 Mar 19, 2026
1 check passed
@anandbraman anandbraman deleted the anandraman/fde-29-document-current-limitations-of-feldera-sql-functions branch March 19, 2026 20:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants