Hello,
I get an exception using the function substring on a csv-file.
I have this csv-file:
"column1";"column2"
"value1";"value2"
"value12";"value22"
Url: jdbc:csv:/.?delayedClose=0;_CSV_Separator=\x3b;_CSV_Quoter=";_CSV_Header=true
Query: select substring(column1, 1, 10) from substring.csv
The stacktrace:
java.lang.StringIndexOutOfBoundsException: String index out of range: 10
at java.lang.String.substring(String.java:1934)
at com.hxtt.d.d.aL(Unknown Source)
at com.hxtt.d.d.a(Unknown Source)
at com.hxtt.d.k.if(Unknown Source)
at com.hxtt.sql.dj.a(Unknown Source)
at com.hxtt.sql.c1.new(Unknown Source)
at com.hxtt.sql.c1.next(Unknown Source)
With kind regards,
Remco Schoen
|
Checked SUBSTRING (Transact-SQL):
length_expression:
Is a positive integer or bigint expression that specifies how many characters of the value_expression will be returned. If length_expression is negative, an error is generated and the statement is terminated. If the sum of start_expression and length_expression is greater than the number of characters in value_expression, the whole value expression beginning at start_expression is returned.
We will fix and upload a ltest package in 2 hours.
|
Tried with the latest package and works!
|