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
  HXTT Paradox v5.2
  HXTT Text(CSV) v5.2
 
  Buy Now
  Support
  Download
  Document
  FAQ
  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 Text(CSV)
Text(CSV) skipping few header lines
ajay
2006-03-30 13:44:52.0
How can we skip some header lines from a text file, say with some report header (My Project Budget)?
Re:Text(CSV) skipping few header lines
HXTT Support
2006-03-30 16:43:27.0
Please email us a simple data sample, then we will provide a connection property to support that function soon.
Re:Re:Text(CSV) skipping few header lines
ajay
2006-03-30 16:50:01.0
Product report for FY 1996
- - - - - - - - - - - -

id,pid,sku,alias,caf,siz,typ,idate
1,1,100-10,Cola,TRUE,12,Can,03/25/1996
2,1,100-20,Diet Cola,TRUE,12,Can,04/01/1996
3,1,100-30,Caffeine Free Cola,FALSE,16,Bottle,04/01/1996
4,2,200-10,Old Fashioned,TRUE,12,Bottle,09/27/1995
5,2,200-20,Diet Root Beer,TRUE,16,Bottle,07/26/1996
6,2,200-30,Sasparilla,FALSE,12,Bottle,12/10/1996
7,2,200-40,Birch Beer,FALSE,16,Bottle,12/10/1996
8,3,300-10,Dark Cream,TRUE,20,Bottle,06/26/1996
9,3,300-20,Vanilla Cream,TRUE,20,Bottle,06/26/1996
10,3,300-30,Diet Cream,TRUE,12,Can,06/26/1996
11,4,400-10,Grape,FALSE,32,Bottle,10/01/1996
12,4,400-20,Orange,FALSE,32,Bottle,10/01/1996
13,4,400-30,Strawberry,FALSE,32,Bottle,10/01/1996
Re:Re:Re:Text(CSV) skipping few header lines
HXTT Support
2006-03-30 23:09:00.0
Supported. Please download the latest package. v2.2.015 provides _CSV_Comment to specify whether ther're some comment lines before csv header and data rows. If you use n (integer values), the first n lines will be ingored as comment. If you use some paragraphs, these paragraphs will be used for csv file creation, the total line number of comment will be used for existent file.

For instance:
Properties props=new Properties();
props.put("_CSV_Comment","3");
//Or props.put("_CSV_Comment","Product report for FY 1996\r\n- - - - - - - - - - - - \r\n\r\n");
Connection con DriverManager.getConnection(url,props);

create table FY1996 (_CSV_Separator char(1) default ',', _CSV_Quoter char(1) default null,_CSV_Header boolean default true,_CSV_Comment longvarchar default 'Product report for FY 1996\r\n- - - - - - - - - - - - \r\n\r\n');
Or
create table FY1996 (_CSV_Separator char(1) default ',', _CSV_Quoter char(1) default null,_CSV_Header boolean default true,_CSV_Comment longvarchar default 3);

Search Key   Search by Last 50 Questions




Google
 

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