我试图将file.txt的全文内容插入到CLOB列中!
Connection^ DB = gcnew Connection();
OracleConnection^ Ocnn=DB->getOracleConnectionObject();
int number = 0;
try {
// here >>
OracleCommand^ c = gcnew OracleCommand("INSERT INTO PANDA.PAGE(SITE_ID, URL, SOURCE) VALUES('40', 'www.site.com', Read_Whole_File('C://Users/farmehr/Desktop/', 'file.txt'))", Ocnn);
number = c->ExecuteNonQuery();
}
catch (Exception^ eOra) {
Console::WriteLine(eOra->Message + "Exception Caught");
throw eOra;
}
我想知道有没有办法直接将文件插入数据库? (代码中的函数类似于Read_Whole_File())