Error ORA-00932 - expected - got CLOB

Summer of work on request and if necessary, to add comments that have been added to a service call. First time I tried were a failure. So I backed up and worked on an idea to put comments into a temporary table and the rest of the data in another temporary table (which will have filtering in from outside our data systems) and combine them in the evaluation table. This table is analyzed to determine if the call is sent by e-mail to the supervisors.

The comments are a clob collected a variation of a function found here and as long as he stays, temporary table right. When the query tries to move this clob in the clob table corresponding assessment, I get the error ORA-00932 for incompatible data types: expected - got CLOB. (The destination column is a column clob as well.)

The select statement which I use is
 INSERT INTO jc_hc_curent(ad_sec, eid, ad_ts, ag_id, tycod, sub_tycod, udts, xdts, estnum, edirpre, efeanme, efeatyp, edirsuf, eapt, ccity, unit_count, comments) SELECT cu.ad_sec, cu.eid, cu.ad_ts, cu.ag_id, cu.tycod, cu.sub_tycod, cu.udts, cu.xdts, cu.estnum, cu.edirpre, cu.efeanme, cu.efeatyp, cu.edirsuf, cu.eapt, cu.ccity, COUNT(cu.unid), cl.comments FROM hc_curent_temp cu JOIN hc_clob_temp cl ON cu.eid = cl.eid GROUP BY cu.ad_sec, cu.eid, cu.ad_ts, cu.ag_id, cu.tycod, cu.sub_tycod, cu.udts, cu.xdts, cu.estnum, cu.edirpre, cu.efeanme, cu.efeatyp, cu.edirsuf, cu.eapt, cu.ccity, cl.comments; 
The hc_clob_temp.comments is a CLOB, just like the jc_hc_curent.comments in which it happens. the two columns of ad_sec and Eid are NUMBER (10.0) and the rest are VARCHAR2 of different sizes.

So what am I I lack and what I have wrong here...?

I would like to know if there is everything you need to view the problem.

Thanks in advance,
Tony

>
So what am I I lack and what I have wrong here...?
>
To solve the problems of this kind I find useful to remove all superfluous objects and focus on getting to work.

So what happens if you use a query that simply inserts the CLOB column? Does it work? Then add a few more columns, and then even more until you find what does not work.

If necessary to create a table that is a clone of jc_hc_curent but does not index or other unnecessary constraints.

Tags: Database

