很多時候我們不小心錯誤delete了一下,或者update一下怎麼辦,或者直接把資料庫刪除了,怎麼辦呢,是不是就一定沒有辦法呢?下面讓我來教大家我現學現賣的兩招。當我們不小心刪除表怎麼辦?做之前我們要設定資料庫復原模式: 設定成完整,不要是簡單模式。首先我們建立一個表:插入幾條資料CREATE DATABASE test1 CREATE TABLE A1(ID INT PRIMARY KEY) INSERT INTO dbo.A1 ( ID )VALUES ( 0 )INSERT INTO
declare c SCROLL cursor for select id from Rows100000 order by id descopen cdeclare @Count as integerdeclare @Str as varchar(1024)declare @tmp as intset @Count=80;FETCH absolute 999 from c INTO @tmpif @@FETCH_STATUS = 0 beginset @Count=@Count-1set
做一個加密程式中要想讓用戶端就得到當前服務端的MAC地址,但發現不是那麼簡單。網路建議的方法大多都是用xp_cmdshell執行ipconfig /all,再就是自己寫擴充存貯過程的。但也看到另一種方法http://topic.csdn.net/u/20070910/12/3d9673e0-dfe4-4c6e-aa8a-1c201bc89df2.html使用如下SQL語句可以得到:select *,net_address from master..sysprocesseswhere
Windows Server 2008 R2 En Enterprise 64bitSQL Server 2008 R2 En Enterprise 64bit癥狀:在performance monitor中看不到Sql Server相關的效能計數器解決辦法:Rebuilding the counters: cd c:\windows\system32 lodctr /R cd c:\windows\sysWOW64 lodctr /RResyncing the
【原創源碼】(01):利用事件-委託,實現主-子表單動態顯示,不同功能表列,不同工具列。(類似SQL Server 2000 企業管理器)歡迎大家發表意見(漏洞,效能等)。在部落格園社區以外轉載,請註明作者和出處。謝謝!1,建立工程“EnterpriseManagerWindow”。2,添加主介面“frmMain.cs”(Windows表單)。 在“frmMain.cs”中添加控制項“menuStrip1”(MenuStrip)。
--聲明遊標declare my_cursor cursor for select * from info--刪除遊標資源deallocate my_cursor--開啟遊標,在遊標關閉或刪除前都有效open my_cursor--關閉遊標close my_cursor--聲明局部變數declare @id int,@name varchar(20),@address varchar(20)--定位到指定位置的記錄fetch absolute 56488 from my_cursor into
In earlier posts I already blogged about creating some simple queuing solutions with SQL Server Service Broker. Last week I spend some time actually implementing my research in a customer project and of course ran into two 'interesting' issues.It is
由於Windows 8不支援SQL Server 2008R2.(嚴格來說是通過.NET程式在串連SQL Server 2008R2資料庫是有錯誤) 那我不得不安裝SQL Server 2012.當安裝完畢以後,Azure Storage Emulator啟動不了,提示以下錯誤。The storage emulator had an unexpected error: Unable to start Development Storage..Error details: Failed to