[jOOQ/jOOQ#14481] Add parser support for bitemporal table queries with system_time and business_time

This commit is contained in:
Lukas Eder 2023-02-15 14:04:23 +01:00
parent 0590c6b3ea
commit 7fef0457f4

View File

@ -7157,15 +7157,13 @@ final class DefaultParseContext extends AbstractScope implements ParseContext {
}
else if (!ignoreProEdition()
&& peekKeyword("FOR")
&& !peekKeyword("FOR JSON")
&& !peekKeyword("FOR KEY SHARE")
&& !peekKeyword("FOR NO KEY UPDATE")
&& !peekKeyword("FOR SHARE")
&& !peekKeyword("FOR UPDATE")
&& !peekKeyword("FOR XML")
&& parseKeyword("FOR") && requireProEdition()) {
else if (!ignoreProEdition() && parseForPeriodIf() && requireProEdition()) {
@ -7331,6 +7329,17 @@ final class DefaultParseContext extends AbstractScope implements ParseContext {
return t(result);
}
private final boolean parseForPeriodIf() {
return peekKeyword("FOR")
&& !peekKeyword("FOR JSON")
&& !peekKeyword("FOR KEY SHARE")
&& !peekKeyword("FOR NO KEY UPDATE")
&& !peekKeyword("FOR SHARE")
&& !peekKeyword("FOR UPDATE")
&& !peekKeyword("FOR XML")
&& parseKeyword("FOR");
}
private final String[] parseParenthesisedIdentifiers() {
return parseParenthesised(c -> map(parseIdentifiers(), Name::last, String[]::new));
}