Similar Questions

  • -Error ORA-00932: inconsistent data types: expected TANK got the NUMBER

    Here is my report query...
    select 
    *
    from   DW_RFA_JOBDATA
    where  FINISH_TIME >= :P1_START_DATE 
    and FINISH_TIME < :P1_END_DATE
         AND RFA_FLAG = (CASE :P1_JOB_CLASSIFICATION WHEN '0' THEN 'LSF'
                                      WHEN '1' THEN 'NON-LSF' 
                                      ELSE RFA_FLAG END)
    The column data type RFA_FLAG is NUMBER(*,0)... I'm view RSA and RSA - not the area of selection, but I get the error ORA-00932: inconsistent data types: expected TANK got the NUMBER >

    I have created a static LOV with LST display 0 return
    Display NON - RSA 1 return...

    Could any body please help me in truble shooting error? How to to convert the data type to number, I have no privileges to make changes to the table...

    Mark you my previous answer as correct? (MOST POINTS!  :))

  • Error ORA-00932: inconsistent data types

    Hello world

    I'm having a small problem with the error ORA-00932: inconsistent data types. The code below is what I'm working on. The error is on line 12:
    "vStmt: = ' select DDH_HOST_NM, DDH_SCHEMA_NR from ' | '. vSchema |'. < table > @ < DB_LINK > '; ». This is because DDH_HOST_NM is a VARCHAR2 and DDH_SCHEMA_NR a number.

    I know what is the error and where it is but I can't work on how to solve this problem. I tried to use to_char on DDH_SCHEMA_NR but that does not.

    Anyone have an idea how I can fix this problem?

    Thank you
    N.S.N.O.

    DECLARE
    vSchema varchar2 (1000);
    vStmt varchar2 (1000);
    Version number (38);
    CURSOR c_schemas IS
    Select "< SCHEMA-NAME >" as "< scheme name >" twice;
    BEGIN
    Open c_schemas;
    LOOP
    SEEK c_schemas INTO vSchema;
    EXIT WHEN c_schemas % NOTFOUND;
    vStmt: = ' select DDH_HOST_NM, DDH_SCHEMA_NR from ' | vSchema |'. < table > @ < DB_LINK > ';
    Run immediately vStmt in version;
    dbms_output.put_line(vSchema||) e '|| Version);
    END LOOP;
    CLOSE C_schemas;
    END;

    The problem is that you choose 2 columns in a single variable?

    vStmt: = ' select DDH_HOST_NM, DDH_SCHEMA_NR from ' | vSchema |'.

    @';
    Run immediately vStmt in version ;

    This must be either

    vStmt: = ' select DDH_SCHEMA_NR from ' | vSchema |'.

    @';
    Run immediately vStmt in version;

    or

    vStmt: = ' select DDH_HOST_NM, DDH_SCHEMA_NR from ' | vSchema |'.

    @';
    Run immediately vStmt in vHostNm, version;

    where vHostNm should set as a variable too.

  • SQL error: ORA-00932: inconsistent data types: expected - was -.

    Hello
    When I am tring to run under sql statement I ORA-00932.

    Select extractvalue ("< rrr > 13 < /rrr > ',' / rrr'") twice;

    How to extract this value?

    Select extractvalue (XMLTYPE ('13'),'/ rrr') twice;

  • ORA-00932: inconsistent data types: expected - got CURSER

    Hi all

    I created a function and tried to run SQL Plus, but I get an error

    ORA-00932: inconsistent data types: expected - got CURSER

    I tried to debug for centuries, but are unable to the root of what could be the problem. I'd appreciate any help or idea people could offer

    The only consolation I take from this is that Oracle have typo in one of their error messages :)



    SQL MORE CODE
    select * FROM TABLE(CAST(tsoraimpdb.QueryAuthorsFunc(116, 1, -1, 1, 0) as tsoraimpdb.ENTITYIDTABLE));
    THE FUNCTION CODE
    CREATE OR REPLACE FUNCTION &HKImpDB_Schema_Name..QueryAuthorsFunc 
    (
    aKGID NUMBER,
      aPageNumber NUMBER,              -- The page interested
      aPageSize NUMBER,                -- Number of records per page
      aOffset NUMBER,                  -- The offset = number of records already got
      aTotalRecord NUMBER          -- Total number of users in the database
    )
    RETURN sys_refcursor
    as
    l_FuncCur sys_refcursor;
    l_TotalRecord NUMBER(10) := aTotalRecord;
    l_Offset NUMBER(10) := aOffset;
    l_PagingTable TEMP_T_TABLE:= TEMP_T_TABLE();
    
    -- paging set up
    l_MinRecordsOnAPge NUMBER(10); --last record on the previous page
    l_MaxRecordsOnAPge NUMBER(10); --last record on the current page
    begin
    DBMS_OUTPUT.PUT_LINE('start');
    select KnowdePos(rownum,p.ID) bulk collect into l_PagingTable
      FROM KnowledgeGene kg
      INNER JOIN HKResource r ON kg.KGOwner = r.ID
      INNER JOIN Person p ON r.PersonID = p.ID
    WHERE kg.kgid = akgid
    ORDER BY p.FirstName + ' ' + p.LastName;
    
    l_TotalRecord := l_PagingTable.count; -- get total records
    DBMS_OUTPUT.PUT_LINE(  l_TotalRecord);
    
    if aPageSize > 0 then
      if aPageNumber <= 0 then
              Raise_application_error(-20003,'Invalid Page Number');
      else
          l_MinRecordsOnAPge := (aPageNumber-1)*aPageSize;
          l_MaxRecordsOnAPge := aPageNumber*aPageSize;
      end if;
    else -- if @PageSize < 0 return all records
        l_Offset := 0;
        l_MinRecordsOnAPge := 0;
        l_MaxRecordsOnAPge := l_TotalRecord;
    END if;
    
    -- return results for the correct page
    open l_FuncCur for
    SELECT pos
      from HKResource r
      INNER JOIN Person p ON r.PersonID = p.ID
      inner join TABLE(CAST(l_PagingTable AS TEMP_T_TABLE)) on pos = p.id
      WHERE KnowdeID > l_MinRecordsOnAPge - l_Offset AND KnowdeID <= l_MaxRecordsOnAPge - l_Offset;
    
    return l_FuncCur;
    EXCEPTION when NO_DATA_FOUND then null;
    end;

    You cannot get the ref cursor in a table like this. Either use a PL/SQL program to extract the lines of ref cursor and display them via dbms_output.put_line (or something) or load the results into a collection and then cast the collection in a table in your select statement.

  • Error: PL/SQL ORA - 00932 data type incompatible when using the value of LONG type

    Hello:

    I use a PL/SQL job script where I use a value of type LONG in a cursor. When I run it, I get:

    Incompatible data type of PL/SQL ORA-00932: expected NUMBER got LONG
    set serveroutput ON SIZE 1000000
    set heading off                
    set feedback off                
    set trimspool off               
    set echo off 
    set term off                   
    set pagesize 0         
    
    SPOOL &so_outfile;
    
    
    
    
    DECLARE
      v_data_file          varchar2(30);
     --   v_sch_code            varchar2(10);
     --   v_instance_name       varchar2(10);
        ws_path            payroll.pybutfl.pybutfl_utl_file_path%TYPE; 
        v_data_line           VARCHAR2 (2000)                              := NULL;
        fhandle_o             UTL_FILE.file_type;
        v_line_count          NUMBER                                       := 0;
        v_selected_count      NUMBER                                       := 0;
        v_error_count         NUMBER                                       := 0;
        v_written_count       NUMBER                                       := 0;
        v_error_text          VARCHAR2 (50)       := ' AMACONF_ERR: Unable to write the line. ';
        v_errm                VARCHAR2 (255);
        v_sqlerrm             VARCHAR2 (255);
        v_payment_type        VARCHAR2(10);
    
    
    CURSOR C1 IS
    select RTRIM
          ( 
            AMRCONF_PIDM_ERR            ||'|'||
            AMRCONF_IDEN_CODE_ERR       ||'|'||
            AMRCONF_ENTRY_DATE_ERR      ||'|'||
            AMRCONF_CONFID_IND_ERR      ||'|'||
           *AMRCONF_COMMENT_ERR        ||'|'||*
            AMRSUBJ_SUBJ_CODE_ERR       ||'|'||
            ERROR_CODE                  ||'|'||
            ERROR_CODE_TEXT                 ) data_line
            from WSUALUMNI.AMRCONF_ERR;
    
    
    
    BEGIN
    
    
    DBMS_OUTPUT.put_line ('Program Generating AMACOMT Mass Update Error File ');
    IF UTL_FILE.is_open (fhandle_o)
        THEN   
       UTL_FILE.fclose (fhandle_o);
    END IF;
    
    /* Name The File Here */
    v_data_file := ('Amaconf_error.txt');
    
    
    
    SELECT RTRIM (pybutfl_utl_file_path)
          INTO ws_path
          FROM payroll.pybutfl;
          
          fhandle_o := UTL_FILE.fopen (ws_path, v_data_file, 'w');
          DBMS_OUTPUT.put_line ('UTLFILE file for this run is: ' || ws_path||'/'||v_data_file);
          v_written_count := 0;   
    
    FOR c1_rec IN C1 LOOP
          BEGIN
            v_selected_count := v_selected_count + 1;
            v_data_line := rtrim(c1_rec.data_line);
            UTL_FILE.put_line (fhandle_o, v_data_line);
            v_written_count := v_written_count + 1;
        EXCEPTION
         WHEN OTHERS
          THEN
           DBMS_OUTPUT.put_line (v_error_text);
           v_error_count := v_error_count + 1;
        END;
    END LOOP;
    
         DBMS_OUTPUT.put_line ('Number of Records Selected: ' || v_selected_count);
         DBMS_OUTPUT.put_line ('Number of Records Written: ' || v_written_count);
    
          IF UTL_FILE.is_open (fhandle_o)
          THEN
             UTL_FILE.fclose (fhandle_o);
          END IF;
    
    END;
    /
    
    SPOOL OFF;
    If I comment on the ' AMRCONF_COMMENT_ERR |'| ' | ' line, then the script works fine. The table has been created as:
    Create Table WSUALUMNI.AMRCONF_ERR
    (
        AMRCONF_PIDM_ERR             NUMBER (8)    NOT NULL,
        AMRCONF_IDEN_CODE_ERR        VARCHAR2(5)   NOT NULL,
        AMRCONF_ENTRY_DATE_ERR       DATE          NOT NULL,
        AMRCONF_CONFID_IND_ERR       VARCHAR2(1),
        AMRCONF_COMMENT_ERR          LONG,          
        AMRSUBJ_SUBJ_CODE_ERR        VARCHAR2(5)   NOT NULL,
        ERROR_CODE                   VARCHAR2(12)  NOT NULL,
        ERROR_CODE_TEXT              VARCHAR2(50)  NOT NULL
    ); 
    I don't understand what the problem here is in the script.

    Hello
    Feew suggestions
    (1) LONG is an obsolete type so if possible start working on this column change
    (2) CLOB will be your favorite type of data on long.
    (3) you cannot use RTRIM on long.

    Here's a very quick example

    drop table h
    create table h (x long,y varchar2(100))
    select rtrim(x) from h
    select rtrim(y) from h
    

    Solution:
    [http://www.oracle.com/technology/oramag/code/tips2003/052503.html]

    need to better implement the clob data type and

    drop table h
    create table h (x clob,y varchar2(100))
    select  dbms_lob.substr( x, 4000, 1 ) from h
    select rtrim(y) from h
    

    See you soon!
    Bobin

  • ORA-00932: inconsistent data types: expected DATE receipt NUMBER to call OIC OCIStmtExecute OBIEE 11g

    Hi friends,

    I get this error: ORA-00932: inconsistent data types: expected DATE got the NUMBER to the call of the OIC OCIStmtExecute when I'm putting the filter on the date column condition.

    "Sun Time". " Day' < = cast (MAX ("Sun time" "." ")) Date day")) and"Sun Time ". "' Day ' > = TIMESTAMPADD (SQL_TSI_MONTH,-1, cast (MAX ("Sun time".) "Day") as date). "

    I sank the date max, but if I get the above error. I think max (date) creates the problem.

    Please suggest your opinion on that.

    Thank you.

    Thank you for your suggestions.

    I used the variable, and it helped.

    "Sun Time". " Date' <= valueof(maxdate)="" and="" "dim-time"."date"="">= TIMESTAMPADD (SQL_TSI_MONTH-1, VALUEOF (Maxdate))

  • pl/sql appellant java class member function obtains ora-00932 in 11g.

    Call a member function of class of java from a pl/sql script, I get an error ora-00932.

    ORA-00932: inconsistent data types: waiting for an IN argument in position 1 which is an instance of an O

    convertible to an instance of a user defined class Java got a type of Oracle that could not be converted

    The code works fine when the java function is declared static.   However, since there could be thousands of users hitting the function at the same time and there is no instance of the object, I wasn't sure if it would be a matter of how oracle manages memory for each user in a session, if it would not be a problem, I can go forward with this approach.   However, I have greatly simplified this for an example that reproduces the problem.

    Create the oracle type:

    CREATE OR REPLACE TYPE MyObject AS OBJECT

    (

    col1Data VARCHAR2 (10),

    MEMBER FUNCTION createData

    RETURN VARCHAR2 AS LANGUAGE JAVA

    NAME "java.lang.String return MyObject.createData ().

    );

    Java code:

    CREATE OR REPLACE AND FIX JAVA SOURCE NAMED 'MyObject' AS

    import java. IO;

    public class MyObject

    {

    private String col1Data;

    public void createData)

    {

    System.out.println ("col1:" + col1Data);

    }

    }

    Java function call vai pl/sql function:

    FUNCTION to CREATE or REPLACE fn_myobject

    (col1 IN varchar2)

    RETURN VARCHAR2

    AS

    p_rc varchar2 (100);

    myObj MyObject;

    BEGIN

    myObj: = new MyObject (col1);

    p_rc: = myObj.createData ();   -This line gets an error 00932

    RETURN p_rc;

    END;

    /

    And finally, the script from sqlplus to test:

    Set serverout

    call dbms_java.set_output (50);

    Set line 120

    declare

    VARCHAR2 (64) RC: = ";

    R1 varchar2 (64): = 'abc ';

    Start

    RC: = fn_myobject (r1);

    end;

    /

    I tried all sorts of things without success.   Any ideas on this would be most appreciated.  It is once again, 11g.

    Thank you.

    MarkF says:

    If you go back to the example code I posted, it is mapping a java class oracle object.

    No, it isn't.

    Your example simply sets an Oracle object type whose member createData function is implemented in Java.

    The fact that the implementing class has the same name does not have a direct mapping between the class and the type of Oracle.

    The important part to read and understand in the link I posted is:

    A call specification outlines the top level of an Oracle database Java method entry point. So, you can publish only public static methods.

    However, there is an exception. You can publish instance methods as members of an SQL object type methods.

    You are in the first case.

    To be in the exceptional cases and be able to publish instance methods, the Java class must implement SQLData.

    See the latest example here:

    https://docs.Oracle.com/database/121/JJDEV/chsix.htm#JJDEV13273

    Adapted to your example:

    CREATE OR REPLACE AND compile JAVA SOURCE NAMED "MyObject" AS
    import java.sql.*;
    
    public class MyClass implements SQLData
    {
      // Implement the attributes and operations for this type.
      private String col1Data;
    
      public String createData ()
      {
          System.out.println ("col1: " + col1Data);
          return col1Data;
      }
    
      // Implement SQLData interface.
      String sql_type;
    
      public String getSQLTypeName() throws SQLException
      {
        return sql_type;
      }
    
      public void readSQL(SQLInput stream, String typeName) throws SQLException
      {
        sql_type = typeName;
        col1Data = stream.readString();
      }
    
      public void writeSQL(SQLOutput stream) throws SQLException
      {
        stream.writeString(col1Data);
      }
    }
    /
    
    CREATE OR REPLACE TYPE MyObject AS OBJECT
    (
      col1Data  VARCHAR2(10),
      MEMBER FUNCTION createData
              RETURN VARCHAR2 AS LANGUAGE JAVA
        NAME 'MyClass.createData() return java.lang.String'
    );
    /
    

    Test:

    SQL> exec dbms_java.set_output(1000)
    
    PL/SQL procedure successfully completed.
    
    SQL> set serverout on
    SQL>
    SQL> select MyObject('ABC').createData() from dual;
    
    MYOBJECT('ABC').CREATEDATA()
    --------------------------------------------------------------------------------
    ABC
    
    col1: ABC
    
  • ORA-00932: inconsistent data types: expected BLOB, CLOB had TANK

    Hello
    When exporting with the EXP utility, I have the following error:
    . exporting private type synonyms
    . exporting object type definitions
    . exporting system procedural objects and actions
    . exporting pre-schema procedural objects and actions
    . exporting cluster definitions
    EXP-00056: ORACLE error 932 encountered
    ORA-00932: inconsistent datatypes: expected BLOB, CLOB got CHAR
    My question is:
    what is the schema? Can there invalid objects by preventing him from EXP (see the Note 339938.1 on metalink).

    Thank you.

    A way perhaps to query dba_feature_usage_statistics that shows in use and query dba_registry features which also shows the features installed.

    HTH - Mark D Powell.

  • ADF: ORA-00932: inconsistent data types: expected - got TANK

    I get this error while casting. ORA-00932: inconsistent data types: expected - got TANK
    I had departments such as front number... .but must be able to take over the alpha characters... so I changed my Bind Variables in my model: Array string (decimal Big)

    This is the error:

    where dept in (SELECT * FROM TABLE (CAST (: depts AS glc.))) NUMTABTYPE)))

    How can I solve this?... probably need to delete interpreters from here... .but how I it... any help is appreciated.

    I also Type:
    create or replace TYPE NUMTABTYPE in the TABLE to the number; (also I tried to change this option for create or replace TYPE NUMTABTYPE in the TABLE to the varchar2 (200);)

    I changed the table to a string and

    [oracle.jbo.domain.Number]"with java.lang.String to support also supports departments alpha characters... dept can be AB123 (string) or 3344 (number only)

    The entire query
    ============
    SELECT * FROM (SELECT
    NVL ("DEPT", "Grand Total") as DEPT,
    PERIOD_YEAR,
    In summary (round ("Jan real CDA")) 'real Jan CDA. "
    In summary (round ("Feb real CDA")) 'Feb CDA real. "
    In summary (round ("Mar real CDA")) 'Mar CDA real. "
    In summary (round ("Apr CDA")) real 'Real CDA Apr',
    In summary (round ("peut CDA")) real "can actual CDA."
    In summary (round ("Jun real CDA")) 'Jun CDA real. "
    sum (round ("Jul real CDA")) 'Real CDA Jul',
    In summary (round ('Aug real CDA")) 'Aug CDA real."
    In summary (round ("Ms real CDA")) 'Ms CDA real. "
    In summary (round ("Oct real CDA")) 'Oct CDA real. "
    In summary (round ("Nov real CDA")) 'real CDA Nov. "
    In summary (round ('Dec real CDA")) 'Dec CDA real."
    In summary (round ("Jan CDA Budget")) 'Budget of CDA Jan. "
    In summary (round ("Feb CDA Budget")) 'Feb CDA Budget. "
    In summary (round ("Mar CDA Budget")) 'Mar CDA Budget. "
    In summary (round ("Apr CDA Budget")) 'Apr CDA Budget. "
    In summary (round ("can CDA Budget")) 'Budget of CDA can. "
    In summary (round ("Jun CDA Budget")) 'Jun CDA Budget. "
    In summary (round ("Jul CDA Budget")) 'Jul CDA Budget. "
    In summary (round ("Aug CDA Budget")) 'Aug CDA Budget. "
    In summary (round ("Sep CDA Budget")) 'Ms CDA Budget. "
    In summary (round ("Oct CDA Budget")) 'Oct CDA Budget. "
    In summary (round ("Nov CDA Budget")) 'Nov CDA Budget. "
    In summary (round ("CDA Budget Dec")) 'Dec CDA Budget. "
    In summary (round ('Total Budget uncorrected')) "Annual_Budget."
    In summary (round ("Total Budget")) "Revised_BUDGET."
    sum (round ("real CDA")) "YTD_ACTUALS."
    In summary (round ("Jan Actual")) "Jan_ACTUAL."
    In summary (round ('Jan Budget')) "Jan_BUDGET."
    In summary (round ("Jan Actual")) "JanYTDACTUAL."
    In summary (round ('Jan Budget')) "JanYTDBUDGET."
    sum (round ("real Feb")) "Feb_ACTUAL."
    In summary (round ('Feb Budget')) "Feb_BUDGET."
    sum (round ("real Mar")) "Mar_ACTUAL."
    In summary (round ("Budget de Mar")) "Mar_BUDGET."
    sum (round ("real Apr")) "Apr_ACTUAL."
    In summary (round ("Apr Budget")) "Apr_BUDGET."
    In summary (round ("can real")) "May_ACTUAL."
    In summary (round ("Budget can")) "May_BUDGET."
    sum (round ("real Jun")) "Jun_ACTUAL."
    In summary (round ('Jun Budget')) "Jun_BUDGET."
    sum (round ("real Jul")) "Jul_ACTUAL."
    In summary (round ('Jul Budget')) "Jul_BUDGET."
    sum (round ("real Aug")) "Aug_ACTUAL."
    In summary (round ('Aug Budget')) "Aug_BUDGET."
    sum (round ("real Sep")) "Sep_ACTUAL."
    In summary (round ('Ms Budget')) "Sep_BUDGET."
    sum (round ("real Oct")) "Oct_ACTUAL."
    In summary (round ('Oct Budget')) "Oct_BUDGET."
    sum (round ("real Nov")) "Nov_ACTUAL."
    In summary (round ('Nov Budget')) "Nov_BUDGET."
    sum (round ("real Dec")) "Dec_ACTUAL."
    In summary (round ("Dec Budget")) "Dec_BUDGET."
    sum (round ("Jan Budget" + "Jan Budget Adj")) "Jan_Budget_Orig."
    sum (round ("Budget Feb" + "Feb Budget Adj")) "Feb_Budget_Orig."
    sum (round ("Mar Budget" + "Mar Budget Adj")) "Mar_Budget_Orig."
    sum (round ("Apr Budget" + "After Budget Adj")) "Apr_Budget_Orig."
    sum (round ("Budget can" + "Can Budget Adj")) "May_Budget_Orig."
    sum (round ("Jun Budget" + "Jun Budget Adj")) "Jun_Budget_Orig."
    sum (round ("Jul Budget" + "Jul Budget Adj")) "Jul_Budget_Orig."
    sum (round ("Aug Budget" + "August Budget Adj")) "Aug_Budget_Orig."
    sum (round ("Ms Budget" + "Ms Budget Adj")) "Sep_Budget_Orig."
    sum (round ("Oct Budget" + "Oct Budget Adj")) "Oct_Budget_Orig."
    sum (round ("Budget Nov" + "Nov Budget Adj")) "Nov_Budget_Orig."
    sum (round ('Dec Budget '' + '' Dec Budget Adj")) 'Dec_Budget_Orig '.
    GLC. GLC_BUDANAL_ACT_BUD_ADJ_VAR_V mainanal
    where dept in (SELECT * FROM TABLE (CAST (: depts AS glc.))) NUMTABTYPE))) and period_year =: year and substr ("OBJECT", 1, 3). =: excludeObject
    and mainanal. FERC not like 4% '
    Group by the Department, period_year) QRSLT ORDER BY DEPT

    As you say your table does not number but the strings. If you must change the table in an array of strings.

    Timo

  • ORA-00932: inconsistent data types: expected - got NUMBER

    Hello
    in 10g R2:
    SQL> select count(*) from sysman.MGMT_METRICS_RAW;
    select count(*) from sysman.MGMT_METRICS_RAW
                                *
    ERROR at line 1:
    ORA-01578: ORACLE data block corrupted (file # 3, block # 27080)
    ORA-01110: data file 3: 'D:\BASE\DB\DATA\SYSAUX01.DBF'
    SQL> select * from sysman.MGMT_METRICS_RAW where rowid=27080;
    select * from sysman.MGMT_METRICS_RAW where rowid=27080
                                                     *
    ERROR at line 1:
    ORA-00932: inconsistent datatypes: expected - got NUMBER
    How to convert the rowid to be accepted in this query?
    Thank you

    This isn't the rowid. This is the block #.

  • ORA-00932: inconsistent data types: expected - was -.

    DECLARE
    STR VARCHAR2(2000):='<SerachVal>1234</SerachVal>';
    L_OUT VARCHAR2(1000);
    BEGIN
    SELECT EXTRACTVALUE(STR,'/SerachVal') INTO L_OUT FROM DUAL;
    DBMS_OUTPUT.PUT_LINE(L_OUT);
    END;
    
    
    error:
    
    PL/SQL: ORA-00932: inconsistent datatypes: expected - got -
    PL/SQL: SQL Statement ignored
    06550. 00000 -  "line %s, column %s:\n%s"
    *Cause:    Usually a PL/SQL compilation error.
    SQL> set serverout on
    SQL> DECLARE
      STR   VARCHAR2(2000):='1234';
      L_OUT VARCHAR2(1000);
    BEGIN
      SELECT EXTRACTVALUE(XMLTYPE(STR),'/SerachVal') INTO L_OUT FROM DUAL;
      DBMS_OUTPUT.PUT_LINE(L_OUT);
    END;  2    3    4    5    6    7
      8  /
    1234
    
    PL/SQL procedure successfully completed.
    
    SQL> 
    
  • Why I get this error? ORA-00932: inconsistent data types

    It's my stored procedure, I created to select only the exact amount of records per page to a GridView (for ASP.NET):
    CREATE OR REPLACE
    PROCEDURE SELECT_COMMAND
    (pTable IN VARCHAR2
    , pFields IN VARCHAR2
    , pSortField IN VARCHAR2
    , pPageIndex IN NUMBER
    , pTotalRecs IN NUMBER
    , pResultSet OUT SYS_REFCURSOR
    ) AS
    BEGIN  
      EXECUTE IMMEDIATE 
      'SELECT ' || pFields || ' FROM '
      || '(SELECT '|| pFields ||', ROW_NUMBER() OVER(ORDER BY '|| pSortField ||') ROW_NUM '
      || 'FROM '|| pTable ||') WHERE ROW_NUM BETWEEN '|| to_char(pPageIndex*pTotalRecs) ||' AND '
      || to_char((pPageIndex+1)*pTotalRecs)    
      INTO pResultSet;
      -- Plus 1 to our index because GridView is a zeroth index collection
    END SELECT_COMMAND;
    I then do a test case with the following parameters:
    declare
    p_test sys_refcursor;
    begin
    select_command('v_sig_devices', '"JOB", "LINE"', '"DEVICE_ID"', 0, 10, p_test);
    end;
    But I get the following error:

    >
    Error report: ORA-00932: inconsistent data types: expected - was -.
    ORA-06512: at the 'SIM '. SELECT_COMMAND', line 10
    ORA-06512: at line 4 level
    00932 00000 - ' incompatible data types: wait %s %s got. "
    >

    At first Oracle gave me an error because the figures were not a string. Can I convert it to a string (with to_char) and Oracle is still not satisfied! Any ideas as to why this is happening?

    Thanks for any help you can provide.

    Suppose you want sth. as

    ...
    OPEN pResultSet FOR 'SELECT ' || pFields || ' FROM '
      || '(SELECT '|| pFields ||', ROW_NUMBER() OVER(ORDER BY '|| pSortField ||') ROW_NUM '
      || 'FROM '|| pTable ||') WHERE ROW_NUM BETWEEN '|| to_char(pPageIndex*pTotalRecs) ||' AND '
      || to_char((pPageIndex+1)*pTotalRecs)  ;
    ...
    
  • While the BLOB conversion of type CLOB error - ORA-06502: PL/SQL: digital error or value

    Passing data from attachment of DB (Blob data Type) after the CLOB data type conversion, giving the error "ORA-06502: PL/SQL: digital error or value" in the PL/SQL package. If the BLOB size 32K > it will give another error works great my procedure.

    For example, I enclose my code here.

    function get_base64 (p_blob_in in blob) return clob is

    CLOB v_clob;

    CLOB v_result;

    whole v_offset;

    v_chunk_size PLS_INTEGER: = 12288;

    v_buffer_varchar varchar2 (32767).

    v_buffer_raw raw (32767).

    Start

    fnd_file.put_line (fnd_file.log, 'here');

    If p_blob_in is null then

    Returns a null value.

    end if;

    DBMS_LOB.CREATETEMPORARY (v_clob, true);

    fnd_file.put_line (fnd_file.log, 'here1');

    v_offset: = 1;

    fnd_file.put_line (fnd_file.log, 'Loop value'-| ceil (DBMS_LOB.) GetLength (p_blob_in) / v_chunk_size));

    because me in 1... ceil (DBMS_LOB. GetLength (p_blob_in) / v_chunk_size) loop

    DBMS_LOB. Read (p_blob_in, v_chunk_size, v_offset, v_buffer_raw);

    v_buffer_raw: = utl_encode.base64_encode (v_buffer_raw);

    v_buffer_varchar: = utl_raw.cast_to_varchar2 (v_buffer_raw);

    DBMS_LOB. WriteAppend (v_clob, length (v_buffer_varchar), v_buffer_varchar);

    v_offset: = v_offset + v_chunk_size;

    end loop;

    fnd_file.put_line (fnd_file.log, 'Out of the loop');

    v_result: = v_clob;

    fnd_file.put_line (fnd_file.log, 'V_result length' - |) DBMS_LOB. GetLength (v_result));

    fnd_file.put_line (fnd_file.log, 'V_result' - | v_result);

    DBMS_LOB.freeTemporary (v_clob);

    Return v_result;

    exception

    while others then

    fnd_file.put_line (fnd_file.log, 'Error based on the encode_base64' - |) SQLERRM);

    Returns a null value.

    end;

    In my main program I call this function as below:

    Main proceedings...

    l_return_clob CLOB.

    Begin

    ....

    l_return_clob: = get_base64 (p_blob_in);

    -In returning it gives error - ORA-06502: PL/SQL: digital error or value

    end;

    Then, please mark the thread ANSWERED.

  • Can't export an internal error has occurred: bad argument #1 to 'find' (string expected, got the draw)

    Cannot export

    An internal error has occurred: bad argument #1 to 'find' (string expected, got the draw)

    No one can tell you anything. Your track is not the least useful info like what is exported from which program on which system and so on.

    Mylenium

Maybe you are looking for