Skip to content

Commit cf76aba

Browse files
authored
Minor: Update string tests for strpos (#12739)
1 parent 48bff75 commit cf76aba

File tree

4 files changed

+14
-67
lines changed

4 files changed

+14
-67
lines changed

datafusion/sqllogictest/test_files/string/large_string.slt

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -72,23 +72,6 @@ false false
7272
false true
7373
NULL NULL
7474

75-
# TODO: move it back to `string_query.slt.part` after fixing the issue
76-
# see detail: https://github.com/apache/datafusion/issues/12670
77-
query IIIIII
78-
SELECT
79-
STRPOS(ascii_1, 'e'),
80-
STRPOS(ascii_1, 'ang'),
81-
STRPOS(ascii_1, NULL),
82-
STRPOS(unicode_1, 'и'),
83-
STRPOS(unicode_1, 'ион'),
84-
STRPOS(unicode_1, NULL)
85-
FROM test_basic_operator;
86-
----
87-
5 0 NULL 0 0 NULL
88-
7 3 NULL 0 0 NULL
89-
6 0 NULL 18 18 NULL
90-
NULL NULL NULL NULL NULL NULL
91-
9275
#
9376
# common test for string-like functions and operators
9477
#

datafusion/sqllogictest/test_files/string/string.slt

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -63,23 +63,6 @@ Xiangpeng datafusion数据融合 false true false true
6363
Raphael datafusionДатаФусион false false false false
6464
NULL NULL NULL NULL NULL NULL
6565

66-
# TODO: move it back to `string_query.slt.part` after fixing the issue
67-
# see detail: https://github.com/apache/datafusion/issues/12670
68-
query IIIIII
69-
SELECT
70-
STRPOS(ascii_1, 'e'),
71-
STRPOS(ascii_1, 'ang'),
72-
STRPOS(ascii_1, NULL),
73-
STRPOS(unicode_1, 'и'),
74-
STRPOS(unicode_1, 'ион'),
75-
STRPOS(unicode_1, NULL)
76-
FROM test_basic_operator;
77-
----
78-
5 0 NULL 0 0 NULL
79-
7 3 NULL 0 0 NULL
80-
6 0 NULL 18 18 NULL
81-
NULL NULL NULL NULL NULL NULL
82-
8366
#
8467
# common test for string-like functions and operators
8568
#

datafusion/sqllogictest/test_files/string/string_query.slt.part

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -951,22 +951,20 @@ NULL NULL
951951
# Test STRPOS
952952
# --------------------------------------
953953

954-
# TODO: DictionaryString does not support STRPOS. Enable this after fixing the issue
955-
# see issue: https://github.com/apache/datafusion/issues/12670
956-
#query IIIIII
957-
#SELECT
958-
# STRPOS(ascii_1, 'e'),
959-
# STRPOS(ascii_1, 'ang'),
960-
# STRPOS(ascii_1, NULL),
961-
# STRPOS(unicode_1, 'и'),
962-
# STRPOS(unicode_1, 'ион'),
963-
# STRPOS(unicode_1, NULL)
964-
#FROM test_basic_operator;
965-
#----
966-
#5 0 NULL 0 0 NULL
967-
#7 3 NULL 0 0 NULL
968-
#6 0 NULL 18 18 NULL
969-
#NULL NULL NULL NULL NULL NULL
954+
query IIIIII
955+
SELECT
956+
STRPOS(ascii_1, 'e'),
957+
STRPOS(ascii_1, 'ang'),
958+
STRPOS(ascii_1, NULL),
959+
STRPOS(unicode_1, 'и'),
960+
STRPOS(unicode_1, 'ион'),
961+
STRPOS(unicode_1, NULL)
962+
FROM test_basic_operator;
963+
----
964+
5 0 NULL 0 0 NULL
965+
7 3 NULL 0 0 NULL
966+
6 0 NULL 18 18 NULL
967+
NULL NULL NULL NULL NULL NULL
970968

971969
# --------------------------------------
972970
# Test SUBSTR_INDEX

datafusion/sqllogictest/test_files/string/string_view.slt

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -50,23 +50,6 @@ false false
5050
false true
5151
NULL NULL
5252

53-
# TODO: move it back to `string_query.slt.part` after fixing the issue
54-
# see detail: https://github.com/apache/datafusion/issues/12670
55-
query IIIIII
56-
SELECT
57-
STRPOS(ascii_1, 'e'),
58-
STRPOS(ascii_1, 'ang'),
59-
STRPOS(ascii_1, NULL),
60-
STRPOS(unicode_1, 'и'),
61-
STRPOS(unicode_1, 'ион'),
62-
STRPOS(unicode_1, NULL)
63-
FROM test_basic_operator;
64-
----
65-
5 0 NULL 0 0 NULL
66-
7 3 NULL 0 0 NULL
67-
6 0 NULL 18 18 NULL
68-
NULL NULL NULL NULL NULL NULL
69-
7053
#
7154
# common test for string-like functions and operators
7255
#

0 commit comments

Comments
 (0)