Skip to content

Commit 303b19f

Browse files
author
yixuanyxzhu
committed
[fix](function) Fix ArrayType.of parameter error in StGeometries
1 parent 8feb287 commit 303b19f

3 files changed

Lines changed: 496 additions & 1 deletion

File tree

fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/StGeometries.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ public class StGeometries extends ScalarFunction
3939
implements UnaryExpression, ExplicitlyCastableSignature, AlwaysNullable, PropagateNullLiteral {
4040

4141
public static final List<FunctionSignature> SIGNATURES = ImmutableList.of(
42-
FunctionSignature.ret(ArrayType.of(VarcharType.SYSTEM_DEFAULT, true))
42+
FunctionSignature.ret(ArrayType.of(VarcharType.SYSTEM_DEFAULT))
4343
.args(VarcharType.SYSTEM_DEFAULT)
4444
);
4545

Lines changed: 167 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,167 @@
1+
-- This file is automatically generated. You should know what you did if you want to edit this
2+
-- !intersection_overlap --
3+
POLYGON ((5 5, 10 5.01900181748964, 10 10, 5 10.0374230459107, 5 5))
4+
5+
-- !intersection_contains --
6+
POLYGON ((5 5, 15 5, 15 15, 5 15, 5 5))
7+
8+
-- !intersection_disjoint --
9+
\N
10+
11+
-- !intersection_same --
12+
POLYGON ((0 0, 10 0, 10 10, 0 10, 0 0))
13+
14+
-- !intersection_partial --
15+
POLYGON ((5 0, 10 0, 10 10, 7.50000000000002 10.0280636401533, 5 10, 5 0))
16+
17+
-- !difference_overlap --
18+
POLYGON ((5 10.0374230459107, 0 10, 0 0, 10 0, 10 5.01900181748964, 5 5, 5 10.0374230459107))
19+
20+
-- !difference_disjoint --
21+
POLYGON ((0 0, 10 0, 10 10, 0 10, 0 0))
22+
23+
-- !difference_same --
24+
\N
25+
26+
-- !difference_b_contains_a --
27+
\N
28+
29+
-- !difference_a_contains_b --
30+
POLYGON ((0 0, 10 0, 10 10, 0 10, 0 0), (3 3, 7 3, 7 7, 3 7, 3 3))
31+
32+
-- !difference_asymmetric_ab --
33+
POLYGON ((5 10, 7.50000000000002 10.0280636401533, 0 10, 0 0, 5 0, 5 10))
34+
35+
-- !difference_asymmetric_ba --
36+
POLYGON ((10 10, 10 0, 15 0, 15 10, 7.50000000000002 10.0280636401533, 10 10))
37+
38+
-- !symdiff_overlap --
39+
POLYGON ((5 10.0374230459107, 0 10, 0 0, 10 0, 10 5.01900181748964, 5 5, 5 10.0374230459107), (5 10.0374230459107, 10 10, 10 5.01900181748964, 15 5, 15 15, 5 15, 5 10.0374230459107))
40+
41+
-- !symdiff_disjoint --
42+
POLYGON ((0 0, 5 0, 5 5, 0 5, 0 0), (10 10, 15 10, 15 15, 10 15, 10 10))
43+
44+
-- !symdiff_same --
45+
\N
46+
47+
-- !symdiff_symmetric_ab --
48+
POLYGON ((5 10, 7.50000000000002 10.0280636401533, 0 10, 0 0, 5 0, 5 10), (7.50000000000002 10.0280636401533, 10 10, 10 0, 15 0, 15 10, 7.50000000000002 10.0280636401533))
49+
50+
-- !symdiff_symmetric_ba --
51+
POLYGON ((10 10, 10 0, 15 0, 15 10, 7.50000000000002 10.0280636401533, 10 10), (0 0, 5 0, 5 10, 7.50000000000002 10.0280636401533, 0 10, 0 0))
52+
53+
-- !intersection_null_left --
54+
\N
55+
56+
-- !intersection_null_right --
57+
\N
58+
59+
-- !difference_null --
60+
\N
61+
62+
-- !symdiff_null --
63+
\N
64+
65+
-- !intersection_point_polygon --
66+
\N
67+
68+
-- !difference_line_polygon --
69+
\N
70+
71+
-- !intersection_area --
72+
307105705487.048
73+
74+
-- !intersection_contains --
75+
false
76+
77+
-- !intersection_with_hole --
78+
POLYGON ((3 3, 10 3, 10 5.01900181748964, 5 5, 5 10.0149451409474, 3 10, 3 3))
79+
80+
-- !difference_with_hole --
81+
POLYGON ((5 10.0374230459107, 5 15, 15 15, 15 5, 10 5.01900181748964, 10 0, 20 0, 20 20, 0 20, 0 10, 5 10.0374230459107))
82+
83+
-- !intersection_touch_vertex --
84+
\N
85+
86+
-- !intersection_touch_edge --
87+
\N
88+
89+
-- !intersection_multipolygon --
90+
\N
91+
92+
-- !intersection_circle --
93+
\N
94+
95+
-- !intersection_small --
96+
POLYGON ((0.0005 0.0005, 0.001 0.000500000000038077, 0.001 0.001, 0.0005 0.00100000000003808, 0.0005 0.0005))
97+
98+
-- !intersection_triangle_square --
99+
POLYGON ((0 10, 5 0, 10 10, 0 10))
100+
101+
-- !difference_triangle_square --
102+
POLYGON ((5 0, 10 0, 10 10, 5 0), (0 10, 0 0, 5 0, 0 10))
103+
104+
-- !intersection_diamond_square --
105+
POLYGON ((2 3.00731896885612, 3.00487241049699 2.0015293661712, 6.99512758950301 2.0015293661712, 8 3.00731896885612, 8 7.02017035518359, 7.01511454794136 8.00594658035869, 2.98488545205864 8.00594658035869, 2 7.02017035518359, 2 3.00731896885612))
106+
107+
-- !symdiff_diamond_square --
108+
POLYGON ((8 3.00731896885612, 10 5, 8 7.02017035518359, 8 3.00731896885612), (7.01511454794136 8.00594658035869, 5 10, 2.98488545205864 8.00594658035869, 7.01511454794136 8.00594658035869), (2 7.02017035518359, 0 5, 2 3.00731896885612, 2 7.02017035518359), (3.00487241049699 2.0015293661712, 5 0, 6.99512758950301 2.0015293661712, 3.00487241049699 2.0015293661712), (8 3.00731896885612, 6.99512758950301 2.0015293661712, 8 2, 8 3.00731896885612), (7.01511454794136 8.00594658035869, 8 7.02017035518359, 8 8, 7.01511454794136 8.00594658035869), (2 7.02017035518359, 2.98488545205864 8.00594658035869, 2 8, 2 7.02017035518359), (2 2, 3.00487241049699 2.0015293661712, 2 3.00731896885612, 2 2))
109+
110+
-- !intersection_pentagon_square --
111+
POLYGON ((1 2.907251511176, 3.62319856379691 1.00215205480952, 6.37680143620309 1.00215205480952, 9 2.907251511176, 9 5.38235115050203, 8.36633451480864 7.00493579704068, 1.63366548519136 7.00493579704068, 1 5.38235115050203, 1 2.907251511176))
112+
113+
-- !intersection_hexagon_square --
114+
POLYGON ((2 2, 8 2, 8 8, 2 8, 2 2))
115+
116+
-- !intersection_lshape_square --
117+
POLYGON ((3 3, 10 3.00640067982583, 10 5, 5 5, 5 10, 3 10.0089608708822, 3 3))
118+
119+
-- !difference_lshape_square --
120+
POLYGON ((3 10.0089608708822, 0 10, 0 0, 10 0, 10 3.00640067982583, 3 3, 3 10.0089608708822))
121+
122+
-- !intersection_concave_square --
123+
POLYGON ((2 6.00363056258457, 4 6, 4 4, 2 4.00243025545118, 2 2, 8 2, 8 4.00243025545118, 6 4, 6 6, 8 6.00363056258457, 8 8, 2 8, 2 6.00363056258457))
124+
125+
-- !intersection_strip_square --
126+
POLYGON ((5 4.04609769179648, 15 4.04609769179648, 15 6.06886082819151, 5 6.06886082819151, 5 4.04609769179648))
127+
128+
-- !difference_strip_square --
129+
POLYGON ((15 4.04609769179648, 20 4, 20 6, 15 6.06886082819151, 15 4.04609769179648), (5 6.06886082819151, 0 6, 0 4, 5 4.04609769179648, 5 6.06886082819151))
130+
131+
-- !intersection_two_triangles --
132+
POLYGON ((5 0, 7.5 5.04314401088612, 5 10, 2.5 5.04314401088612, 5 0))
133+
134+
-- !symdiff_two_triangles --
135+
POLYGON ((5 0, 10 0, 7.5 5.04314401088612, 5 0), (2.5 5.04314401088612, 0 0, 5 0, 2.5 5.04314401088612), (2.5 5.04314401088612, 5 10, 7.5 5.04314401088612, 10 10, 0 10, 2.5 5.04314401088612))
136+
137+
-- !intersection_star_octagon --
138+
POLYGON ((0.76 4.67618502791496, 3.5 3.5, 4.67450012976417 0.760483937843262, 5.32549987023583 0.760483937843262, 6.5 3.5, 9.24 4.67618502791496, 9.24 5.32814067726992, 6.5 6.5, 5.32579021114234 9.24578250397916, 4.67420978885766 9.24578250397916, 3.5 6.5, 0.76 5.32814067726992, 0.76 4.67618502791496))
139+
140+
-- !intersection_irregular_triangle --
141+
POLYGON ((0.854805294035458 1.72878916071591, 1 1, 4 0, 7 2, 7.80781636986037 4.42516019666363, 6.0669960806028 7.90026060199019, 6 8, 4.27597377194228 8.57812928027526, 0.854805294035458 1.72878916071591))
142+
143+
-- !difference_irregular_triangle --
144+
POLYGON ((7.80781636986037 4.42516019666363, 8 5, 6.0669960806028 7.90026060199019, 7.80781636986037 4.42516019666363), (4.27597377194228 8.57812928027526, 3 9, 0 6, 0.854805294035458 1.72878916071591, 4.27597377194228 8.57812928027526))
145+
146+
-- !intersection_ushape_rect --
147+
POLYGON ((1 1, 9 1, 9 8, 8 8.00843389264136, 8 2, 2 2, 2 8.00843389264136, 1 8, 1 1))
148+
149+
-- !symdiff_ushape_rect --
150+
POLYGON ((1 8, 2 8.00843389264136, 2 10, 0 10, 0 0, 10 0, 10 10, 8 10, 8 8.00843389264136, 9 8, 9 1, 1 1, 1 8), (2 8.00843389264136, 2 2, 8 2, 8 8.00843389264136, 2 8.00843389264136))
151+
152+
-- !intersection_cross_square --
153+
POLYGON ((2 3.00091243694347, 3 3, 3 2.00152343441601, 7 2.00152343441601, 7 3, 8 3.00091243694347, 8 7.00211174691832, 7 7, 7 8.006019650934, 3 8.006019650934, 3 7, 2 7.00211174691832, 2 3.00091243694347))
154+
155+
-- !difference_cross_square --
156+
POLYGON ((8 3.00091243694347, 10 3, 10 7, 8 7.00211174691832, 8 3.00091243694347), (7 8.006019650934, 7 10, 3 10, 3 8.006019650934, 7 8.006019650934), (2 7.00211174691832, 0 7, 0 3, 2 3.00091243694347, 2 7.00211174691832), (3 2.00152343441601, 3 0, 7 0, 7 2.00152343441601, 3 2.00152343441601))
157+
158+
-- !table_intersection --
159+
1 POLYGON ((0 0, 10 0, 10 10, 0 10, 0 0))
160+
2 POLYGON ((5 10.0374230459107, 5 5, 10 5.01900181748964, 10 10, 5 10.0374230459107))
161+
3 \N
162+
163+
-- !table_difference --
164+
1 \N
165+
2 POLYGON ((10 10, 10 5.01900181748964, 15 5, 15 15, 5 15, 5 10.0374230459107, 10 10))
166+
3 POLYGON ((20 20, 30 20, 30 30, 20 30, 20 20))
167+

0 commit comments

Comments
 (0)