首页 > Linux操作系统 > Linux操作系统 > 如何操作SQL的TXT字段(转)
2、当大量的插入时,要用 INSERTTEXT 和 UPDATETEXT命令。
以下有例子:
<!-- #INCLUDE VIRTUAL="adovbs.inc" -->
<%
Set MyCon=Server.CreateObject("ADODB.Connection")
Set RS=Server.CreateObject("ADODB.RecordSet")
MyCon.Open "DSN=MyDSN;UID=ME;PWD=Secret"
' Create a SQL Insert String
MySQL="INSERT MyTable (MyTextColumn) VALUES ('Some really long
string')"
' Insert the string into the table named "MyTable"
MyCon.Execute MySQL
' Open the RecordSet with a Static Cursor for a TEXT Column
RS.Open "SELECT MyTextColumn FROM MyTable",MyCon,adOpenStatic
Response.Write(RS("MyTextColumn"))
RS.Close
MyCon.Close
%>
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/10294527/viewspace-124522/ ,如需转载,请注明出处,否则将追究法律责任。