1. The table doesn't have foreign key.
>> USE DatabaseName;
>> TRUNCATE TABLE TableName;
2. The table has foreign key.
>> USE DatabaseName;
>> DELETE [TableName];
>> DBCC CHECKIDENT('TableName', RESEED, 0);
1. The table doesn't have foreign key.
>> USE DatabaseName;
>> TRUNCATE TABLE TableName;
2. The table has foreign key.
>> USE DatabaseName;
>> DELETE [TableName];
>> DBCC CHECKIDENT('TableName', RESEED, 0);
1. Open "Sql Server Configuration Manager".
step 1) 放入安裝光碟! (光碟機在F槽)
step 2) 開啟命令提示字元(cmd)
step 3) 輸入以下指令!
C:\Users\Administrator> F:
F:\> setup.exe /ACTION=uninstall
step 4) 開始移除SQL Server 2008 R2.
開放SQL Server 2008 Express資料庫的權限供asp .net做連接(我的環境是以IIS與SQL Server為同一台機器時):
step 1. 「開始」
step 2. 「所有程式」
step 3. 「Microsoft SQL Server 2008」
step 4. 「SQL Server Management Studio」
step 5. 連接到您要使用的SQL Server 2008,選擇好「伺服器類型」與「伺服器名稱」後,「連接」
step 6. 點選您要開啟連線的資料庫「Northwind」