Skip to content

Commit

Permalink
Fix issue 2106: Add parsing functionality for MySQL ADD PARTITION and…
Browse files Browse the repository at this point in the history
… DROP PARTITION clauses in ALTER TABLE statements(2) (#2108)

* feat MySQL Alter add partition

* fix PartitionDefinition to Serializable

* add Engine variable to MySQL partition definition

* fix: Update parser to correctly handle ENGINE token and pass existing CREATE TABLE tests

* feat mysql alter drop partition

* refactor truncate partition

* fix codacy

* fix: add LOOKAHEADs

Signed-off-by: Andreas Reichel <[email protected]>

* doc: mention running `gradle check`

Signed-off-by: Andreas Reichel <[email protected]>

* style: add license header

Signed-off-by: Andreas Reichel <[email protected]>

---------

Signed-off-by: Andreas Reichel <[email protected]>
Co-authored-by: mj-db <[email protected]>
Co-authored-by: Andreas Reichel <[email protected]>
  • Loading branch information
3 people authored Nov 14, 2024
1 parent 7b0e42f commit 12952d6
Show file tree
Hide file tree
Showing 7 changed files with 158 additions and 37 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ public class AlterExpression implements Serializable {
private boolean uk;
private boolean useEqual;

private List<String> partitions;
private List<PartitionDefinition> partitionDefinitions;
private List<ConstraintState> constraints;
private List<String> parameters;
Expand All @@ -63,8 +64,6 @@ public class AlterExpression implements Serializable {

private boolean useBrackets = false;

private String truncatePartitionName = null;

private boolean useIfNotExists = false;

public Index getOldIndex() {
Expand Down Expand Up @@ -433,19 +432,6 @@ public void setUk(boolean uk) {
this.uk = uk;
}

public String getTruncatePartitionName() {
return truncatePartitionName;
}

public void setTruncatePartitionName(String truncatePartitionName) {
this.truncatePartitionName = truncatePartitionName;
}

public AlterExpression withTruncatePartitionName(String truncatePartitionName) {
this.truncatePartitionName = truncatePartitionName;
return this;
}

public boolean isUseIfNotExists() {
return useIfNotExists;
}
Expand Down Expand Up @@ -499,8 +485,8 @@ public String toString() {
// Oracle Multi Column Drop
b.append("DROP (").append(PlainSelect.getStringList(pkColumns)).append(')');
} else if (operation == AlterOperation.TRUNCATE_PARTITION
&& truncatePartitionName != null) {
b.append("TRUNCATE PARTITION ").append(truncatePartitionName);
&& partitions != null) {
b.append("TRUNCATE PARTITION ").append(PlainSelect.getStringList(partitions));
} else {
if (operation == AlterOperation.COMMENT_WITH_EQUAL_SIGN) {
b.append("COMMENT =").append(" ");
Expand Down Expand Up @@ -784,6 +770,14 @@ public AlterExpression addConstraints(Collection<? extends ConstraintState> cons
return this.withConstraints(collection);
}

public List<String> getPartitions() {
return partitions;
}

public void setPartitions(List<String> partitions) {
this.partitions = partitions;
}

public List<PartitionDefinition> getPartitionDefinitions() {
return partitionDefinitions;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
package net.sf.jsqlparser.statement.alter;

public enum AlterOperation {
ADD, ALTER, DROP, DROP_PRIMARY_KEY, DROP_UNIQUE, DROP_FOREIGN_KEY, MODIFY, CHANGE, CONVERT, ALGORITHM, RENAME, RENAME_TABLE, RENAME_INDEX, RENAME_KEY, RENAME_CONSTRAINT, COMMENT, COMMENT_WITH_EQUAL_SIGN, UNSPECIFIC, ADD_PARTITION, TRUNCATE_PARTITION, LOCK;
ADD, ALTER, DROP, DROP_PRIMARY_KEY, DROP_UNIQUE, DROP_FOREIGN_KEY, MODIFY, CHANGE, CONVERT, ALGORITHM, RENAME, RENAME_TABLE, RENAME_INDEX, RENAME_KEY, RENAME_CONSTRAINT, COMMENT, COMMENT_WITH_EQUAL_SIGN, UNSPECIFIC, ADD_PARTITION, DROP_PARTITION, TRUNCATE_PARTITION, LOCK;

public static AlterOperation from(String operation) {
return Enum.valueOf(AlterOperation.class, operation.toUpperCase());
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
/*-
* #%L
* JSQLParser library
* %%
* Copyright (C) 2004 - 2024 JSQLParser
* %%
* Dual licensed under GNU LGPL 2.1 or Apache License 2.0
* #L%
*/
package net.sf.jsqlparser.statement.create.table;

import java.io.Serializable;
Expand All @@ -7,12 +16,14 @@ public class PartitionDefinition implements Serializable {
private String partitionName;
private String partitionOperation;
private List<String> values;
private String storageEngine;

public PartitionDefinition(String partitionName, String partitionOperation,
List<String> values) {
List<String> values, String storageEngine) {
this.partitionName = partitionName;
this.partitionOperation = partitionOperation;
this.values = values;
this.storageEngine = storageEngine;
}

public String getPartitionName() {
Expand All @@ -38,4 +49,12 @@ public List<String> getValues() {
public void setValues(List<String> values) {
this.values = values;
}

public String getStorageEngine() {
return storageEngine;
}

public void setStorageEngine(String storageEngine) {
this.storageEngine = storageEngine;
}
}
46 changes: 41 additions & 5 deletions src/main/jjtree/net/sf/jsqlparser/parser/JSqlParserCC.jjt
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,7 @@ TOKEN: /* SQL Keywords. prefixed with K_ to avoid name clashes */
| <K_EMIT: "EMIT">
| <K_ENABLE: "ENABLE">
| <K_END: "END">
| <K_ENGINE: "ENGINE">
| <K_ERROR: "ERROR">
| <K_ESCAPE: "ESCAPE">
| <K_EXCEPT: "EXCEPT">
Expand Down Expand Up @@ -2021,7 +2022,7 @@ String RelObjectNameWithoutValue() :
{ Token tk = null; }
{
( tk=<DATA_TYPE> | tk=<S_IDENTIFIER> | tk=<S_QUOTED_IDENTIFIER> | tk=<K_DATE_LITERAL> | tk=<K_DATETIMELITERAL> | tk=<K_STRING_FUNCTION_NAME> | tk=<K_ISOLATION> | tk=<K_TIME_KEY_EXPR> | tk=<K_TEXT_LITERAL>
| tk="ACTION" | tk="ACTIVE" | tk="ADD" | tk="ADVANCE" | tk="ADVISE" | tk="AGAINST" | tk="ALGORITHM" | tk="ALTER" | tk="ANALYZE" | tk="APPLY" | tk="APPROXIMATE" | tk="ARCHIVE" | tk="ARRAY" | tk="ASC" | tk="AT" | tk="AUTHORIZATION" | tk="AUTO" | tk="BASE64" | tk="BEGIN" | tk="BERNOULLI" | tk="BINARY" | tk="BIT" | tk="BLOCK" | tk="BROWSE" | tk="BUFFERS" | tk="BY" | tk="BYTE" | tk="BYTES" | tk="CACHE" | tk="CALL" | tk="CASCADE" | tk="CASE" | tk="CAST" | tk="CHANGE" | tk="CHANGES" | tk="CHAR" | tk="CHARACTER" | tk="CHECKPOINT" | tk="CLOSE" | tk="COLLATE" | tk="COLUMN" | tk="COLUMNS" | tk="COMMENT" | tk="COMMIT" | tk="CONCURRENTLY" | tk="CONFLICT" | tk="CONSTRAINTS" | tk="CONVERT" | tk="COSTS" | tk="COUNT" | tk="CS" | tk="CYCLE" | tk="DATA" | tk="DATABASE" | tk="DATETIME" | tk="DBA_RECYCLEBIN" | tk="DDL" | tk="DECLARE" | tk="DEFERRABLE" | tk="DELAYED" | tk="DELETE" | tk="DESC" | tk="DESCRIBE" | tk="DISABLE" | tk="DISCONNECT" | tk="DIV" | tk="DML" | tk="DO" | tk="DOMAIN" | tk="DROP" | tk="DUMP" | tk="DUPLICATE" | tk="ELEMENTS" | tk="EMIT" | tk="ENABLE" | tk="END" | tk="ERROR" | tk="ESCAPE" | tk="EXCLUDE" | tk="EXEC" | tk="EXECUTE" | tk="EXPLAIN" | tk="EXPLICIT" | tk="EXTENDED" | tk="EXTRACT" | tk="FALSE" | tk="FILTER" | tk="FIRST" | tk="FLUSH" | tk="FN" | tk="FOLLOWING" | tk="FORMAT" | tk="FULLTEXT" | tk="FUNCTION" | tk="GRANT" | tk="GROUP_CONCAT" | tk="GUARD" | tk="HASH" | tk="HIGH_PRIORITY" | tk="HISTORY" | tk="HOPPING" | tk="INCLUDE" | tk="INCLUDE_NULL_VALUES" | tk="INCREMENT" | tk="INDEX" | tk="INSERT" | tk="INTERLEAVE" | tk="INTERPRET" | tk="INVALIDATE" | tk="ISNULL" | tk="JSON" | tk="JSON_ARRAY" | tk="JSON_ARRAYAGG" | tk="JSON_OBJECT" | tk="JSON_OBJECTAGG" | tk="KEEP" | tk="KEY" | tk="KEYS" | tk="LAST" | tk="LEADING" | tk="LESS" | tk="LINK" | tk="LOCAL" | tk="LOCK" | tk="LOCKED" | tk="LOG" | tk="LONGTEXT" | tk="LOOP" | tk="LOW_PRIORITY" | tk="MATCH" | tk="MATCHED" | tk="MATERIALIZED" | tk="MAX" | tk="MAXVALUE" | tk="MEDIUMTEXT" | tk="MEMBER" | tk="MERGE" | tk="MIN" | tk="MINVALUE" | tk="MODIFY" | tk="MOVEMENT" | tk="NEXT" | tk="NO" | tk="NOCACHE" | tk="NOKEEP" | tk="NOLOCK" | tk="NOMAXVALUE" | tk="NOMINVALUE" | tk="NOORDER" | tk="NOTHING" | tk="NOTNULL" | tk="NOVALIDATE" | tk="NOWAIT" | tk="NULLS" | tk="OF" | tk="OFF" | tk="OPEN" | tk="OVER" | tk="OVERFLOW" | tk="OVERLAPS" | tk="PARALLEL" | tk="PARENT" | tk="PARTITION" | tk="PATH" | tk="PERCENT" | tk="PLACING" | tk="PLAN" | tk="PRECEDING" | tk="PRIMARY" | tk="PURGE" | tk="QUERY" | tk="QUICK" | tk="QUIESCE" | tk="RANGE" | tk="RAW" | tk="READ" | tk="RECURSIVE" | tk="RECYCLEBIN" | tk="REFERENCES" | tk="REFRESH" | tk="REGEXP" | tk="REGEXP_LIKE" | tk="REGISTER" | tk="REMOTE" | tk="RENAME" | tk="REPEATABLE" | tk="REPLACE" | tk="RESET" | tk="RESPECT" | tk="RESTART" | tk="RESTRICT" | tk="RESTRICTED" | tk="RESUMABLE" | tk="RESUME" | tk="RETURN" | tk="RLIKE" | tk="ROLLBACK" | tk="ROLLUP" | tk="ROOT" | tk="ROW" | tk="ROWS" | tk="RR" | tk="RS" | tk="SAFE_CAST" | tk="SAVEPOINT" | tk="SCHEMA" | tk="SECURE" | tk="SEED" | tk="SEPARATOR" | tk="SEQUENCE" | tk="SESSION" | tk="SETS" | tk="SHARE" | tk="SHOW" | tk="SHUTDOWN" | tk="SIBLINGS" | tk="SIGNED" | tk="SIMILAR" | tk="SIZE" | tk="SKIP" | tk="STORED" | tk="STRING" | tk="STRUCT" | tk="SUMMARIZE" | tk="SUSPEND" | tk="SWITCH" | tk="SYNONYM" | tk="SYSTEM" | tk="TABLE" | tk="TABLESPACE" | tk="TEMP" | tk="TEMPORARY" | tk="TEXT" | tk="THAN" | tk="THEN" | tk="TIMEOUT" | tk="TIMESTAMPTZ" | tk="TIMEZONE" | tk="TINYTEXT" | tk="TO" | tk="TRIGGER" | tk="TRUE" | tk="TRUNCATE" | tk="TRY_CAST" | tk="TUMBLING" | tk="TYPE" | tk="UNLOGGED" | tk="UNQIESCE" | tk="UNSIGNED" | tk="UPDATE" | tk="UPSERT" | tk="UR" | tk="USER" | tk="VALIDATE" | tk="VERBOSE" | tk="VIEW" | tk="VOLATILE" | tk="WAIT" | tk="WITHIN" | tk="WITHOUT" | tk="WITHOUT_ARRAY_WRAPPER" | tk="WORK" | tk="XML" | tk="XMLAGG" | tk="XMLDATA" | tk="XMLSCHEMA" | tk="XMLTEXT" | tk="XSINIL" | tk="YAML" | tk="YES" | tk="ZONE" )
| tk="ACTION" | tk="ACTIVE" | tk="ADD" | tk="ADVANCE" | tk="ADVISE" | tk="AGAINST" | tk="ALGORITHM" | tk="ALTER" | tk="ANALYZE" | tk="APPLY" | tk="APPROXIMATE" | tk="ARCHIVE" | tk="ARRAY" | tk="ASC" | tk="AT" | tk="AUTHORIZATION" | tk="AUTO" | tk="BASE64" | tk="BEGIN" | tk="BERNOULLI" | tk="BINARY" | tk="BIT" | tk="BLOCK" | tk="BROWSE" | tk="BUFFERS" | tk="BY" | tk="BYTE" | tk="BYTES" | tk="CACHE" | tk="CALL" | tk="CASCADE" | tk="CASE" | tk="CAST" | tk="CHANGE" | tk="CHANGES" | tk="CHAR" | tk="CHARACTER" | tk="CHECKPOINT" | tk="CLOSE" | tk="COLLATE" | tk="COLUMN" | tk="COLUMNS" | tk="COMMENT" | tk="COMMIT" | tk="CONCURRENTLY" | tk="CONFLICT" | tk="CONSTRAINTS" | tk="CONVERT" | tk="COSTS" | tk="COUNT" | tk="CS" | tk="CYCLE" | tk="DATA" | tk="DATABASE" | tk="DATETIME" | tk="DBA_RECYCLEBIN" | tk="DDL" | tk="DECLARE" | tk="DEFERRABLE" | tk="DELAYED" | tk="DELETE" | tk="DESC" | tk="DESCRIBE" | tk="DISABLE" | tk="DISCONNECT" | tk="DIV" | tk="DML" | tk="DO" | tk="DOMAIN" | tk="DROP" | tk="DUMP" | tk="DUPLICATE" | tk="ELEMENTS" | tk="EMIT" | tk="ENABLE" | tk="END" | tk="ENGINE" | tk="ERROR" | tk="ESCAPE" | tk="EXCLUDE" | tk="EXEC" | tk="EXECUTE" | tk="EXPLAIN" | tk="EXPLICIT" | tk="EXTENDED" | tk="EXTRACT" | tk="FALSE" | tk="FILTER" | tk="FIRST" | tk="FLUSH" | tk="FN" | tk="FOLLOWING" | tk="FORMAT" | tk="FULLTEXT" | tk="FUNCTION" | tk="GRANT" | tk="GROUP_CONCAT" | tk="GUARD" | tk="HASH" | tk="HIGH_PRIORITY" | tk="HISTORY" | tk="HOPPING" | tk="INCLUDE" | tk="INCLUDE_NULL_VALUES" | tk="INCREMENT" | tk="INDEX" | tk="INSERT" | tk="INTERLEAVE" | tk="INTERPRET" | tk="INVALIDATE" | tk="ISNULL" | tk="JSON" | tk="JSON_ARRAY" | tk="JSON_ARRAYAGG" | tk="JSON_OBJECT" | tk="JSON_OBJECTAGG" | tk="KEEP" | tk="KEY" | tk="KEYS" | tk="LAST" | tk="LEADING" | tk="LESS" | tk="LINK" | tk="LOCAL" | tk="LOCK" | tk="LOCKED" | tk="LOG" | tk="LONGTEXT" | tk="LOOP" | tk="LOW_PRIORITY" | tk="MATCH" | tk="MATCHED" | tk="MATERIALIZED" | tk="MAX" | tk="MAXVALUE" | tk="MEDIUMTEXT" | tk="MEMBER" | tk="MERGE" | tk="MIN" | tk="MINVALUE" | tk="MODIFY" | tk="MOVEMENT" | tk="NEXT" | tk="NO" | tk="NOCACHE" | tk="NOKEEP" | tk="NOLOCK" | tk="NOMAXVALUE" | tk="NOMINVALUE" | tk="NOORDER" | tk="NOTHING" | tk="NOTNULL" | tk="NOVALIDATE" | tk="NOWAIT" | tk="NULLS" | tk="OF" | tk="OFF" | tk="OPEN" | tk="OVER" | tk="OVERFLOW" | tk="OVERLAPS" | tk="PARALLEL" | tk="PARENT" | tk="PARTITION" | tk="PATH" | tk="PERCENT" | tk="PLACING" | tk="PLAN" | tk="PRECEDING" | tk="PRIMARY" | tk="PURGE" | tk="QUERY" | tk="QUICK" | tk="QUIESCE" | tk="RANGE" | tk="RAW" | tk="READ" | tk="RECURSIVE" | tk="RECYCLEBIN" | tk="REFERENCES" | tk="REFRESH" | tk="REGEXP" | tk="REGEXP_LIKE" | tk="REGISTER" | tk="REMOTE" | tk="RENAME" | tk="REPEATABLE" | tk="REPLACE" | tk="RESET" | tk="RESPECT" | tk="RESTART" | tk="RESTRICT" | tk="RESTRICTED" | tk="RESUMABLE" | tk="RESUME" | tk="RETURN" | tk="RLIKE" | tk="ROLLBACK" | tk="ROLLUP" | tk="ROOT" | tk="ROW" | tk="ROWS" | tk="RR" | tk="RS" | tk="SAFE_CAST" | tk="SAVEPOINT" | tk="SCHEMA" | tk="SECURE" | tk="SEED" | tk="SEPARATOR" | tk="SEQUENCE" | tk="SESSION" | tk="SETS" | tk="SHARE" | tk="SHOW" | tk="SHUTDOWN" | tk="SIBLINGS" | tk="SIGNED" | tk="SIMILAR" | tk="SIZE" | tk="SKIP" | tk="STORED" | tk="STRING" | tk="STRUCT" | tk="SUMMARIZE" | tk="SUSPEND" | tk="SWITCH" | tk="SYNONYM" | tk="SYSTEM" | tk="TABLE" | tk="TABLESPACE" | tk="TEMP" | tk="TEMPORARY" | tk="TEXT" | tk="THAN" | tk="THEN" | tk="TIMEOUT" | tk="TIMESTAMPTZ" | tk="TIMEZONE" | tk="TINYTEXT" | tk="TO" | tk="TRIGGER" | tk="TRUE" | tk="TRUNCATE" | tk="TRY_CAST" | tk="TUMBLING" | tk="TYPE" | tk="UNLOGGED" | tk="UNQIESCE" | tk="UNSIGNED" | tk="UPDATE" | tk="UPSERT" | tk="UR" | tk="USER" | tk="VALIDATE" | tk="VERBOSE" | tk="VIEW" | tk="VOLATILE" | tk="WAIT" | tk="WITHIN" | tk="WITHOUT" | tk="WITHOUT_ARRAY_WRAPPER" | tk="WORK" | tk="XML" | tk="XMLAGG" | tk="XMLDATA" | tk="XMLSCHEMA" | tk="XMLTEXT" | tk="XSINIL" | tk="YAML" | tk="YES" | tk="ZONE" )
{ return tk.image; }
}

Expand Down Expand Up @@ -6695,6 +6696,7 @@ List<String> CreateParameter():
| tk=<K_TYPE> | tk=<K_COMMENT> | tk=<K_USING> | tk=<K_COLLATE> | tk=<K_ASC>
| tk=<K_DESC> | tk=<K_TRUE> | tk=<K_FALSE> | tk=<K_PARALLEL> | tk=<K_BINARY> | tk=<K_START>
| tk=<K_TIME_KEY_EXPR> | tk=<K_RAW> | tk=<K_HASH> | tk=<K_FIRST> | tk=<K_LAST> | tk = <K_SIGNED> | tk = <K_UNSIGNED>
| tk=<K_ENGINE>
| tk="="
)
{ param.add(tk.image); }
Expand Down Expand Up @@ -7022,6 +7024,7 @@ List<PartitionDefinition> PartitionDefinitions():
PartitionDefinition partitionDef = null;
String partitionName = null;
String partitionOperation = null;
String storageEngine = null;
}
{
"("
Expand All @@ -7044,8 +7047,9 @@ List<PartitionDefinition> PartitionDefinitions():
partitionOperation = "VALUES LESS THAN";
}
)
[ "ENGINE" "=" tk=<S_IDENTIFIER> { storageEngine = tk.image; } ]
{
partitionDef = new PartitionDefinition(partitionName, partitionOperation, values);
partitionDef = new PartitionDefinition(partitionName, partitionOperation, values, storageEngine);
partitionDefinitions.add(partitionDef);
}
[ "," ]
Expand All @@ -7056,6 +7060,26 @@ List<PartitionDefinition> PartitionDefinitions():
}
}


List<String> PartitionNamesList() :
{
Token tk;
List<String> partitionNames = new ArrayList<String>();
}
{
tk = <S_IDENTIFIER> {
partitionNames.add(tk.image);
}
(
LOOKAHEAD(2) "," tk = <S_IDENTIFIER> {
partitionNames.add(tk.image);
}
)*
{
return partitionNames;
}
}

/**
* This production needs refactoring to multiple smaller productions. The target class should
* be splitted as well.
Expand All @@ -7077,6 +7101,7 @@ AlterExpression AlterExpression():
AlterExpression.ColumnDropNotNull alterExpressionColumnDropNotNull = null;
AlterExpression.ColumnDropDefault alterExpressionColumnDropDefault = null;
ReferentialAction.Action action = null;
List<String> partitions = null;
List<PartitionDefinition> partitionDefinition = null;
String truncatePartitionName = null;

Expand Down Expand Up @@ -7120,9 +7145,8 @@ AlterExpression AlterExpression():
sk3=RelObjectName() <K_COMMENT> tk=<S_CHAR_LITERAL> { alterExp.withColumnName(sk3).withCommentText(tk.image); }
)
|
(
LOOKAHEAD(3) (
<K_PARTITION> {
System.out.println("test _ Partition");
alterExp.setOperation(AlterOperation.ADD_PARTITION);
}
partitionDefinition=PartitionDefinitions() {
Expand Down Expand Up @@ -7292,6 +7316,15 @@ AlterExpression AlterExpression():
|
<K_DROP> { alterExp.setOperation(AlterOperation.DROP); }
(
(
<K_PARTITION> {
alterExp.setOperation(AlterOperation.DROP_PARTITION);
}
partitions=PartitionNamesList() {
alterExp.setPartitions(partitions);
}
)
|
(
(
// we use the PK Columns Field instead of the Column Field
Expand Down Expand Up @@ -7403,7 +7436,10 @@ AlterExpression AlterExpression():
}
)
|
LOOKAHEAD(2) <K_TRUNCATE> <K_PARTITION> { alterExp.setOperation(AlterOperation.TRUNCATE_PARTITION); } truncatePartitionName = RelObjectName() { alterExp.setTruncatePartitionName(truncatePartitionName); }
LOOKAHEAD(2) <K_TRUNCATE> <K_PARTITION> { alterExp.setOperation(AlterOperation.TRUNCATE_PARTITION); }
partitions=PartitionNamesList() {
alterExp.setPartitions(partitions);
}
|
tokens = captureRest() {
alterExp.setOperation(AlterOperation.UNSPECIFIC);
Expand Down
17 changes: 16 additions & 1 deletion src/site/sphinx/contribution.rst
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,22 @@ The JSQLParser is generated by ``JavaCC`` based on the provided Grammar. The Gra
* The complete test suite must succeed.

5) Add the description of the new feature to the ``README.md`` file, section `Extensions`.
6) Build the package with ``Maven`` and ensure, all checks do pass (PMD and CheckStyle and Code Formatting).
6) Build the package with ``Gradle`` and ensure, all checks do pass (PMD and CheckStyle and Code Formatting).
.. tab:: Gradle

.. code-block:: shell
:caption: Gradle `check` Task
gradle check
.. tab:: Maven

.. code-block:: shell
:caption: Maven `verify` Task
mvn verify
7) Create your `GitHub Pull Request <https://www.youtube.com/watch?v=nCKdihvneS0>`_

Manage Reserved Keywords
------------------------------
Expand Down
12 changes: 0 additions & 12 deletions src/site/sphinx/unsupported.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,6 @@ Unsupported Grammar of various RDBMS
*JSQLParser* is a RDBMS agnostic parser with a certain focus on SQL:2016 Standard compliant Queries and the "Big Four" (Oracle, MS SQL Server, Postgres, MySQL/MariaDB).
We would like to recommend writing portable, standard compliant SQL in general.

- Postgres Implicit cast is not supported.

.. code-block:: java
SELECT date '2022-12-31';
SELECT double precision 1;
- Oracle PL/SQL blocks are not support.

.. code-block:: sql
Expand Down Expand Up @@ -40,10 +32,6 @@ We would like to recommend writing portable, standard compliant SQL in general.

While *JSQLParser* provides a lot of generic support for DDL statements, it is possible that certain RDBMS specific syntax (especially about indices, encodings, compression) won't be supported.

- `JSON` or `XML` specific syntax and functions

While *JSQLParser* provides a lot of generic support for `JSON` or `XML` processing, it is possible that certain RDBMS specific syntax or functions won't be supported.

- Interval Operators

Anything like `DAY HOUR MINUTE SECOND [TO HOUR MINUTE SECOND]` is not supported.:
Expand Down
Loading

0 comments on commit 12952d6

Please sign in to comment.