OracleCommand doesn't pick up LONG data types on ExecuteReader

.net plsql oracle11g varchar2

202 просмотра

1 ответ

1375 Репутация автора

I have a select query which retrieves a LONG data type value. SQL Developer execution pulls the data but the OracleCommand doesn't retrieve the value. Instead it returns empty strings even though I know that the values exist in the database.

Is there a way to convert LONG type into VARCHAR2? The values stored in that field are plain text? Also I'm only doing a SELECT on the table.

SELECT REQ_COL FROM TEST_TABLE

I've tried TO_CHAR but that didn't work.

NOTE: This is a vendor database that I have no control over changing the data types of columns. I am only reading the data from the database.

Автор: h-rai Источник Размещён: 15.07.2016 02:12

Ответы (1)


0 плюса

966 Репутация автора

I have encountered this same problem while querying SYS.DBA_TRIGGERS. I have found that setting cmd.InitialLONGFetchSize = -1 solves it.

Автор: shindigo Размещён: 28.07.2016 07:18
Вопросы из категории :
32x32