Main   Products   Offshore Outsourcing   Customers   Partners   ContactUs  
JDBC Databases
  HXTT Access v5.2
  HXTT Cobol v2.1
  HXTT DBF v5.2
  HXTT Excel v4.2
  Buy Now
  HXTT Paradox v5.2
  HXTT Text(CSV) v5.2
  HXTT XML v1.2
Offshore Outsourcing
Oracle Data Import/Export
DB2 Data Import/Export
Sybase Data Import/Export
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
Hongxin Technology & Trade Ltd. of Xiangtan City (abbr, HXTT)

HXTT Excel
Mixed data type columns
Jeff Caldwell
2007-04-16 12:29:32.0
I am selecting data from a sheet with columns of mixed data types (e.g., 198765T, 864278,19-89765). I expected the column to be treated as all strings, yet the purely numeric values are being returned with a trailing decimal and zero (e.g., 864278.0) which is not in the original spreadsheet. How do I force the driver to treat these columns as type varchar and return only what was entered in the original sheet? I've tried CAST(), CONVERT(), CSTR() but the decimal and zero remain.
Re:Mixed data type columns
HXTT Support
2007-04-17 08:54:29.0
At Connecting to the Database, maxScanRows Indicates how many rows should be scanned when determining the column types. If you set maxScanRows to 0, the entire file is scanned. If you set maxScanRows to a negative value, the file won't be scanned. Default: 10
Try maxScanRows=-1.
Re:Re:Mixed data type columns
Jeff Caldwell
2007-04-17 10:55:16.0
I've followed your recommendation with no success. I've investigated further and found that the problem is with certain rows that were pasted in from another source. The cells apparently have some hidden "stuff" coming in with them that I can not see, but that causes them to always be selected as real numbers. The only way I was able to get the desired result was to apply the Excel "CLEAN()" function to the values and then paste them back into the cells.

I guess at this point I need to know if there is any way the hxtt driver can detect and/or strip out these extra characters in the same way that the Excel clean function does?
Re:Re:Re:Mixed data type columns
HXTT Support
2007-04-18 03:19:03.0
Pleaes email your xls sample, and let us know what's your issue.

Search Key   Search by Last 50 Questions


Address: 9 Station Rd., Xiangtan City, Hunan Province, P.R. China
Postcode: 411100
Phone: (86)731-58225727
Fax: (86)731-58225727
Copyright © 1999-2011 Hongxin Technology & Trade Ltd. | All Rights Reserved. | Privacy | Legal | Sitemap