Main   Products   Offshore Outsourcing   Customers   Partners   ContactUs  
JDBC Databases
  HXTT Access v7.1
  HXTT Cobol v5.0
  HXTT DBF v7.1
  HXTT Excel v6.1
  HXTT Json v1.0
  HXTT Paradox v7.1
  HXTT PDF v2.0
  HXTT Text(CSV) v7.1
  Buy Now
  HXTT Word v1.1
  HXTT XML v4.0
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)

Column types
2006-09-11 15:38:36

Is there a way (for example a property) to force the HXTT text driver to consider all columns of a query as string columns without the need to construct a CREATE TABLE statement? If not could you consider implementing this?

Thanks in advance,
Re:Column types
HXTT Support
2006-09-11 18:41:19
For CSV, PSV, and TSV, it can do that things easily, for instance,
jdbc:csv:////usr/data?csvfileExtension=TXT;_CSV_Header=true //all CSV files with TXT extension, and first line for column names.
jdbc:csv:////usr/data?_CSV_Separator=\t //TSV file without column name header.
jdbc:csv:////usr/data?_CSV_Separator=|;maxScanRows=-1 //PSV file's column type will be regarded as varchar without detection automatically.

Then you can use all sqls without CREATE TABLE sql:)

For plain text which can't be detected without column separator help, you need CREATE TABLE sql. It supports universal table declaration for a series of tables with the same table structure. '?' represents any single character, and '*' represents a string of zero or more characters. For instance, create table "*.log" (...); create table [*a?b.*"] (...). Universal table declaration is only visible for the current connection, and isn't prior to any specific table declaration. You can store all common table declaration sql in schemaFile(connection property, can be load from any (absolute or relative) path, even you can load it from http url or compressed file.), then you needn't to call CREATE TABLE in your program.

Re:Re:Column types
HXTT Support
2006-09-11 18:42:42
If those above hints can't help you, please let us know your situation, suggestion and requirement:)

Search Key   Search by Last 50 Questions


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