½«MySQLÖÐsqlÔËÐнá¹û±£´æµ½Îļþ
ÓÐÁ½ÖÖ·½·¨¡£
·½·¨Ò»£ºÔÚmysql>Ìáʾ·ûÖÐʹÓÃtee
mysql> tee output.txt
Logging to file 'output.txt'
mysql> notee
Outfile disabled.
»òÕß
mysql> \T output.txt
Logging to file 'output.txt'
mysql> \t
Outfile disabled.
Õâ¸öÀàËÆÓÚsqlplusµÄspool¹¦ÄÜ£¬¿ÉÒÔ½«ÃüÁîÐÐÖеĽá¹û±£´æµ½ÍⲿÎļþÖС£Èç¹ûÖ¸¶¨ÒѾ´æÔÚµÄÎļþ£¬Ôò½á¹û»á¸½¼Óµ½ÎļþÖС£
²Î¿¼£ºhttp://www.ningoo.net
·½·¨¶þ£ºÊ¹ÓÃmysqlÃüÁîÐй¤¾ßµÄ--tee²ÎÊý
$mysql --tee=ot.txt
Logging to file 'ot.txt'
mysql>
Õâ»Ø½«ËùÓеÄÊäÈëºÍÊä³öÄÚÈݶ¼¼Ç¼µ½Ö¸¶¨µÄÎļþÖÐ(Ö±µ½exitΪֹ)¡£Èç¹ûÖ¸¶¨ÒѾ´æÔÚµÄÎļþ£¬Ôò½á¹û»á¸½¼Óµ½ÎļþÖС£
Ïà¹ØÎĵµ£º
ÏÈ¿´ÏÂÃæ×¢ÒâÄÚÈÝ
ÕûÕûŪÁËÒ»Ì죬ÖÕÓÚ½â¾öÁËjdbc(mysql-connector-java-5.0.30)ºÍmysqͨÐÅÖÐÎÄÂÒÂëµÄÎÊÌ⣡ÎÒµÄϵͳÊÇ
linux£¨ubuntu£©¡£ÔÚjavaÖУ¨Myeclipse»·¾³£©Ê¹ÓÃhibernateÁ¬½Ómysql¡£´æ´¢Ó¢ÎÄûÎÊÌ⣬д£¨insert
into£©ºÍ¶Á£¨select£©¶¼ÄÜÕýÈ·ÏÔʾ£¬µ«ÊÇÈôÆäÖдøÓÐÖÐÎÄ×Ö·û¾Í³ÉÂÒÂëÁË¡£µ½ÍøÉϲéÕÒÁË°ëÌì×ÊÁ ......
1. Í£µ½ÔËÐеÄmysql: /etc/init.d/mysql stop
2. ʹÓÃskip-grant-tablesÕâ¸öÑ¡ÏîÆô¶¯MySQL£º /usr/bin/mysqld_safe --skip-grant-tables &
3. ÏÖÔÚ¿ÉÒÔ²»ÓÃÃÜÂë½øÈëmysql ÁË¡£
# myql
>   ......
ÕýÔÚ¼ÓÔØÊý¾Ý...
¡¡¡¡1.°´ÐÕÊϱʻÅÅÐò: select * from TableName Order By CustomerName Collate Chinese_PRC_Stroke_ci_as
¡¡¡¡2.Êý¾Ý¿â¼ÓÃÜ: select encrypt(’ÔʼÃÜÂë’) select pwdencrypt(’ÔʼÃÜÂë’) select pwdcompare(’ÔʼÃÜÂë’,’¼ÓÃܺóÃÜÂë’) = 1--Ïàͬ£»·ñÔ ......
SQL SERVER 2005ÒýÈëÁËÔÚµ¥Ò»Á¬½ÓÉ϶Զà»î¶¯½á¹û¼¯£¨Ò²³ÆΪMARS£©»ò¶à¸öÇëÇóµÄÖ§³Ö¡£Í¨¹ýÔÚÓëSQL SERVER 2005µÄÁ¬½ÓÉÏÆôÓÃÕâÒ»ÌØÐÔ£¬µ±´æÔÚÓëSqlconnectionÏà¹ØÁªµÄ¿ª·ÅʽSqlDataReaderʱ£¬Á¬½Ó½«²»»áÖжϡ£¼´Ê¹ÉÐδ¹Ø±Õµ±Ç°´ò¿ªµÄSqlDataReader£¬Ò²ÈÔÈ»Äܹ»ÔÚSqlconnectionÉÏÖ´ÐÐÆäËû²éѯ±ÈÈ磺SELECT£¬UPDATE£¬CREATETABL ......