摘要:
可以先在SQL写一个函数:CodeCode highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->CREATEFUNCTION[dbo].[ExclusionAccount](@Accountnvarchar(30))RETURNSbitASBEGINDECLARE@ResultbitIF@AccountIN('administrator','admin','system','sys',' 阅读全文
摘要:
SQL循环插入记录,需要用到WHILE来实现,比如要插入L1至L50到表中。CodeCode highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->DECLARE@iintSET@i=1WHILE@i<44BEGININSERTINTO[ProductionLines]([ProductionLinesName])VALUES('L'+CONVERT(nvarchar,@i))SET@i=@i+1END如果需要插入如下数据,MA001至 阅读全文
摘要:
Server Error in '/' Application.A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provid 阅读全文