D
dennyshao001
Unregistered / Unconfirmed
GUEST, unregistred user!
碰到个奇怪的问题,我用ADOQuery添加数据时,如下<br>aloneq.AppendRecord([ip,level,csname,oid,mibtype,value,finterface,now]);<br><br>我在SQL事件探察器中发现有时候会出现<br>exec sp_executesql N'INSERT INTO "EPON".."realvartb" ("ip","address" VALUES (@P1,@P2)', N'@P1 nvarchar(13),@P2 nvarchar(1)', N'192.168.1.156', N'0'<br><br><br>正确的添加语句应该为<br>exec sp_executesql N'INSERT INTO "EPON".."realvartb" ("ip","address","csname","oid","mibtype","value","interface","mondate" VALUES (@P1,@P2,@P3,@P4,@P5,@P6,@P7,@P8)', N'@P1 nvarchar(13),@P2 nvarchar(1),@P3 nvarchar(13),@P4 nvarchar(31),@P5 nvarchar(1),@P6 nvarchar(17),@P7 nvarchar(1),@P8 datetime', N'192.168.1.156', N'0', N'oltMACAddress', N'1.3.6.1.4.1.14590.1.1.2.1.1.2.0', N'1', N'00-00-00-00-00-00', N'', '10 12 2007 2:38:05:000PM'<br><br>为什么会有时候出现那种不正确的语句那?