ÅؽºÆ®¸¦ DB¿¡ ³ÖÀ»¶§ Áú¹® µå¸³´Ï´Ù.

   Á¶È¸ 6393   Ãßõ 0    

mysql -u root -p passwd DB_name -e "delete from table_name;

load data infile 'a.txt' into table table_name fields terminated by '\n' lines terminated by '\r\n' (Çʵå1,Çʵå2,Çʵå3);

load data infile 'b.txt' into table table_name fields terminated by '\n' lines terminated by '\r\n' (Çʵå4,Çʵå5,Çʵå6);

load data infile 'c.txt' into table table_name fields terminated by '\n' lines terminated by '\r\n' (Çʵå7,Çʵå8,Çʵå9);

load data infile 'd.txt' into table table_name fields terminated by '\n' lines terminated by '\r\n' (Çʵå10,Çʵå11,Çʵå12);

load data infile 'e.txt' into table table_name fields terminated by '\n\n' lines terminated by '\r' (Çʵå13,Çʵå14,Çʵå15); "



Å×À̺íÀº Çʵå1,Çʵå2Çʵå3......Çʵå14,Çʵå15 ·Î ±¸¼ºµÇ¾îÀÖ½À´Ï´Ù.

À§Àǹæ¹ýÀ¸·Î Çϴϱñ ÇàÀÌ ´Ù ³ª´²Áö´øµ¥...textÆÄÀÏÀº a,b,c,d,e ´Ù¼¸°³Àε¥ text¸¦ DB·Î ³ÖÀ»¶§ ¿©·¯ÆÄÀÏÀ» ÇÑÅ×ÀÌºí¿¡ ³ÖÀ¸¸é¼­ ÇÑÇà¿¡ ÂÒ¾Ç ³Ö´Â ¹æ¹ýÀÌ ¾øÀ»±î¿ä?
서버 모니터링, 라즈베리파이에 관심이 많습니다.
http://www.sproc.co.kr
http://rpi.sproc.co.kr
http://noaa.sproc.co.kr
ªÀº±Û Àϼö·Ï ½ÅÁßÇÏ°Ô.
±è»óÁø 2010-02
À½....Àú¶ó¸é, ±×³É 5°³ ÆÄÀÏÀ» Àӽà Å×À̺í·Î °¢°¢ ³ÖÀº´ÙÀ½¿¡
5°³ Å×À̺íÀ» Á¶ÀÎÇؼ­ ÇϳªÀÇ Å×À̺í·Î ¸¸µé´ø ¾Æ´Ô view¸¦ ¸¸µå´Â ¹æ¹ý´Â ¾î¶³·±Áö¿ä
´Ù¸¸, ¾çÀÌ ¸¹´Ù¸é joinÇؼ­ insertÇϴ°͵µ ºÎÇÏ°¡ Å©±äÇÏÁÒ ^^
¶ÇÇÑ, °¢°¢ 5°³ Å×À̺íÀ» joinÇϱâÀ§ÇÑ Å°°ªµéÀº º°µµ·Î °¡Áö°íÀÖ¾î¾ß °ÚÁÒ

¾Æ´Ï¸é, editer¿¡¼­ Çϳª·Î ÇÕÄ¡´Â ¹æ¹ýµµ ÀÖ±äÇѵ¥...(unixÀÇ ½©·Îµµ °¡´ÉÇÒ·±Áö´Â ¸ð¸£°ÚÁö¸¸) ^^


QnA
Á¦¸ñPage 4024/5680
2014-05   4944998   Á¤ÀºÁØ1
2015-12   1481695   ¹é¸Þ°¡
2010-02   11894   ´Ïº­¸®
2010-02   11956   ³ª³Ê¿ì¸®
2010-02   8712   ½É¹ÙÆ®
2010-02   8660   2CPUÃÖÁÖÈñ
2010-02   23567   »ðÁú¸Å´Ï¾Æ
2010-02   6157   ¼Õ¼®¿ì
2010-02   9049   ²Ù·°¾¾
2010-02   7611   °æ¹ÚÇѽùÎ
2010-02   18526   ±Ç¿ÀÁØ
2010-02   7430   ±è°Ç¿ì
2010-02   12201   À±Ä¡¿­
2010-02   35648   ÀÜÀÎÇѳÑ
2010-02   7083   ¹Î»çÀå
2010-02   7674   psj1050
2010-02   7578   ÀÌ»çÀå
2010-02   6394   °æ¹ÚÇѽùÎ
2010-02   10951   ¿Õ¿ëÇÊ
2010-02   8029   ÃÖ¿ø½ÃÀÍ
2010-02   8601   ³ª³Ê¿ì¸®
2010-02   7429   ¹Ì¼ö¸Ç