´æ´¢¹ý³Ì£¬ Éú³ÉSQLÓï¾ä
USE [sfaecrm]
GO
/****** ¶ÔÏó: StoredProcedure [dbo].[proc_insert] ½Å±¾ÈÕÆÚ: 05/29/2009 06:16:07 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER proc [dbo].[proc_insert] (@tablename varchar(256))
as
begin
set nocount on
declare @sqlstr varchar(4000)
declare @sqlstr1 varchar(4000)
declare @sqlstr2 varchar(4000)
select @sqlstr='select ''insert '+@tablename
select @sqlstr1=''
select @sqlstr2=' ('
select @sqlstr1= ' values ( ''+'
select @sqlstr1=@sqlstr1+col+'+'',''+' ,@sqlstr2=@sqlstr2+name +',' from (select case
-- when a.xtype =173 then 'case when '+a.name+' is null then ''NULL'' else '+'convert(varchar('+convert(varchar(4),a.length*2+2)+'),'+a.name +')'+' end'
when a.xtype =127 then 'case when '+a.name+' is null then ''NULL'' else '+'convert(varchar(20),'+a.name +')'+' end'
when a.xtype =104 then 'case when '+a.name+' is null then ''NULL'' else '+'convert(varchar(1),'+a.name +')'+' end'
when a.xtype =175 then 'case when '+a.name+' is null then ''NULL'' else '+'''''''''+'+'replace('+a.name+','''''''','''''''''''')' + '+'''''''''+' end'
when a.xtype =61 then 'case when '+a.name+' is null then ''NULL'' else '+'''''''''+'+'convert(varchar(23),'+a.name +',121)'+ '+'''''''''+' end'
when a.xtype =106 then 'case when '+a.name+' is null then ''NULL'' else '+'convert(varchar(
Ïà¹ØÎĵµ£º
Ëø»úÖÆ
NOLOCKºÍREADPASTµÄÇø±ð¡£
1. ¿ªÆôÒ»¸öÊÂÎñÖ´ÐвåÈëÊý¾ÝµÄ²Ù×÷¡£
BEGIN TRAN t
INSERT INTO Customer
SELECT 'a','a'
2. Ö´ÐÐÒ»Ìõ²éѯÓï¾ä¡£
SELECT * from Customer WITH (NOLOCK)
½á¹ûÖÐÏÔʾ"a"ºÍ"a"¡£µ±1ÖÐÊÂÎñ»Ø¹öºó£¬ÄÇôa½«³ÉΪÔàÊý¾Ý¡£(×¢:1ÖеÄÊÂÎñδÌá½») ¡£NOLOCK±íÃ÷ûÓжÔÊý¾Ý±íÌí¼Ó¹²Ï ......
Microsoft SQL Server 2005 JDBC Driver
1.1
¿ìËÙÃèÊö
ÏÂÔØ Microsoft SQL Server
2005 JDBC Driver 1.1£¬ÕâÊÇÒ»ÖÖ Type 4 JDBC Çý¶¯³ÌÐò£¬¿Éͨ¹ý J2EE£¨Java2 ÆóÒµ°æ£©Öеıê×¼ JDBC
Ó¦ÓóÌÐò±à³Ì½Ó¿Ú (API) ÌṩÊý¾Ý¿âÁ´½Ó¡£
±¾Ò³ÄÚÈÝ
¿ì
ËÙÏêϸÐÅÏ¢
¸Å
Êö
ϵ
ͳҪÇó
˵
Ã÷
Ïà
¹Ø×ÊÔ´
Æä
ËûÓû§ÕýÔÚ ......
ÏÂÃæËùÓеÄSQLÓï¾ä¶¼ÊÇÕë¶Ôǰ׺Ϊwp_µÄ±í£¬Èç¹ûÄãµÄ±íǰ׺²»ÊÇwp_£¬Çë×öÏàÓ¦µÄÐÞ¸Ä
1.¸ü¸Äwordpress°²×°ºÍÊ×Ò³µØÖ·
Èç¹ûÄã¸ü»»ÓòÃû»òÕß°ÑwordpressµÄ°²×°Ä¿Â¼½øÐÐÁ˱䶯¾ÍÐèÒª½øÐÐÐ޸ģ¬
UPDATE wp_options SET option_value = replace(option_value, ‘¾ÉÍøÖ·’, ‘ÐÂÍøÖ·’) WHERE option_name ......
linq to sql ÔÚ²åÈëÖµµÄʱºò»¹ÊǺܷ½±ã¡£ÓÐʱºòÎÒÃÇÐèÒªÔÚ²åÈëÒ»¸öеÄʵÌåÖ®ºóµÃµ½ÄǸöʵÌåµÄÖ÷¼üIDµÄÖµ£¬Õâ¸öIDµ±È»±ØÐëÊÇ×ÔÔö¡£Ò»¶Îʱ¼äÎÒÒ»Ö±ÈÏΪֱ½ÓʹÓÃlinq to sqlµÄ²åÈë»úÖÆÊDz»¿ÉÒÔÔÚ×öµ½µÄ£¬ËùÒÔÖ»ÓÐʹÓô洢¹ý³ÌµÄ£¬¾ßÌå¿ÉÒԲ鿴ÕâÆªÎÄÕ£ºhttp://blog.benhall.me.uk/2008/01/custom-insert-logic-with-linq-to- ......