Link to home
Start Free TrialLog in
Avatar of 2much4u
2much4u

asked on

ORA-01406 - Fetched column value was truncated

Hello,

I receive this error sometimes when I execute a procedure in a Package in Oracle 10g, the data returned has a CLOB field and some numbers and nvarchar2, could this be the problem?

Thanks.
Avatar of Helena Marková
Helena Marková
Flag of Slovakia image

Maybe this can help (http://download-west.oracle.com/docs/cd/B10501_01/server.920/a96525/e900.htm#1004903):

ORA-01406 fetched column value was truncated

Cause: In a host language program, a FETCH operation was forced to truncate a character string. The program buffer area for this column was not large enough to contain the entire string. The cursor return code from the fetch was +3.

Action: Increase the column buffer area to hold the largest column value or perform other appropriate processing.
Avatar of 2much4u
2much4u

ASKER

I found that answer but I don't understand it, how can I Increase the column buffer area?
It can be a bug, you can find some of them on MetaLink. You can try to drop column and create it.
Maybe someone else can help you more than I have done.
Avatar of 2much4u

ASKER

I'm sorry but that doesn't solve my problem. Thanks.
ASKER CERTIFIED SOLUTION
Avatar of helpneed
helpneed

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of 2much4u

ASKER

hi helpneed,

I think that your comment doesn't solve my problem.

This is my query:

----------------------------------------------------------------------------------------
SELECT   MC_MP.c_id, MC_MP.d_title AS d_title,
         MC_MP.f_dateon, MC_USERS.d_firstname, MC_USERS.d_lastname,
         MC_USERS.d_email, ROWNUM
    FROM MC_MP, MC_USERS
   WHERE (    (MC_USERS.c_id(+) = MC_MP.c_usr_id)
          AND (MC_MP.b_validated = 1)
          AND (MC_MP.c_mic_id = 3)
          AND (MC_MP.c_geo_id = 4597784)
         )
ORDER BY MC_MP.f_dateon DESC;
----------------------------------------------------------------------------------------

If I execute this query from TOAD everything is working fine, but if I execute it from my asp.net page as asimple query or inside a stored procedure it returns ORA-01406 error.

If I remove MC_MP.d_title NVARCHAR2(255) the query works fine from anywhere.

Regards!