可以使簡單,希望你們能幫助和理解甲骨文INSERT SELECT,使用ColdFusion cfqueryparam BLOB類型
<cfsavecontent variable="sContent">
<cfoutput>
here i will have alot of Text will needed to INSERT SELECT into database
</cfoutput>
<cfsavecontent>
<!--- perform insert select --->
<cfquery name="Inserting" datasource="#data#">
insert table1 (content)
select <cfqueryparam value = "#sContent#" CFSQLType = "CF_SQL_BLOB">
from dual
</cfquery>
我之所以使用一滴,因爲我的內容插入到數據庫中是含有大量的文本。 這是插入blob數據的正確方法嗎?
爲什麼你想使用'cfqueryparam'從數據庫表本身插入? – RRK
'插入表1(內容) 從雙'選擇sContent 就夠了吧? – RRK
sContent超過4000個字符,DDL語句得到一個關於不能長時間綁定的錯誤。 – Victor