Created
July 15, 2013 14:05
-
-
Save IanHopkinson/6000184 to your computer and use it in GitHub Desktop.
SQL to upload the two big MOT data files to a MySQL database, requires the tables to by using the MyIASM engine.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
USE MOT; | |
ALTER TABLE testitem DISABLE KEYS; | |
LOAD DATA LOCAL INFILE '[yourpath \\ separated in Windows]UAT_test_item_2011.txt' | |
INTO TABLE testitem | |
FIELDS TERMINATED BY '|' | |
LINES TERMINATED BY '\n' | |
; | |
ALTER TABLE testitem ENABLE KEYS; | |
ALTER TABLE testresult DISABLE KEYS; | |
LOAD DATA LOCAL INFILE '[yourpath \\ separated in Windows]UAT_test_result_2011.txt' | |
INTO TABLE testresult | |
FIELDS TERMINATED BY '|' | |
LINES TERMINATED BY '\n' | |
; | |
ALTER TABLE testresult ENABLE KEYS; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment