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)

default column definition of an empty csv
2014-11-27 21:04:47.0

this actually only aesthetic issue, here we have an empty headerless csv file with zero bytes size

when we issue select to this empty file, hxtt will return empty resultset with predefined 25 columns (column1 to column25)

the test query is:

select column1 as id, column26 as my_column from empty.csv

this csv file is generated by other program, and normally have about 150 columns, so when the file is empty, the query will return error "Invalid column or variable: column26"

is it possible to make the resultset column definition (ResultSet.getMetaData().getColumnLabel) matches the query so this error does not happen ?

thank you
Re:default column definition of an empty csv
HXTT Support
2014-11-28 04:45:23.0
_CSV_ColumnCount4EmptyFile: To specify the default column count for an empty text file without header information and data rows. Default: 25
You can use _CSV_ColumnCount4EmptyFile=150 connection property.

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