[jOOQ/jOOQ#982] Add support for GIS extensions
- Add support for ST_AREA, ST_ASTEXT - Add support for SQL Server method style syntax - Add Geography type and Spatial super type
This commit is contained in:
parent
e78ce3cf76
commit
4475fa4e8b
@ -115,6 +115,5 @@ package org.jooq;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -214,6 +214,7 @@ import org.jooq.Field;
|
||||
import org.jooq.FieldOrRow;
|
||||
// ...
|
||||
// ...
|
||||
// ...
|
||||
import org.jooq.GroupConcatOrderByStep;
|
||||
import org.jooq.GroupConcatSeparatorStep;
|
||||
import org.jooq.GroupField;
|
||||
@ -367,6 +368,7 @@ import org.jooq.SelectForStep;
|
||||
import org.jooq.SelectSelectStep;
|
||||
import org.jooq.SelectWhereStep;
|
||||
import org.jooq.Sequence;
|
||||
// ...
|
||||
import org.jooq.Statement;
|
||||
import org.jooq.Stringly;
|
||||
import org.jooq.Support;
|
||||
@ -20512,6 +20514,58 @@ public class DSL {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -26722,6 +26776,18 @@ public class DSL {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -27622,6 +27688,28 @@ public class DSL {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -28169,6 +28257,17 @@ public class DSL {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -378,6 +378,8 @@ final class Names {
|
||||
static final Name N_STRING_AGG = unquotedName("string_agg");
|
||||
static final Name N_STRREVERSE = unquotedName("strreverse");
|
||||
static final Name N_STR_REPLACE = unquotedName("str_replace");
|
||||
static final Name N_ST_ASTEXT = unquotedName("st_astext");
|
||||
static final Name N_ST_AREA = unquotedName("st_area");
|
||||
static final Name N_ST_GEOMFROMTEXT = unquotedName("st_geomfromtext");
|
||||
static final Name N_ST_X = unquotedName("st_x");
|
||||
static final Name N_ST_Y = unquotedName("st_y");
|
||||
|
||||
@ -311,6 +311,8 @@ import static org.jooq.impl.DSL.sqrt;
|
||||
import static org.jooq.impl.DSL.square;
|
||||
// ...
|
||||
// ...
|
||||
// ...
|
||||
// ...
|
||||
import static org.jooq.impl.DSL.stddevPop;
|
||||
import static org.jooq.impl.DSL.stddevSamp;
|
||||
import static org.jooq.impl.DSL.substringIndex;
|
||||
@ -7543,6 +7545,35 @@ final class DefaultParseContext extends AbstractScope implements ParseContext {
|
||||
r = arrayGet((Field) toField(r), (Field) parseField());
|
||||
parse(']');
|
||||
}
|
||||
|
||||
r = parseMethodCallIf(r);
|
||||
return r;
|
||||
}
|
||||
|
||||
private FieldOrRow parseMethodCallIf(FieldOrRow r) {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
return r;
|
||||
}
|
||||
@ -7831,7 +7862,7 @@ final class DefaultParseContext extends AbstractScope implements ParseContext {
|
||||
|
||||
else if ((field = parseFieldGreatestIf()) != null)
|
||||
return field;
|
||||
else if (parseFunctionNameIf("GROUP_ID") && requireProEdition() && parse('(') && parse(')')) {
|
||||
else if (parseFunctionNameIf("GROUP_ID") && requireProEdition() && parseEmptyParens()) {
|
||||
|
||||
|
||||
|
||||
@ -7840,6 +7871,11 @@ final class DefaultParseContext extends AbstractScope implements ParseContext {
|
||||
return field;
|
||||
else if (parseFunctionNameIf("GROUPING"))
|
||||
return grouping(parseFieldParenthesised());
|
||||
else if ((parseFunctionNameIf("GEOMETRY::STGEOMFROMTEXT") || parseFunctionNameIf("GEOGRAPHY::STGEOMFROMTEXT")) && requireProEdition()) {
|
||||
|
||||
|
||||
|
||||
}
|
||||
else
|
||||
break;
|
||||
|
||||
@ -8079,7 +8115,7 @@ final class DefaultParseContext extends AbstractScope implements ParseContext {
|
||||
return parseFunctionArgs3(DSL::splitPart);
|
||||
else if ((field = parseFieldReplaceIf()) != null)
|
||||
return field;
|
||||
else if (parseFunctionNameIf("SCHEMA") && parseIf('(') && parse(')'))
|
||||
else if (parseFunctionNameIf("SCHEMA") && parseEmptyParensIf())
|
||||
return currentSchema();
|
||||
else if (parseFunctionNameIf("STRREVERSE"))
|
||||
return reverse((Field) parseFieldParenthesised());
|
||||
@ -8088,7 +8124,7 @@ final class DefaultParseContext extends AbstractScope implements ParseContext {
|
||||
|
||||
else if (parseFunctionNameIf("SECOND"))
|
||||
return second(parseFieldParenthesised());
|
||||
else if (parseFunctionNameIf("SEQ4", "SEQ8") && parse('(') && parse(')') && requireProEdition()) {
|
||||
else if (parseFunctionNameIf("SEQ4", "SEQ8") && parseEmptyParens() && requireProEdition()) {
|
||||
|
||||
|
||||
|
||||
@ -8110,6 +8146,16 @@ final class DefaultParseContext extends AbstractScope implements ParseContext {
|
||||
|
||||
else if ((field = parseFieldSysConnectByPathIf()) != null)
|
||||
return field;
|
||||
else if (parseFunctionNameIf("ST_AREA") && requireProEdition()) {
|
||||
|
||||
|
||||
|
||||
}
|
||||
else if (parseFunctionNameIf("ST_ASTEXT") && requireProEdition()) {
|
||||
|
||||
|
||||
|
||||
}
|
||||
else if (parseFunctionNameIf("ST_GEOMFROMTEXT") && requireProEdition()) {
|
||||
|
||||
|
||||
|
||||
@ -83,6 +83,7 @@ import org.jooq.Function7;
|
||||
import org.jooq.Function8;
|
||||
import org.jooq.Function9;
|
||||
// ...
|
||||
// ...
|
||||
import org.jooq.GroupField;
|
||||
import org.jooq.Index;
|
||||
import org.jooq.Internal;
|
||||
@ -107,6 +108,7 @@ import org.jooq.RowId;
|
||||
import org.jooq.Schema;
|
||||
import org.jooq.Select;
|
||||
import org.jooq.Sequence;
|
||||
// ...
|
||||
import org.jooq.Statement;
|
||||
import org.jooq.Table;
|
||||
import org.jooq.Traverser;
|
||||
@ -3452,6 +3454,28 @@ public final class QOM {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -88,6 +88,7 @@ import java.util.UUID;
|
||||
import org.jooq.Configuration;
|
||||
import org.jooq.DataType;
|
||||
// ...
|
||||
// ...
|
||||
import org.jooq.JSON;
|
||||
import org.jooq.JSONB;
|
||||
// ...
|
||||
@ -719,6 +720,15 @@ public final class SQLDataType {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -192,6 +192,10 @@ package org.jooq.impl;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -162,6 +162,10 @@ package org.jooq.impl;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -162,6 +162,10 @@ package org.jooq.impl;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user