Main   Products   Offshore Outsourcing   Customers   Partners   ContactUs  
JDBC Databases
  HXTT Access 7.1.131
  HXTT Cobol 5.0.131
  HXTT DBF 7.1.132
  HXTT Excel 6.1.135
  HXTT Json 1.0.103
  HXTT Paradox 7.1.131
  HXTT PDF 2.0.131
  HXTT Text(CSV) 7.1.131
  Buy Now
  HXTT Word 1.1.131
  HXTT XML 4.0.132
Offshore Outsourcing
Free Resources
  Firewall Tunneling
  Search Indexing Robot
  Conditional Compilation
  Password Recovery for MS Access
  Password Recovery for Corel Paradox
  Checksum Tool for MD5
  Character Set Converter
  Pyramid - Poker of ZYH
Heng Xing Tian Tai Lab of Xi'an City (abbr, HXTT)

Function substring fails
Remco Schoen
2010-06-25 06:00:34.0

I get an exception using the function substring on a csv-file.

I have this csv-file:


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(
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 Source)
at Source)
at Source)

With kind regards,

Remco Schoen
Re:Function substring fails
HXTT Support
2010-06-25 06:16:57.0
Checked SUBSTRING (Transact-SQL):
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.
Re:Re:Function substring fails
Remco Schoen
2010-06-29 01:13:51.0
Tried with the latest package and works!

Search Key   Search by Last 50 Questions


Copyright © 2003-2019 Heng Xing Tian Tai Lab of Xi'an City. | All Rights Reserved. | Privacy | Legal | Sitemap