sql 代码
- CREATE TABLE `customers` (
- `id` int(11) NOT NULL auto_increment,
- `name` varchar(255) default NULL,
- `full_name` varchar(255) default NULL,
- `bank_account` varchar(255) default NULL,
- `bank_name` varchar(255) default NULL,
- `tel` varchar(255) default NULL,
- `fax` varchar(255) default NULL,
- `email` varchar(255) default NULL,
- `address` text,
- `created_at` datetime default NULL,
- `updated_at` datetime default NULL,
- `lock_version` int(11) default '0',
- `default_discount` decimal(16,2) default '0.00',
- PRIMARY KEY (`id`)
- ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
xml 代码
- d:\customers.txt
- limitless in Seoul,Seoul limitless Store,880-009-098879,Seoul CCB,+81 877 0993 1828,+81 877 0993 18281,Seoul@limitless.foo,Seoul 1rd 809,2007-11-16 20:42:30,2007-11-16 20:42:30,0,0.50
- limitless in Hanoverian,Hanoverian limitless Store,880-009-098879,Hanoverian CCB,+82 877 0993 1828,+82 877 0993 18281,Hanoverian@limitless.foo,Hanoverian 1rd 809,2007-11-16 20:42:30,2007-11-16 20:42:30,0,0.55
- limitless in Paris,Paris limitless Store,880-009-098879,Paris CCB,+83 877 0993 1828,+83 877 0993 18281,Paris@limitless.foo,Paris 1rd 809,2007-11-16 20:42:30,2007-11-16 20:42:30,0,0.40
sql 代码
- LOAD DATA INFILE 'd:\customers.txt' INTO TABLE customers
- FIELDS TERMINATED BY ','
- (`name`,`full_name`,`bank_account`,`bank_name`,`tel`,`fax`,`email`,`address`,`created_at`,`updated_at`,`lock_version`,`default_discount`)