SQLÓï¾ä²éѯÊÇ·ñΪ¿Õ =null¼°null
a b c d
980515 ¾«頂Æó業ÓÐÏÞ¹«Ë¾ 簡¼ÒºÀ NULL
980514 È«ÐÀľ業ÓÐÏÞ¹«Ë¾ NULL 123
980514 Ѹ億¿Æ¼¼¹É·ÝÓÐÏÞ¹«Ë¾ 簡·ê¿£ NULL
980515 聖Ô½國際Æó業ÓÐÏÞ¹«Ë¾ NULL 111
±í½á¹¹ÈçÉÏËùʾ£¬Òª²éѯCÁÐΪ¿ÕµÄ¼Ç¼µÄ£Ó£Ñ£ÌÓï¾ä²»ÊÇselect * from table where c=null; »òÕß select * from table where c=’’; ¶øÓ¦µ±ÊÇ select * from table where c is null; Ïà·´µØÒª²éѯ²»Îª¿ÕµÄÔòÓ¦µ±ÊÇ select * from talbe where c<>’’; »òÕß select * from table where c is not null; ×¢Ò⣺²»ÊÇnot is nullŶ¡£
Ïà¹ØÎĵµ£º
ttp.bat
sqlplus user/pwd@TTPPANADB @ttp
ttp.sql
drop user ttpuser cascade;
CREATE USER TTPUSER IDENTIFIED BY e0ttpuser DEFAULT TABLESPACE avcrt001 TEMPORARY TABLESPACE TEMP PROFILE DEFAULT;
GRANT CONNECT TO TTPUSER;
GRANT ALTER SESSION TO TTPUSER;
GRANT CREATE DATABASE LINK TO TTPUSER;
GRANT ......
protected void Button1_Click(object sender, EventArgs e)
{
SqlConnection conn= new SqlConnection("server=(local);database=colorring;uid=sa;pwd=;");
conn.Open();
string sqlstr = "exec master..xp_cmdshell 'bcp \"select top 100 * from master..aps\" queryout c:\\aa ......
SQL Server µ¼ÈëºÍµ¼³öÏòµ¼ÌṩÁËÉú³É Microsoft SQL Server 2005 Integration Services (SSIS) °ü×î¼òµ¥µÄ·½·¨¡£SQL Server µ¼ÈëºÍµ¼³öÏòµ¼¿ÉÒÔ·ÃÎʸ÷ÖÖÊý¾ÝÔ´¡£¿ÉÒÔÏòÏÂÁÐÔ´¸´ÖÆÊý¾Ý»ò´ÓÆäÖи´ÖÆÊý¾Ý£º
· Microsoft SQL Server
· Æ½ÃæÎļþ
· Microsoft Off ......
/******* µ¼³öµ½excel
EXEC master..xp_cmdshell ’bcp SettleDB.dbo.shanghu out c:\temp1.xls -c -q -S"GNETDATA/GNETDATA" -U"sa" -P""’
/*********** µ¼ÈëExcel
SELECT *
from OpenDataSource( ’Microsoft.Jet.OLEDB.4.0’,
’Data Source="c:\test.xls";User ......
SQL Server 2005±¨ÁËÕâô¸ö´í£ºCannot resolve the collation conflict between "Chinese_PRC_CI_AS" and "Chinese_PRC_90_CI_AS" in the like operation.
ºó²éÖ¤£¬ÕâÊÇÓÉÓÚÁ½¸ö×ö±È½ÏµÄÁеÄÅÅÐò·½Ê½²»Í¬£¬ÖÐÎÄÓкܶàÖÖÅÅÐò·½Ê½£¬¶ÔÓ¦ÈçÏ£º
ÖÐÎÄ£¨Ïã¸ÛÌØ±ðÐÐÕþÇø£©
Chinese_Hong_Kong_Stroke_90_CI_AS
ÖÐÎÄ£¨Ïã¸ÛÌØ±ðÐ ......