How can i use "OracleDbType.Clob" type with PL/SQL table?
Error: "Type "OracleDbType.Clob" cannot be used in PL/SQL table parameter"
Error Type "OracleDbType.Clob" cannot be used in PL/SQL tabl
-
- Devart Team
- Posts: 1710
- Joined: Thu 03 Dec 2009 10:48
Could you please describe the scenario you are trying to perform in more details?
Do you mean passing a PL/SQL table of Oracle LOBs into a stored procedure? Provided that you have declared the corresponding table type (say, 'LOB_TABLETYPE'), this can be done in the following way:
Please tell us if this helps.
Do you mean passing a PL/SQL table of Oracle LOBs into a stored procedure? Provided that you have declared the corresponding table type (say, 'LOB_TABLETYPE'), this can be done in the following way:
Code: Select all
// Register the corresponding table type in your application
OracleType lobtabletype = OracleType.GetObjectType("LOB_TABLETYPE", oracleConnection1);
// Create the table
OracleTable table = new OracleTable(lobtabletype);
// Populate the table
...
// Add this table as a parameter to an OracleCommand object.
oracleCommand1.Parameters.Add(new OracleParameter("p0", OracleDbType.Table));
oracleCommand1.Parameters[0].Value = table;
// Execute the command.
...