*Urgent* incomplete or malformed

Hi Fellows,
I am writing a trigger with a boolean variable in declare section. I am getting the following error
CREATE OR REPLACE TRIGGER gt_e1c10c20c31_T03
Before Insert or Update on gt_e1c10c20c31 For Each Row
DECLARE
lv_validate_recid BOOLEAN;
BEGIN
IF INSERTING THEN
lv_validate_recid :=('GT_E1C10C20C31', :new.GT_COVERAGES_RECID);
IF NOT lv_validate_recid THEN
RAISE_APPLICATION_ERROR(-20107,'Invalid effective / expiry date ');
END IF;
END IF;
END;
Error:
5/10 PL/SQL: Statement ignored
5/31 PLS-00320: the declaration of the type of this expression is
incomplete or malformed
Will anybody let me know what is wrong in it???
I appreciate sooner respose.
Thanks
Ghulam Mustafa Butt

BOOLEANs must be an expression that evaluates to TRUE or FALSE.
SQL> DECLARE
  2    lb BOOLEAN;
  3  BEGIN
  4    lb := (1=2);
  5    IF lb THEN
  6       dbms_output.put_line ('It''s true!');
  7    ELSE
  8       dbms_output.put_line ('It''s a dirty lie!');
  9    END IF;
10  END;
11  /
It's a dirty lie!
PL/SQL procedure successfully completed.
SQL> Your code does not do this.
Cheers, APC

Similar Messages

  • PLS-00320: the declaration of the type of this expression is incomplete or malformed

    hello my friend please help
    I have this Error in PL /SQL procedure
    ORA-06550: line 6, column 12:
    PLS-00320: the declaration of the type of this expression is incomplete or malformed
    ORA-06550: line 6, column 12:
    PL/SQL: Item ignored
    where this is my procedure
    CREATE OR REPLACE PROCEDURE MOAMALAT."IO_EMP_REP"
    P_FROMDATE IN NUMBER,
    P_TODATE IN NUMBER,
    P_EMPID IN NUMBER,
    RCT1 OUT GLOBALPKG.RCT1
    AS
    BEGIN
    OPEN RCT1 FOR
    SELECT COUNT (I.CORRESPONDENCENUMBER) cont,
    EMP.FULLNAME empname,
    D.DEPARTMENTNAME deptname
    FROM MOAMALAT.IO_INCOMING i,
    MOAMALAT.IO_EMPLOYEES emp,
    MOAMALAT.IO_DEPARTMENTS d
    WHERE I.RECEIVEDBY = (SELECT EM.USERID
    FROM MOAMALAT.IO_EMPLOYEES em
    WHERE EM.EMPLOYEEID = P_EMPID)
    AND I.RECEIVEDBY LIKE EMP.USERID
    --and EMP.DEPARTMENTID=1900
    AND I.RECEIVEDBYDEPARTMENTID = D.DEPARTMENTID
    AND I.CORRESPONDENCEDATE BETWEEN P_FROMDATE AND P_TODATE
    GROUP BY EMP.FULLNAME, D.DEPARTMENTNAME
    UNION ALL
    SELECT COUNT (o.CORRESPONDENCENUMBER) cont,
    EMP.FULLNAME empname,
    D.DEPARTMENTNAME deptname
    FROM MOAMALAT.IO_OUTGOING o,
    MOAMALAT.IO_EMPLOYEES emp,
    MOAMALAT.IO_DEPARTMENTS d
    WHERE O.SENTBY = (SELECT EM.USERID
    FROM MOAMALAT.IO_EMPLOYEES em
    WHERE EM.EMPLOYEEID = P_EMPID)
    AND EMP.USERID LIKE EMP.USERID
    AND EMP.USERID LIKE O.SENTBY
    AND O.SENTBYDEPARTMENTID = D.DEPARTMENTID
    AND O.CORRESPONDENCEDATE BETWEEN P_FROMDATE AND P_TODATE
    GROUP BY EMP.FULLNAME, D.DEPARTMENTNAME;
    END;

    aymanhamdan01 wrote:
    thanks for replay
    sb92075
    this line 6:  RCT1 OUT GLOBALPKG.RCT1
    does Oracle (& you) know what datatype GLOBALPKG.RCT1 is?

  • Error:expression is incomplete or malformed

    when i execute below coding, im getting an error
    error:the declaration of the type of this expression is incomplete or malformed
    declare
    b varchar2(4000);
    c varchar2(4000);
    a varchar2(100);
    begin
    a:='scott';
    IF APEX_COLLECTION.COLLECTION_EXISTS('BOOK') THEN
    APEX_COLLECTION.DELETE_COLLECTION('BOOK');
    END IF;
    apex_collection.create_collection(p_collection_name=>'BOOK');
    apex_collection.add_member(
    p_collection_name=>'BOOK',
    p_c001 => 1,
    p_c002 => 2);
    select c001,c002 into b,c from apex_collections
    where collection_name ='BOOK';
    htp.prn(b);
    execute immediate 'insert into' ||a|| '.mac values(:b, :c)' using (b, c);-------------*error*
    end;how to resolve is?
    Thanks and regards
    skud.
    Edited by: skud on 10-Apr-2011 23:46

    Hi,
    Try
    DECLARE
      b VARCHAR2(4000);
      c VARCHAR2(4000);
      a VARCHAR2(100);
    BEGIN
      a :='scott';
      IF APEX_COLLECTION.COLLECTION_EXISTS('BOOK') THEN
        APEX_COLLECTION.DELETE_COLLECTION('BOOK');
      END IF;
      apex_collection.create_collection(p_collection_name=>'BOOK');
      apex_collection.add_member(
        p_collection_name => 'BOOK',
        p_c001 => 1,
        p_c002 => 2
      SELECT c001,
        c002
      INTO b,
        c
      FROM apex_collections
      WHERE collection_name ='BOOK'
      htp.prn(b);
      EXECUTE IMMEDIATE 'INSERT INTO ' || a || '.mac(col1,col2) VALUES(' || b || ',' || c || ')';
    END;Change col1 and col2 according your table column name
    Regards,
    Jari
    Edited by: jarola on Apr 11, 2011 10:07 AM
    Edited by: jarola on Apr 11, 2011 10:10 AM
    And this should work also
    DECLARE
      b VARCHAR2(4000);
      c VARCHAR2(4000);
      a VARCHAR2(100);
    BEGIN
      a:='scott';
      IF APEX_COLLECTION.COLLECTION_EXISTS('BOOK') THEN
        APEX_COLLECTION.DELETE_COLLECTION('BOOK');
      END IF;
      apex_collection.create_collection(
        p_collection_name=>'BOOK'
      apex_collection.add_member(
        p_collection_name=>'BOOK',
        p_c001 => 1,
        p_c002 => 2
      SELECT c001,
        c002
      INTO b,
        c
      FROM apex_collections
      WHERE collection_name ='BOOK'
      htp.prn(b);
      EXECUTE IMMEDIATE 'INSERT INTO ' || a || '.mac(col1,col2) VALUES(:b, :c)' USING b, c;
    END;

  • URGENT:  Incomplete classpath settings

    hi all,
           When we create the project for the development component in NWDS 2004.
    The Development component is having lot of errors. There is no default jarfiles available for the project in java build path --> libraries. When we add the jar ifles externally thro add external jar files, it is having the error,
          <b>The project is incomplete since its classpath is incomplete. cannot find the class file for com.sap.tc.logging.Location.</b>
          <b>This compilation unit indirectly refernces the missing type com.sap.tc.logging.Location.</b>
            Please note that we are accessing the remote server by creating the track, all the developments are made under the track only. If we create the same development component under local development means there is no error. We find one more thing that, under the track there is no jar files available as like in our local development. How to add the these jar files to the track.
    Please guide us to solve  these issues. Issue is in high prioity.
    Thanks in advance.

    Hi Martin,
    Thanks for the Veluable Information. It helped me a lot.
    But one more thing I want to know is How to make Workflow Trigger for the change in a Subtype?
    for Example, I want to trigger my workflow for the change in the Subtpye 7 ( Primary Emergency Details) or 8(secondary Emergency Details).
    Do I also need to write a Check FM for triggerring my Workflow for change in Subtypes and if YES...can you please also let me know the logic.
    Can you please let me know where and how to make these settings...?
    This is very urgent for me,.
    Thanks and Regards,
    Venu Gopal.

  • Malformed or incomplete collection error

    I am trying to work with a custom record type and collections.
    create or replace procedure coll_test
    as
    type param_rec is record (
    param_cd varchar2(10),
    unit_cd varchar2(10),
    min_value number,
    max_value number);
    type param_array is table of param_rec index by binary_integer;
    basic_params param_array;
    begin
      -- load the array
      basic_params(1) := ('00040','43',null,25);
      basic_params(2) := ('00400','12',6,9);
      basic_params(3) := ('01264','28',null,115);
      basic_params(4) := ('00550','19',null,15);
      basic_params(5) := ('01256','28',null,20);
    -- loop through the array
    for i in 1..basic_params.count
    loop
       dbms_output.put_line(basic_params(i).param_cd||' '||basic_params(i).max_value);
    end loop;
    end;
    /When I try to compile this, I get the following error message:
    11/3
    PL/SQL: Statement ignored
    11/22
    PLS-00320: the declaration of the type of this expression is incomplete or malformed
    12/3
    PL/SQL: Statement ignored
    12/22
    PLS-00320: the declaration of the type of this expression is incomplete or malformed
    13/3
    PL/SQL: Statement ignored
    13/22
    PLS-00320: the declaration of the type of this expression is incomplete or malformed
    14/3
    PL/SQL: Statement ignored
    14/22
    PLS-00320: the declaration of the type of this expression is incomplete or malformed
    15/3
    PL/SQL: Statement ignored
    15/22
    PLS-00320: the declaration of the type of this expression is incomplete or malformedSo it appears that I am trying to populate the array incorrectly. Can someone point out what I am doing wrong?
    Tony

    You have to assign all the fields individually -
    there are no constructors for record types.Oh yeah, my mistake. Sorry OP.
    Got confused cos I'd just answered another similar post where the assignment was being done in the declaration section where you can specify the record type like I showed.
    hehe

  • Urgent: You cannot login because an error occurred while retrieving the login URL.

    I got this error when i tried to login to administrator portal
    The error number is wwc-41441
    i can login into portal30 but not into portal30_sso
    please send me a reply as soon as possible

    Hi,
    I ran ssodatan again and got the following error:
    ERROR: Setting Login Server Partner App
    ORA-06508: PL/SQL: could not find program unit being called
    I then found out that the wwsec_sso_enabler_private in the SSO
    schema is invalid and this was causing the above error. I tried
    recompiling the package but got the following error:
    Errors for PACKAGE BODY WWSEC_SSO_ENABLER_PRIVATE:
    LINE/COL ERROR
    151/6 PL/SQL: SQL Statement ignored
    151/13 PLS-00320: the declaration of the type of this
    expression is incomplete or malformed
    151/20 PLS-00336: non-object-table "SECI" illegal in this
    context
    160/4 PL/SQL: SQL Statement ignored
    643/6 PL/SQL: SQL Statement ignored
    643/13 PLS-00320: the declaration of the type of this
    expression is incomplete or malformed
    643/20 PLS-00336: non-object-table "SECI" illegal in this
    context
    LINE/COL ERROR
    651/4 PL/SQL: SQL Statement ignored
    713/4 PL/SQL: SQL Statement ignored
    713/50 PLS-00382: expression is of wrong type
    745/3 PL/SQL: SQL Statement ignored
    746/10 PLS-00389: table, view or alias name "ENBCONFIG" not
    allowed in this context
    The same package in the Portal schema is valid. Will an
    export of this package from a working instance and an import into
    the above instance solve this problem?
    Thanks and Regards,
    Rupesh

  • Malformed cursor

    I am using Oracle Entreprise Manager Console Standalone to compile my code
    2.Cursor read_cur is
    3.     select F.ZZ AS ZZ, F.ID AS ID, P.TYPE AS TYPE
    5.     P.DESC AS DESC,P.PART AS PART
    6.     FROM Table1 F,Table2 P
    7.     WHERE P.AA = F.BB;Compile errors:
    Line # = 2 Column # = 8 Error Text = PLS-00341: declaration of cursor 'READ_CUR' is incomplete or malformed
    What could be the error?
    Message was edited by:
    learningoracle

    Maybe the blank in P.TYPE is the problem?
    3. ...P. TYPE AS TYPEC.

  • How to update Portal 10.1.2 to 10.1.4 under multiportal environment ?

    I install two portal and one infra.
    And Configuring Multiple Middle Tiers with a Load Balancing Router successfully.
    The origin portal virsion is 10.1.2.
    Now i want to update to 10.1.4 but have somthing wrong after I enter the update commond.
    Error message is java.SQLException: IO Exception : connection is reset.
    Then I run de upgrade command again , get the different error message
    ### ERROR: OracleAS Portal 10.1.4 upgrade precheck failed. See /raid/product/OraHome_1/upgrade/temp/portal/precheck.log for details.
    Error: Component upgrade failed PORTAL
    Error: PORTAL component version is: 10.1.2.0.2 INVALID
    FAILURE: Some OracleAS plug-ins report failure during upgrade.
    The Portal Upgrade precheck log is follow:
    -- Portal Upgrade release information: 10.1.4 Release 1
    Upgrade Started in -precheck -force mode at Wed Oct 18 21:22:19 2006
    ### PHASE 1: Initial setup
    Existing temporary directory /raid/product/OraHome_1/upgrade/temp/portal/prechktmp renamed to /raid/product/OraHome_1/upgrade/temp/portal/prechktmp.Wed-Oct-18-21.14.10-2006
    Existing log file /raid/product/OraHome_1/upgrade/temp/portal/precheck.log renamed to /raid/product/OraHome_1/upgrade/temp/portal/precheck.log.Wed-Oct-18-21.14.10-2006
    Creating /raid/product/OraHome_1/upgrade/temp/portal/prechktmp directory
    Creating /raid/product/OraHome_1/upgrade/temp/portal/prechktmp/gen directory
    Welcome to the Oracle Portal Production Upgrade
    The script will lead you through the upgrade step by step.
    For questions asked in this script that have appropriate defaults
    those defaults will be shown in square brackets after the question.
    To accept a default value, simply hit the Return key.
    ### Set New Variables and Validate Environment Variables
    Step started at Wed Oct 18 21:22:19 2006
    PERL5LIB set to ../../../perl/lib/site_perl/5.6.1/i686-linux:../../../perl/lib:../../../perl/lib/5.6.1
    Check SQL*Plus version
    Running upg/frwk/upchkpls.sql### Log shared and environment variables
    Step started at Wed Oct 18 21:22:19 2006
    Log file: /raid/product/OraHome_1/upgrade/temp/portal/precheck.log
    Log dir: /raid/product/OraHome_1/upgrade/temp/portal/prechktmp
    Profile dir: /raid/product/OraHome_1/upgrade/temp/portal/prechktmp/gen
    Verbose flag: 0
    Debug mode: 0
    Force flag: 1
    Nosave flag: 0
    Save flag: 1
    Repos flag: 0
    Compile flag: 0
    Oldver flag: 0
    isPatch flag: 0
    Will save Tables: 1
    Environment variables:
    ===========================================================
    DISPLAY: :0
    G_BROKEN_FILENAMES: 1
    HISTSIZE: 1000
    HOME: /home/oracle
    HOSTNAME: portal1.bizmatch.com.cn
    IBPATH: /usr/bin
    INPUTRC: /etc/inputrc
    KDEDIR: /usr
    LANG: en_US.UTF-8
    LC_CTYPE: en_US.UTF-8
    LD_ASSUME_KERNEL: 2.4.19
    LD_LIBRARY_PATH: /raid/product/OraHome_1/lib32:/raid/product/OraHome_1/lib:/raid/tmp/jdk/jre/lib/i386/client:/raid/tmp/jdk/jre/lib/i386:/raid/tmp/jdk/jre/../lib/i386:/raid/product/OraHome_1/lib32:/raid/product/OraHome_1/network/lib32:/raid/product/OraHome_1/lib:/raid/product/OraHome_1/network/lib:/raid/product/OraHome_1/lib:/usr/lib:/usr/local/lib
    LD_LIBRARY_PATH_64: /raid/product/OraHome_1/lib:/raid/product/OraHome_1/lib32:/raid/product/OraHome_1/network/lib32:/raid/product/OraHome_1/lib:/raid/product/OraHome_1/network/lib:
    LESSOPEN: |/usr/bin/lesspipe.sh %s
    LIBPATH: /raid/product/OraHome_1/lib32:/raid/product/OraHome_1/lib
    LOGNAME: oracle
    LS_COLORS: no=00:fi=00:di=00;34:ln=00;36:pi=40;33:so=00;35:bd=40;33;01:cd=40;33;01:or=01;05;37;41:mi=01;05;37;41:ex=00;32:*.cmd=00;32:*.exe=00;32:*.com=00;32:*.btm=00;32:*.bat=00;32:*.sh=00;32:*.csh=00;32:*.tar=00;31:*.tgz=00;31:*.arj=00;31:*.taz=00;31:*.lzh=00;31:*.zip=00;31:*.z=00;31:*.Z=00;31:*.gz=00;31:*.bz2=00;31:*.bz=00;31:*.tz=00;31:*.rpm=00;31:*.cpio=00;31:*.jpg=00;35:*.gif=00;35:*.bmp=00;35:*.xbm=00;35:*.xpm=00;35:*.png=00;35:*.tif=00;35:
    MAIL: /var/spool/mail/oracle
    NLSPATH: /usr/dt/lib/nls/msg/%L/%N.cat
    ORACLE_BASE: /raid/product
    ORACLE_HOME: /raid/product/OraHome_1
    ORACLE_SID:
    PATH: /raid/product/OraHome_1/bin:../../../perl/bin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/home/oracle/bin:/raid/product/OraHome_1/bin:/usr/local/sbin:/usr/bin/X11:/usr/X11R6/bin:/home/oracle/bin:/bin:/sbin:/usr/bin
    PERL5LIB: ../../../perl/lib/site_perl/5.6.1/i686-linux:../../../perl/lib:../../../perl/lib/5.6.1
    PWD: /raid/tmp/mrua
    QTDIR: /usr/lib/qt-3.3
    REPCA_ORACLE_HOME: /raid/tmp
    SHELL: /bin/bash
    SHLIB_PATH: /raid/product/OraHome_1/lib32:/raid/product/OraHome_1/lib
    SHLVL: 3
    SQLPATH: .:owa:/raid/product/OraHome_1/upgrade/temp/portal/prechktmp/gen:upg/frwk:sql:wwc
    SSH_ASKPASS: /usr/libexec/openssh/gnome-ssh-askpass
    TERM: xterm
    USER: oracle
    XAUTHORITY: /root/.Xauthority
    XFILESEARCHPATH: /usr/dt/app-defaults/%L/Dt
    _: /raid/tmp/jdk/bin/java
    ### PHASE 2: User inputs
    Upgrade phase started at Wed Oct 18 21:22:19 2006
    Processing Metadata File: upg/common/inputchk/inputchk.met Running upg/common/inputchk/inputchk.pl ### Verify that the database has been backed up
    Step started at Wed Oct 18 21:22:19 2006
    Before beginning the upgrade, it is important that you backup your database.
    Have you backed up your database (y/n)? [y]: y
    Ask user for schema and database details
    Enter the name of schema that you would like to upgrade [PORTAL]: portal
    Enter the password for the schema that you would like to upgrade [portal]:
    Enter the password for the SYS user of your database [CHANGE_ON_INSTALL]:
    Enter the TNS connect string to connect to the database [ORCL]: (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=portaldb.bizmatch.com.cn)(PORT=1521))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=IASDB.bizmatch.com.cn)))
    Responses to the above questions will now be recorded in the file
    upgrade.in. Placeholders are recorded instead of actual passwords,
    for security reasons. If you wish, this file can be edited and used
    as the standard input for a subsequent run of upgrade.pl.
    ### Verify database connection information.
    Step started at Wed Oct 18 21:22:19 2006
    Validating the connection information supplied by the user
    Running CheckConnections()Check connection to the Portal repository.
    Check connection as SYS to the Portal repository.
    Ending CheckConnections() Wed Oct 18 21:22:19 2006
    ### PHASE 3: Setup
    Upgrade phase started at Wed Oct 18 21:22:19 2006
    Processing Metadata File: upg/common/setup/setup.met Running upg/common/setup/setup.pl Analyzing the product schema
    Running upg/common/setup/upgettbs.sqlPortal SQL script started at Wed Oct 18 21:22:19 2006
    Connected.
    ### Install messaging framework
    Step started at Wed Oct 18 21:22:19 2006
    Portal SQL script started at Wed Oct 18 21:22:19 2006
    Connected.
    No errors.
    No errors.
    Creating sequence 'wwpof_output_id_seq'
    Creating sequence 'wwpof_output_script_run_id_seq'
    Creating table 'wwpof_output$'
    Creating table 'wwpof_msg$'
    Creating index 'wwpof_output_idx1' in tablespace PORTAL
    Creating index 'wwpof_output_idx2' in tablespace PORTAL
    Creating index 'wwpof_output_idx3' in tablespace PORTAL
    Creating index 'wwpof_msg_uk1' in tablespace PORTAL
    No errors.
    No errors.
    Granting privileges on POF objects to SYS
    Loading /raid/product/OraHome_1/upgrade/temp/portal/prechktmp/upgus.ctl using sqlldr
    Copying scripts to de-install message objects.
    Get Portal version and determine upgrade sequence
    Running upg/common/setup/upgetver.sqlPortal SQL script started at Wed Oct 18 21:22:22 2006
    Connected.
    Upgrading to version 10.1.4.0.0
    Version directories to be traversed: upg/10140
    Running upg/common/setup/setseq.pl Set the correct Traversal Sequence
    ### PHASE 4: Pre upgrade checks
    Upgrade phase started at Wed Oct 18 21:22:22 2006
    Processing Metadata File: upg/common/prechk/prechk.met Running upg/common/prechk/prechk.pl Set up subscriber iteration
    Running upg/common/prechk/upgetsub.sqlPortal SQL script started at Wed Oct 18 21:22:22 2006
    Connected.
    ### Perform pre upgrade checks
    Step started at Wed Oct 18 21:22:22 2006
    Running upg/frwk/utlchvpd.sqlPortal SQL script started at Wed Oct 18 21:22:22 2006
    Connected.
    Calling DoPreChecks()Starting precheck at Wed Oct 18 21:22:23 2006
    Calling upg/common/prechk/sysuppre.sql
    Connected.
    Running upg/common/prechk/upgtabs.sqlPortal SQL script started at Wed Oct 18 21:22:23 2006
    Connected.
    ### ERROR: WWU-00013: Tables with UPG_ prefix were found in the OracleAS Portal
    ### schema.
    ### Table Name
    ### UPG_PTL_OBJECTS$
    ### UPG_PTL_TABLES$
    ### UPG_WWV_DOCINFO
    ### CAUSE: The upgrade is terminated when UPG_ prefix tables are present in the
    ### OracleAS Portal schema.
    ### ACTION: Back up all tables with the UPG_ prefix, then delete them from the
    ### OracleAS Portal schema. The script
    ### /raid/product/OraHome_1/upgrade/temp/portal/prechktmp/dropupg.sql can
    ### be used for this purpose.
    ### Check Failed at Wed Oct 18 21:22:23 2006 Continuing as PreCheck mode is specified
    Calling upg/common/prechk/wwvcheck.sql
    Portal SQL script started at Wed Oct 18 21:22:23 2006
    Connected.
    # Beginning outer script: prechk/wwvcheck
    # Check for invalid Portlet Builder (webview) components.
    # Checking if there are too many archive components.
    # Checking for missing application schemas.
    # Ending outer script: prechk/wwvcheck, 0.31 seconds
    Ending precheck at Wed Oct 18 21:22:24 2006
    Running upg/common/prechk/upchkobj.sqlPortal SQL script started at Wed Oct 18 21:22:24 2006
    Connected.
    Running upg/common/prechk/chkmrreg.sqlPortal SQL script started at Wed Oct 18 21:22:24 2006
    Connected.
    # Beginning outer script: prechk/chkmrreg
    # Pre-check to determine that OracleAS Portal is registered with OracleAS Internet Directory
    # OracleAS Portal has been wired with OracleAS Internet Directory
    # Ending outer script: prechk/chkmrreg, 0.10 seconds
    ### Connect to OID as Application Entry
    Running upg/common/prechk/bindapp.sql . Portal SQL script started at Wed Oct 18 21:22:24 2006
    Connected.
    # Beginning outer script: prechk/bindapp
    #-- Beginning inner script: prechk/bindapp
    # Pre-check to test bind to OracleAS Internet Directory Server
    # Connecting to OracleAS Internet Directory as the Application Entry
    # Connecting to OracleAS Internet Directory as the Application Entry was successful
    #-- Ending inner script: prechk/bindapp, 0.14 seconds
    # Ending outer script: prechk/bindapp, 0.20 seconds
    ### Display Tablespace and Parameter Settings
    Running upg/common/prechk/../../frwk/upshoset.sql .
    Subscriber independent Processing.
    Portal SQL script started at Wed Oct 18 21:22:24 2006
    Connected.
    # Beginning outer script: prechk/upshoset
    Tablespace Usage
    TABLESPACE BYTES_USED BYTES_FREE TOTAL BYTES CREATE_BYTES AUT FILE STAT STATUS     ENABLED BLOCKS BLOCK_SIZE FILE_NAME
    B2B_DT     63766528     20054016 83886080          0 YES AVAILABLE ONLINE     READ WRITE     10240     8192 /raid/product/oradata/IASDB/b2b_dt.dbf
    B2B_IDX 14942208     26935296 41943040          0 YES AVAILABLE ONLINE     READ WRITE     5120     8192 /raid/product/oradata/IASDB/b2b_idx.dbf
    B2B_LOB 11141120     30736384 41943040          0 YES AVAILABLE ONLINE     READ WRITE     5120     8192 /raid/product/oradata/IASDB/b2b_lob.dbf
    B2B_RT     39780352     12582912 52428800          0 YES AVAILABLE ONLINE     READ WRITE     6400     8192 /raid/product/oradata/IASDB/b2b_rt.dbf
    BAM     6553600     3866624 10485760          0 YES AVAILABLE ONLINE     READ WRITE     1280     8192 /raid/product/oradata/IASDB/bam.dbf
    DCM     237174784     20709376 257949696          0 YES AVAILABLE ONLINE     READ WRITE     31488     8192 /raid/product/oradata/IASDB/dcm.dbf
    DISCO_PTM5 1310720     1769472 3145728          0 YES AVAILABLE ONLINE     READ WRITE     384     8192 /raid/product/oradata/IASDB/discopltc1.dbf
    _CACHE
    DISCO_PTM5 1310720     1769472 3145728          0 YES AVAILABLE ONLINE     READ WRITE     384     8192 /raid/product/oradata/IASDB/discopltm1.dbf
    _META
    DSGATEWAY_ 5701632     1572864 7340032          0 YES AVAILABLE ONLINE     READ WRITE     896     8192 /raid/product/oradata/IASDB/oss_sys01.dbf
    TAB
    IAS_META 210567168     30539776 241172480          0 YES AVAILABLE ONLINE     READ WRITE     29440     8192 /raid/product/oradata/IASDB/ias_meta01.dbf
    OCATS     1769472     5505024 7340032          0 YES AVAILABLE ONLINE     READ WRITE     896     8192 /raid/product/oradata/IASDB/oca.dbf
    OLTS_ATTRS 2555904     917504 3538944          0 YES AVAILABLE ONLINE     READ WRITE     432     8192 /raid/product/oradata/IASDB/attrs1_oid.dbf
    TORE
    OLTS_BATTR 262144     131072 516096          0 YES AVAILABLE ONLINE     READ WRITE     63     8192 /raid/product/oradata/IASDB/battrs1_oid.dbf
    STORE
    OLTS_DEFAU 3997696     851968 4915200          0 YES AVAILABLE ONLINE     READ WRITE     600     8192 /raid/product/oradata/IASDB/gdefault1_oid.dbf
    LT
    ORABPEL 11993088     29884416 41943040          0 YES AVAILABLE ONLINE     READ WRITE     5120     8192 /raid/product/oradata/IASDB/orabpel.dbf
    PORTAL     74383360     6946816 78643200          0 YES AVAILABLE ONLINE     READ WRITE     9600     8192 /raid/product/oradata/IASDB/portal.dbf
    PORTAL_DOC 851968     3276800 4194304          0 YES AVAILABLE ONLINE     READ WRITE     512     8192 /raid/product/oradata/IASDB/ptldoc.dbf
    PORTAL_IDX 11206656     41156608 52428800          0 YES AVAILABLE ONLINE     READ WRITE     6400     8192 /raid/product/oradata/IASDB/ptlidx.dbf
    PORTAL_LOG 262144     3866624 4194304          0 YES AVAILABLE ONLINE     READ WRITE     512     8192 /raid/product/oradata/IASDB/ptllog.dbf
    SYSAUX     235732992     5373952 241172480          0 YES AVAILABLE ONLINE     READ WRITE     29440     8192 /raid/product/oradata/IASDB/sysaux01.dbf
    SYSTEM     834404352     4390912 838860800          0 YES AVAILABLE SYSTEM     READ WRITE 102400     8192 /raid/product/oradata/IASDB/system01.dbf
    TEMP     6291456     18874368 25165824     25165824 YES AVAILABLE ONLINE     READ WRITE     3072     8192 /raid/product/oradata/IASDB/temp01.dbf
    UDDISYS_TS 19988480     28180480 48234496          0 YES AVAILABLE ONLINE     READ WRITE     5888     8192 /raid/product/oradata/IASDB/uddisys01.dbf
    UNDOTBS1 247201792     4390912 251658240          0 YES AVAILABLE ONLINE     READ WRITE     30720     8192 /raid/product/oradata/IASDB/undotbs01.dbf
    USERS     327680     4849664 5242880          0 YES AVAILABLE ONLINE     READ WRITE     640     8192 /raid/product/oradata/IASDB/users01.dbf
    WCRSYS_TS 1703936     15007744 16777216          0 YES AVAILABLE ONLINE     READ WRITE     2048     8192 /raid/product/oradata/IASDB/wcrsys01.dbf
    Sort Segment Data
    TABLESPACE EXTENT_SIZE TOTAL_EXTENTS USED_EXTENTS FREE_EXTENTS MAX_USED_SIZE
    TEMP          128          5          0     5          1
    SGA Allocation Stats
    POOL     NAME                    BYTES
    java pool free memory               67108864
    Total                              67108864
    SGA Allocation Stats
    POOL     NAME                    BYTES
    large pool free memory               8388608
    Total                              8388608
    SGA Allocation Stats
    POOL     NAME                    BYTES
    shared pool fixed allocation callback               344
    shared pool pl/sql source               1156
    shared pool table definiti               1712
    shared pool alert threshol               2648
    shared pool trigger inform               3048
    shared pool joxs heap                    4220
    shared pool policy hash ta               4220
    shared pool trigger defini               5980
    shared pool KQR S SO                    7176
    shared pool PLS non-lib hp               12208
    shared pool trigger source               18652
    shared pool KQR L SO                    44032
    shared pool repository                76264
    shared pool KQR M SO                    81408
    shared pool parameters                105696
    shared pool type object de               194164
    shared pool KQR S PO                    207136
    shared pool VIRTUAL CIRCUITS               649340
    shared pool FileOpenBlock               746704
    shared pool kmgsb circular statistics          821248
    shared pool KSXR pending messages que          841036
    shared pool KSXR receive buffers          1032500
    shared pool KQR M PO                    1675892
    shared pool sessions                    1835204
    shared pool PL/SQL DIANA               2910560
    shared pool private strands               2928640
    shared pool KTI-UNDO                    3019632
    shared pool KGLS heap                    3105320
    shared pool PL/SQL MPCODE               3705484
    shared pool row cache                    3707272
    shared pool ASH buffers               4194304
    shared pool event statistics per sess          9094400
    shared pool sql area                    9234624
    shared pool library cache               10361688
    shared pool miscellaneous               15820288
    shared pool free memory               74540744
    Total                              150994944
    SGA Allocation Stats
    POOL     NAME                    BYTES
         log_buffer                524288
         fixed_sga                    778968
         buffer_cache               50331648
    Total                              51634904
    Database Parameters
    NAME                    VALUE
    O7_DICTIONARY_ACCESSIBILITY     FALSE
    active_instance_count
    aq_tm_processes           1
    archive_lag_target          0
    asm_diskgroups
    asm_diskstring
    asm_power_limit           1
    audit_file_dest           /raid/product/OraHome_1/rdbms/audit
    audit_sys_operations          FALSE
    audit_trail               NONE
    background_core_dump          partial
    background_dump_dest          /raid/product/admin/IASDB/bdump
    backup_tape_io_slaves          FALSE
    bitmap_merge_area_size          1048576
    blank_trimming               FALSE
    buffer_pool_keep
    buffer_pool_recycle
    circuits
    cluster_database          FALSE
    cluster_database_instances     1
    cluster_interconnects
    commit_point_strength          1
    compatible               10.1.0.2.0
    control_file_record_keep_time     7
    control_files               /raid/product/oradata/IASDB/control01.ctl, /raid/product/oradata/IASDB/control02
                        .ctl, /raid/product/oradata/IASDB/control03.ctl
    core_dump_dest               /raid/product/admin/IASDB/cdump
    cpu_count               2
    create_bitmap_area_size      8388608
    create_stored_outlines
    cursor_sharing               EXACT
    cursor_space_for_time          FALSE
    db_16k_cache_size          0
    db_2k_cache_size          0
    db_32k_cache_size          0
    db_4k_cache_size          0
    db_8k_cache_size          0
    db_block_buffers          0
    db_block_checking          FALSE
    db_block_checksum          TRUE
    db_block_size               8192
    db_cache_advice           ON
    db_cache_size               50331648
    db_create_file_dest
    db_create_online_log_dest_1
    db_create_online_log_dest_2
    db_create_online_log_dest_3
    db_create_online_log_dest_4
    db_create_online_log_dest_5
    db_domain               bizmatch.com.cn
    db_file_multiblock_read_count     16
    db_file_name_convert
    db_files               200
    db_flashback_retention_target     1440
    db_keep_cache_size          0
    db_name                IASDB
    db_recovery_file_dest          /raid/product/flash_recovery_area
    db_recovery_file_dest_size     2147483648
    db_recycle_cache_size          0
    db_unique_name               IASDB
    db_writer_processes          1
    dbwr_io_slaves               0
    ddl_wait_for_locks          FALSE
    dg_broker_config_file1          /raid/product/OraHome_1/dbs/dr1IASDB.dat
    dg_broker_config_file2          /raid/product/OraHome_1/dbs/dr2IASDB.dat
    dg_broker_start           FALSE
    disk_asynch_io               TRUE
    dispatchers               (PROTOCOL=TCP)(PRE=oracle.aurora.server.GiopServer), (PROTOCOL=TCP)(PRE=oracle.a
                        urora.server.SGiopServer)
    distributed_lock_timeout     60
    dml_locks               1760
    drs_start               FALSE
    enqueue_resources          1980
    event
    fal_client
    fal_server
    fast_start_io_target          0
    fast_start_mttr_target          0
    fast_start_parallel_rollback     LOW
    file_mapping               FALSE
    fileio_network_adapters
    filesystemio_options          none
    fixed_date
    gc_files_to_locks
    gcs_server_processes          0
    global_context_pool_size
    global_names               FALSE
    hash_area_size               131072
    hi_shared_memory_address     0
    hs_autoregister           TRUE
    ifile
    instance_groups
    instance_name               IASDB
    instance_number           0
    instance_type               RDBMS
    java_max_sessionspace_size     0
    java_pool_size               67108864
    java_soft_sessionspace_limit     0
    job_queue_processes          5
    large_pool_size           8388608
    ldap_directory_access          NONE
    license_max_sessions          0
    license_max_users          0
    license_sessions_warning     0
    local_listener
    lock_name_space
    lock_sga               FALSE
    log_archive_config
    log_archive_dest
    log_archive_dest_1
    log_archive_dest_10
    log_archive_dest_2
    log_archive_dest_3
    log_archive_dest_4
    log_archive_dest_5
    log_archive_dest_6
    log_archive_dest_7
    log_archive_dest_8
    log_archive_dest_9
    log_archive_dest_state_1     enable
    log_archive_dest_state_10     enable
    log_archive_dest_state_2     enable
    log_archive_dest_state_3     enable
    log_archive_dest_state_4     enable
    log_archive_dest_state_5     enable
    log_archive_dest_state_6     enable
    log_archive_dest_state_7     enable
    log_archive_dest_state_8     enable
    log_archive_dest_state_9     enable
    log_archive_duplex_dest
    log_archive_format          %t_%s_%r.dbf
    log_archive_local_first      TRUE
    log_archive_max_processes     2
    log_archive_min_succeed_dest     1
    log_archive_start          FALSE
    log_archive_trace          0
    log_buffer               524288
    log_checkpoint_interval      0
    log_checkpoint_timeout          1800
    log_checkpoints_to_alert     FALSE
    log_file_name_convert
    logmnr_max_persistent_sessions     1
    max_commit_propagation_delay     0
    max_dispatchers
    max_dump_file_size          UNLIMITED
    max_enabled_roles          150
    max_shared_servers
    nls_calendar
    nls_comp
    nls_currency
    nls_date_format
    nls_date_language
    nls_dual_currency
    nls_iso_currency
    nls_language               AMERICAN
    nls_length_semantics          BYTE
    nls_nchar_conv_excp          FALSE
    nls_numeric_characters
    nls_sort
    nls_territory               AMERICA
    nls_time_format
    nls_time_tz_format
    nls_timestamp_format
    nls_timestamp_tz_format
    object_cache_max_size_percent     10
    object_cache_optimal_size     102400
    olap_page_pool_size          0
    open_cursors               300
    open_links               4
    open_links_per_instance      4
    optimizer_dynamic_sampling     2
    optimizer_features_enable     10.1.0.5
    optimizer_index_caching      0
    optimizer_index_cost_adj     100
    optimizer_mode               ALL_ROWS
    os_authent_prefix          ops$
    os_roles               FALSE
    parallel_adaptive_multi_user     TRUE
    parallel_automatic_tuning     FALSE
    parallel_execution_message_size 2148
    parallel_instance_group
    parallel_max_servers          40
    parallel_min_percent          0
    parallel_min_servers          0
    parallel_server           FALSE
    parallel_server_instances     1
    parallel_threads_per_cpu     2
    pga_aggregate_target          33554432
    plsql_code_type           INTERPRETED
    plsql_compiler_flags          INTERPRETED, NON_DEBUG
    plsql_debug               FALSE
    plsql_native_library_dir
    plsql_native_library_subdir_count 0
    plsql_optimize_level          2
    plsql_v2_compatibility          FALSE
    plsql_warnings               DISABLE:ALL
    pre_page_sga               FALSE
    processes               150
    query_rewrite_enabled          TRUE
    query_rewrite_integrity      enforced
    rdbms_server_dn
    read_only_open_delayed          FALSE
    recovery_parallelism          0
    remote_archive_enable          true
    remote_dependencies_mode     TIMESTAMP
    remote_listener
    remote_login_passwordfile     EXCLUSIVE
    remote_os_authent          FALSE
    remote_os_roles           FALSE
    replication_dependency_tracking TRUE
    resource_limit               FALSE
    resource_manager_plan
    resumable_timeout          0
    rollback_segments
    serial_reuse               disable
    service_names               IASDB.bizmatch.com.cn
    session_cached_cursors          0
    session_max_open_files          10
    sessions               400
    sga_max_size               281018368
    sga_target               0
    shadow_core_dump          partial
    shared_memory_address          0
    shared_pool_reserved_size     7549747
    shared_pool_size          150994944
    shared_server_sessions
    shared_servers               1
    skip_unusable_indexes          TRUE
    smtp_out_server
    sort_area_retained_size      0
    sort_area_size               65536
    sp_name                IASDB
    spfile                    /raid/product/OraHome_1/dbs/spfileIASDB.ora
    sql92_security               FALSE
    sql_trace               FALSE
    sql_version               NATIVE
    sqltune_category          DEFAULT
    standby_archive_dest          ?/dbs/arch
    standby_file_management      MANUAL
    star_transformation_enabled     FALSE
    statistics_level          TYPICAL
    streams_pool_size          0
    tape_asynch_io               TRUE
    thread                    0
    timed_os_statistics          0
    timed_statistics          TRUE
    trace_enabled               TRUE
    tracefile_identifier
    transactions               440
    transactions_per_rollback_segment 5
    undo_management           AUTO
    undo_retention               900
    undo_tablespace           UNDOTBS1
    use_indirect_data_buffers     FALSE
    user_dump_dest               /raid/product/admin/IASDB/udump
    utl_file_dir
    workarea_size_policy          AUTO
    All Portal DBMS jobs
    JOB LOG_USER          PRIV_USER     SCHEMA_USER
         17 PORTAL          PORTAL          PORTAL
         18 PORTAL          PORTAL          PORTAL
         27 PORTAL          PORTAL          PORTAL
         28 PORTAL          PORTAL          PORTAL
         43 PORTAL          PORTAL          PORTAL
    Details of all Portal DBMS jobs
    JOB WHAT
         17 begin execute immediate     'begin wwctx_sso.cleanup_sessions(
         p_hours_old => 168     ); end;'     ; exception     when others then
         null; end;
         18 wwsec_api_private.rename_users;
         27 wwv_context.sync;
         28 wwv_context.optimize(CTX_DDL.OPTLEVEL_FULL,1440,null);
         43 begin execute immediate     'begin wwutl_cache_sys.process_background_inv
         al;     end;'     ; exception     when others then     wwlog_api.log(p_
         domain=>'utl',     p_subdomain=>'cache',          p_name=>'background
         ',          p_action=>'process_background_inval',      p_information =
         > 'Error in process_background_inval '||          sqlerrm);end;
    Database version details
    BANNER
    Oracle Database 10g Enterprise Edition Release 10.1.0.4.2 - Prod
    PL/SQL Release 10.1.0.4.2 - Production
    CORE     10.1.0.4.0     Production
    TNS for Linux: Version 10.1.0.4.0 - Production
    NLSRTL Version 10.1.0.4.2 - Production
    # Ending outer script: prechk/upshoset, 1.83 seconds
    ### Log invalid DB objects in the temporary directory.
    List count of invalid objects in the database in /raid/product/OraHome_1/upgrade/temp/portal/prechktmp/dbinvob1.log
    Running upg/frwk/dbinvobj.sqlPortal SQL script started at Wed Oct 18 21:22:26 2006
    Connected.
    ### Install Schema Validation Utility
    Running upg/common/prechk/svuver.sql . Portal SQL script started at Wed Oct 18 21:22:26 2006
    Connected.
    # Beginning outer script: prechk/svuver
    #-- Beginning inner script: prechk/svuver
    # Portal Schema Version = 10.1.2.0.2
    # Version of schema validation utility being installed = 101202
    # Load the Schema Validation Utility
    Installed version of schema validation utility: 10.1.2.0.6
    Schema Validation Utility version: 10.1.2.0.6 will be installed.
    No errors.
    No errors.
    No errors.
    No errors.
    No errors.
    No errors.
    No errors.
    No errors.
    No errors.
    No errors.
    No errors.
    No errors.
    No errors.
    No errors.
    No errors.
    No errors.
    No errors.
    Warning: Package Body created with compilation errors.
    Errors for PACKAGE BODY WWUTL_SCHEMA_COMMON:
    44/9     PL/SQL: Statement ignored
    44/16     PLS-00905: object PORTAL.WWSBR_SITE_DB is invalid
    70/9     PL/SQL: Statement ignored
    70/17     PLS-00905: object PORTAL.WWPOB_API_PAGE is invalid
    96/10     PL/SQL: Statement ignored
    96/18     PLS-00905: object PORTAL.WWV_THINGDB is invalid
    122/10     PL/SQL: Statement ignored
    122/18     PLS-00905: object PORTAL.WWV_THINGDB is invalid
    No errors.
    Warning: Package Body created with compilation errors.
    Errors for PACKAGE BODY WWUTL_ATTR_VALIDATION:
    740/9     PL/SQL: SQL Statement ignored
    778/26     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    Warning: Package Body created with compilation errors.
    Errors for PACKAGE BODY WWUTL_PAGE_GROUP_VALIDATION:
    366/9     PL/SQL: SQL Statement ignored
    372/31     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    1447/13 PL/SQL: SQL Statement ignored
    1458/28 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    1624/13 PL/SQL: SQL Statement ignored
    1635/28 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    1783/13 PL/SQL: SQL Statement ignored
    1794/28 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    1896/13 PL/SQL: SQL Statement ignored
    1907/28 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    2009/13 PL/SQL: SQL Statement ignored
    2020/28 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    2126/13 PL/SQL: SQL Statement ignored
    2137/28 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    No errors.
    No errors.
    Warning: Package Body created with compilation errors.
    Errors for PACKAGE BODY WWUTL_PAGE_VALIDATION:
    137/9     PL/SQL: SQL Statement ignored
    144/53     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    258/21     PL/SQL: SQL Statement ignored
    260/43     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    277/17     PL/SQL: SQL Statement ignored
    279/39     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    322/9     PL/SQL: SQL Statement ignored
    327/25     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    353/25     PL/SQL: Statement ignored
    353/40     PLS-00905: object PORTAL.WWPOB_API_PAGE is invalid
    362/29     PL/SQL: SQL Statement ignored
    369/42     PL/SQL: ORA-06575: Package or function WWPOB_API_PAGE is in an
         invalid state
    376/33     PL/SQL: Statement ignored
    376/48     PLS-00905: object PORTAL.WWPOB_API_PAGE is invalid
    385/21     PL/SQL: SQL Statement ignored
    388/39     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    1214/21 PL/SQL: SQL Statement ignored
    1216/42 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    1262/9     PL/SQL: SQL Statement ignored
    1266/30 PL/SQL: ORA-06575: Package or function WWPOB_API_PAGE is in an
         invalid state
    Warning: Package Body created with compilation errors.
    Errors for PACKAGE BODY WWUTL_REGION_VALIDATION:
    237/9     PL/SQL: SQL Statement ignored
    249/41     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    Warning: Package Body created with compilation errors.
    Errors for PACKAGE BODY WWUTL_STYLE_VALIDATION:
    414/9     PL/SQL: SQL Statement ignored
    424/44     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    584/21     PL/SQL: Statement ignored
    584/52     PLS-00905: object PORTAL.WWSBR_SITE_DB is invalid
    Warning: Package Body created with compilation errors.
    Errors for PACKAGE BODY WWUTL_THING_VALIDATION:
    2129/32 PL/SQL: Item ignored
    2130/13 PLS-00905: object PORTAL.WWSBR_THING_TYPES is invalid
    2131/32 PL/SQL: Item ignored
    2132/13 PLS-00905: object PORTAL.WWSBR_THING_TYPES is invalid
    2133/32 PL/SQL: Item ignored
    2134/13 PLS-00905: object PORTAL.WWSBR_THING_TYPES is invalid
    2135/31 PL/SQL: Item ignored
    2136/13 PLS-00905: object PORTAL.WWSBR_THING_TYPES is invalid
    2137/31 PL/SQL: Item ignored
    2138/13 PLS-00905: object PORTAL.WWSBR_THING_TYPES is invalid
    2139/31 PL/SQL: Item ignored
    2140/13 PLS-00905: object PORTAL.WWSBR_THING_TYPES is invalid
    2151/32 PL/SQL: Item ignored
    2151/42 PLS-00320: the declaration of the type of this expression is
         incomplete or malformed
    2152/32 PL/SQL: Item ignored
    2152/42 PLS-00320: the declaration of the type of this expression is
         incomplete or malformed
    2153/32 PL/SQL: Item ignored
    2153/42 PLS-00320: the declaration of the type of this expression is
         incomplete or malformed
    2202/17 PL/SQL: SQL Statement ignored
    2212/27 PL/SQL: ORA-06575: Package or function WWSBR_THING_TYPES is in an
         invalid state
    Warning: Package Body created with compilation errors.
    Errors for PACKAGE BODY WWUTL_ITEM_VALIDATION:
    322/9     PL/SQL: SQL Statement ignored
    338/30     PL/SQL: ORA-06575: Package or function WWPOB_API_PAGE is in an
         invalid state
    Warning: Package Body created with compilation errors.
    Errors for PACKAGE BODY WWUTL_PORTLET_VALIDATION:
    155/13     PL/SQL: SQL Statement ignored
    163/36     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    170/13     PL/SQL: SQL Statement ignored
    178/36     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
         invalid state
    459/9     PL/SQL: SQL Statement ignored
    467/31     PL/SQL: ORA-06575: Package or function WWSBR_SITEBUILDER_PROVIDER
         is in an invalid state
    581/9     PL/SQL: SQL Statement ignored
    584/21     PL/SQL: ORA-06575: Package or function WWSBR_SITEBUILDER_PROVIDER
         is in an invalid state
    588/9     PL/SQL: SQL Statement ignored
    591/29     PL/SQL: ORA-06575: Package or function WWSBR_SITEBUILDER_PROVIDER
         is in an invalid state
    Warning: Package Body created with compilation errors.
    Errors for PACKAGE BODY WWUTL_DBPROV_VALIDATION:
    341/25     PL/SQL: Item ignored
    341/45     PLS-00302: component 'URL' must be declared
    559/17     PL/SQL: Statement ignored
    559/17     PLS-00320: the declaration of the type of this expression is
         incomplete or malformed
    562/17     PL/SQL: Statement ignored
    564/40     PLS-00320: the declaration of the type of this expression is
         incomplete or malformed
    No errors.
    No errors.
    ### Invoke Schema Validation Utility in Report Mode
    Running upg/common/prechk/../../frwk/svurun.sql . Portal SQL script started at Wed Oct 18 21:22:31 2006
    Connected.
    # Beginning outer script: prechk/svurun
    #-- Beginning inner script: frwk/svurun
    declare
    ERROR at line 1:
    ORA-20000:
    ORA-06512: at "PORTAL.WWPOF", line 440
    ORA-06512: at line 45
    ORA-20000:
    ORA-06512: at "PORTAL.WWPOF", line 440
    ORA-06512: at "PORTAL.WWUTL_SCHEMA_VALIDATION", line 263
    ORA-04063: package body "PORTAL.WWUTL_PAGE_GROUP_VALIDATION" has errors
    ORA-06508: PL/SQL: could not find program unit being called
    Connected.
    # Run the report mode of the schema validation utility
    #---- Beginning inner script: wwutl_schema_validation.validate_all
    # Running the validation in report mode
    # Schema Validation Utility Version = 10.1.2.0.6
    # Validate Page Groups
    # Handling exception
    # ERROR: When executing schema validation utility
    # ERROR: ORA-06508: PL/SQL: could not find program unit being called
    # ----- PL/SQL Call Stack -----
    object line object
    handle number name
    0x5c4fef28     434 package body PORTAL.WWPOF
    0x5bb96e20     263 package body PORTAL.WWUTL_SCHEMA_VALIDATION
    0x5bb96e20     297 package body PORTAL.WWUTL_SCHEMA_VALIDATION
    0x5b885fe4     18 anonymous block
    # Handling exception
    # ERROR: When running the schema validation utility
    # ERROR: ORA-20000:
    ORA-06512: at "PORTAL.WWPOF", line 440
    ORA-06512: at "PORTAL.WWUTL_SCHEMA_VALIDATION", line 263
    ORA-04063: package body "PORTAL.WWUTL_PAGE_GROUP_VALIDATION" has errors
    ORA-06508: PL/SQL: could not find program unit being called
    # ----- PL/SQL Call Stack -----
    object line object
    handle number name
    0x5c4fef28     434 package body PORTAL.WWPOF
    0x5b885fe4     45 anonymous block
    ### ERROR: Exception Executing upg/common/prechk/../../frwk/svurun.sql REPORT PRECHK for Subscriber: 1
    ### Check Failed at Wed Oct 18 21:22:31 2006 Continuing as PreCheck mode is specified
    ### PHASE 5: Version specific user inputs
    Upgrade phase started at Wed Oct 18 21:22:31 2006
    Processing Metadata File: upg/10140/inputchk/inputchk.met ###
    ### PHASE 6: Version specific pre upgrade checks
    Upgrade phase started at Wed Oct 18 21:22:31 2006
    Processing Metadata File: upg/10140/prechk/prechk.met ###
    ### PHASE 7: Pre upgrade common information gathering
    Upgrade phase started at Wed Oct 18 21:22:31 2006
    Processing Metadata File: upg/common/info/info.met ### Log portal configuration info in the temporary directory.
    Running upg/common/info/ptlinfo.sql . Portal SQL script started at Wed Oct 18 21:22:31 2006
    Connected.
    # Beginning outer script: info/ptlinfo
    # Ending outer script: info/ptlinfo, 0.13 seconds
    Metadata File upg/10140/info/info.met does not exist.
    ### PHASE 8: Verify user inputs
    Upgrade phase started at Wed Oct 18 21:22:32 2006
    Processing Metadata File: upg/common/verfyinp/verfyinp.met Running upg/common/verfyinp/verfyinp.pl The following details have been determined:
    General Details
    ===========================================================
    Log File Name : /raid/product/OraHome_1/upgrade/temp/portal/precheck.log
    RDBMS Version : 10.1.0
    Product Version : 10.1.2.0.2
    Oracle PL/SQL Toolkit Schema : SYS
    Oracle PL/SQL Toolkit version : 10.1.2.0.2
    O7 accessibility : FALSE
    Schema Details
    ===========================================================
    Name : portal
    Connect String : (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=portaldb.bizmatch.com.cn)(PORT=1521))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=IASDB.bizmatch.com.cn)))
    Tablespace Details
    ===========================================================
    Default Tablespace : PORTAL
    Temporary Tablespace : TEMP
    Document Tablespace : PORTAL_DOC
    Logging Tablespace : PORTAL_LOG
    Index Tablespace : PORTAL
    ### ERROR: WWU-00030: Pre-Check mode encountered the following errors:
    ### 184 : ### ERROR: WWU-00013: Tables with UPG_ prefix were found in the OracleAS Portal
    ### 706 : 44/16     PLS-00905: object PORTAL.WWSBR_SITE_DB is invalid
    ### 708 : 70/17     PLS-00905: object PORTAL.WWPOB_API_PAGE is invalid
    ### 710 : 96/18     PLS-00905: object PORTAL.WWV_THINGDB is invalid
    ### 712 : 122/18     PLS-00905: object PORTAL.WWV_THINGDB is invalid
    ### 719 : 778/26     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 727 : 372/31     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 731 : 1458/28 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 735 : 1635/28 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 739 : 1794/28 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 743 : 1907/28 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 747 : 2020/28 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 751 : 2137/28 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 761 : 144/53     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 765 : 260/43     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 769 : 279/39     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 773 : 327/25     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 777 : 353/40     PLS-00905: object PORTAL.WWPOB_API_PAGE is invalid
    ### 779 : 369/42     PL/SQL: ORA-06575: Package or function WWPOB_API_PAGE is in an
    ### 783 : 376/48     PLS-00905: object PORTAL.WWPOB_API_PAGE is invalid
    ### 785 : 388/39     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 789 : 1216/42 PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 793 : 1266/30 PL/SQL: ORA-06575: Package or function WWPOB_API_PAGE is in an
    ### 801 : 249/41     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 809 : 424/44     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 813 : 584/52     PLS-00905: object PORTAL.WWSBR_SITE_DB is invalid
    ### 819 : 2130/13 PLS-00905: object PORTAL.WWSBR_THING_TYPES is invalid
    ### 821 : 2132/13 PLS-00905: object PORTAL.WWSBR_THING_TYPES is invalid
    ### 823 : 2134/13 PLS-00905: object PORTAL.WWSBR_THING_TYPES is invalid
    ### 825 : 2136/13 PLS-00905: object PORTAL.WWSBR_THING_TYPES is invalid
    ### 827 : 2138/13 PLS-00905: object PORTAL.WWSBR_THING_TYPES is invalid
    ### 829 : 2140/13 PLS-00905: object PORTAL.WWSBR_THING_TYPES is invalid
    ### 831 : 2151/42 PLS-00320: the declaration of the type of this expression is
    ### 835 : 2152/42 PLS-00320: the declaration of the type of this expression is
    ### 839 : 2153/42 PLS-00320: the declaration of the type of this expression is
    ### 843 : 2212/27 PL/SQL: ORA-06575: Package or function WWSBR_THING_TYPES is in an
    ### 851 : 338/30     PL/SQL: ORA-06575: Package or function WWPOB_API_PAGE is in an
    ### 859 : 163/36     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 863 : 178/36     PL/SQL: ORA-06575: Package or function WWSBR_SITE_DB is in an
    ### 867 : 467/31     PL/SQL: ORA-06575: Package or function WWSBR_SITEBUILDER_PROVIDER
    ### 871 : 584/21     PL/SQL: ORA-06575: Package or function WWSBR_SITEBUILDER_PROVIDER
    ### 875 : 591/29     PL/SQL: ORA-06575: Package or function WWSBR_SITEBUILDER_PROVIDER
    ### 883 : 341/45     PLS-00302: component 'URL' must be declared
    ### 885 : 559/17     PLS-00320: the declaration of the type of this expression is
    ### 889 : 564/40     PLS-00320: the declaration of the type of this expression is
    ### 904 : ERROR at line 1:
    ### 905 : ORA-20000:
    ### 906 : ORA-06512: at "PORTAL.WWPOF", line 440
    ### 907 : ORA-06512: at line 45
    ### 908 : ORA-20000:
    ### 909 : ORA-06512: at "PORTAL.WWPOF", line 440
    ### 910 : ORA-06512: at "PORTAL.WWUTL_SCHEMA_VALIDATION", line 263
    ### 911 : ORA-04063: package body "PORTAL.WWUTL_PAGE_GROUP_VALIDATION" has errors
    ### 912 : ORA-06508: PL/SQL: could not find program unit being called
    ### 922 : # ERROR: When executing schema validation utility
    ### 923 : # ERROR: ORA-06508: PL/SQL: could not find program unit being called
    ### 933 : # ERROR: When running the schema validation utility
    ### 934 : # ERROR: ORA-20000:
    ### 935 : ORA-06512: at "PORTAL.WWPOF", line 440
    ### 936 : ORA-06512: at "PORTAL.WWUTL_SCHEMA_VALIDATION", line 263
    ### 937 : ORA-04063: package body "PORTAL.WWUTL_PAGE_GROUP_VALIDATION" has errors
    ### 938 : ORA-06508: PL/SQL: could not find program unit being called
    ### 947 : ### ERROR: Exception Executing upg/common/prechk/../../frwk/svurun.sql REPORT PRECHK for Subscriber: 1
    ### Check Failed at Wed Oct 18 21:22:32 2006 Continuing as PreCheck mode is specified
    Pre-Check Completed at Wed Oct 18 21:22:32 2006

    Hi,
    Its good that u pasted the complete log file. In your environment you have to run this upgrade tool only once from any of the middle tier.
    And with respect to your error that u got in precheck is quite simple. All u have to do is just run this script from by connecting to portal schema using sqlplus.
    Run dropupg.sql
    Location-------- /raid/product/OraHome_1/upgrade/temp/portal/prechktmp/dropupg.sql
    Later you re-run the upgrade tool and let me know the status.
    Good luck
    Tanmai

  • Solved. error in apxldimg after upgrade from 3.0 to 3.1 on 9.2.0.5 database

    Hi,
    I've upgraded my Apex installation on a 9.2.0.5 database and get an error when running the apxldimg.sql script.
    SQL> @apxldimg d:\xml
    PL/SQL procedure successfully completed.
    old   1: create directory APEX_IMAGES as '&1/apex/images'
    new   1: create directory APEX_IMAGES as 'd:\xml/apex/images'
    Directory created.
        filelist_xml        xmltype := xmltype(bfilename(upload_directory_name,file_
    list),nls_charset_id('AL32UTF8'));
    ERROR at line 15:
    ORA-06550: line 15, column 36:
    PLS-00306: wrong number or types of arguments in call to 'XMLTYPE'
    ORA-06550: line 15, column 25:
    PL/SQL: Item ignored
    ORA-06550: line 38, column 15:
    PLS-00302: component 'EXISTSRESOURCE' must be declared
    ORA-06550: line 38, column 3:
    PL/SQL: Statement ignored
    ORA-06550: line 52, column 46:
    PLS-00320: the declaration of the type of this expression is incomplete or
    malformed
    ORA-06550: line 52, column 3:
    PL/SQL: Statement ignored
    ORA-06550: line 57, column 53:
    PLS-00201: identifier 'I' must be declared
    ORA-06550: line 57, column 5:
    PL/SQL: Statement ignored
    ORA-06550: line 86, column 19:
    PLS-00306: wrong number or types of arguments in call to 'CREATERESOURCE'
    ORA-06550: line 86, column 9:
    PL/SQL: Statement ignored
    ORA-06550: line 88, column 19:
    PLS-00306: wrong number or types of arguments in call to 'CREATERESOURCE'
    ORA-06550: line 88, column 9:
    PL/SQL: Statement ignored
        if not dbms_xdb.existsResource(ro_anonymous_acl) and
    ERROR at line 18:
    ORA-06550: line 18, column 21:
    PLS-00302: component 'EXISTSRESOURCE' must be declared
    ORA-06550: line 18, column 5:
    PL/SQL: Statement ignoredWho has an idea what is the problem ?
    SQL> select comp_id,version from dba_registry;
    COMP_ID                        VERSION
    CATALOG                        9.2.0.5.0
    CATPROC                        9.2.0.5.0
    OWM                            9.2.0.1.0
    JAVAVM                         9.2.0.5.0
    XML                            9.2.0.7.0
    CATJAVA                        9.2.0.5.0
    ORDIM                          9.2.0.5.0
    SDO                            9.2.0.5.0
    CONTEXT                        9.2.0.5.0
    XDB                            9.2.0.5.0
    WK                             9.2.0.5.0
    APEX                           3.1.1.00.09Rene
    Message was edited by:
    Rene W.

    Hi Rene,
    When you found out that you misread the instrucition and you already ran the script, what did you do next? Did you restore the db and redo over? Or did you continue on? I have the same problem with you too but I'm not sure what to do next.
    Trina :)
    [email protected]

  • Error while upgrading to 10.1.3.5 from 10.1.3.1

    hi
    i am trying to upgrade to 10.1.3.5. i ran the bpel upgrade scripts with ORABEL user and it all went fine.
    I ran ESB upgrade script (upgrade_10131_10135_oracle.sql) with ORAESB user and i am getting errors.
    Below are the errors - Please help.
    SQL> Rem DESCRIPTION
    SQL> Rem <short description of component this file declares/defines>
    SQL> Rem
    SQL> Rem NOTES
    SQL> Rem <other useful comments, qualifications, etc.>
    SQL> Rem
    SQL> Rem MODIFIED (MM/DD/YY)
    SQL> Rem atusingh 06/20/08 - Backport atusingh_bug-7163503 from
    SQL> Rem st_pcbpel_10.1.3.1
    SQL> Rem atusingh 06/17/08 - Backport atusingh_bug-7168163 from
    SQL> Rem st_pcbpel_10.1.3.1
    SQL> Rem atusingh 06/02/08 - Backport atusingh_backport_heartbeat from
    SQL> Rem st_pcbpel_10.1.3.1
    SQL> Rem atusingh 05/14/08 - Backport atusingh_bug-7017649 from
    SQL> Rem st_pcbpel_10.1.3.1
    SQL> Rem
    SQL>
    SQL> Rem SET ECHO ON
    SQL> Rem SET FEEDBACK 1
    SQL> Rem SET NUMWIDTH 10
    SQL> Rem SET LINESIZE 80
    SQL> Rem SET TRIMSPOOL ON
    SQL> Rem SET TAB OFF
    SQL> Rem SET PAGESIZE 100
    SQL>
    SQL> drop table ESB_message_map;
    Table dropped.
    SQL> drop table ESB_messages;
    Table dropped.
    SQL> drop table ESB_group_status;
    Table dropped.
    SQL> drop table ESB_containerid_lease;
    Table dropped.
    SQL>
    SQL> CREATE TABLE ESB_messages
    2 (
    3 message_id varchar2(48) PRIMARY KEY, -- unique id for the mess
    age
    4 system_guid varchar2(48),
    5 operation_guid varchar2(48),
    6 flow_id varchar2(100),
    7 key varchar2(1000), -- modify the size of varchar2 base
    d on expected size of key
    8 from_system_guid varchar2(48),
    9 priority number(3),
    10 transactional number(1),
    11 correlation_id varchar2(48),
    12 error_message varchar2(2000),
    13 error_stack varchar2(4000),
    14 header blob,
    15 data blob,
    16 dummy1 varchar2(200),
    17 dummy2 varchar2(200),
    18 dummy3 varchar2(200)
    19 );
    Table created.
    SQL>
    SQL> CREATE TABLE ESB_group_status
    2 (
    3 group_id varchar2(100), -- group id
    4 last_sequence_id varchar2(100), -- sequence id of the last message d
    elivered
    5 last_received_time timestamp, -- time of the last message delivered
    6 error number(1), -- 1 if error
    7 lockConId varchar2(100), -- id of the container that locked t
    he group
    8 lockTime timestamp, -- time locked
    9 service_guid varchar2(48), -- guid of service
    10 system_guid varchar2(48),
    11 destination_system_guid varchar2(48),
    12 version number(38,0),
    13 dummy1 varchar2(200),
    14 dummy2 varchar2(200),
    15 dummy3 varchar2(200),
    16 PRIMARY KEY(group_id, service_guid)
    17 );
    Table created.
    SQL>
    SQL> CREATE TABLE ESB_message_map
    2 (
    3 id varchar2(48) PRIMARY KEY,
    4 service_guid varchar2(48), -- guid of service
    5 group_id varchar2(100), -- group id of the message
    6 sequence_id varchar2(100), -- sequence id of the message
    7 message_id varchar2(48), -- id of the message
    8 received_time timestamp, -- time the message was received by the
    ESB
    9 status number(1), -- message status
    10 standard_sequence_id varchar2(100),
    11 dummy1 varchar2(200),
    12 dummy2 varchar2(200),
    13 dummy3 varchar2(200),
    14 FOREIGN KEY(message_id) REFERENCES ESB_messages(message_id) on delete c
    ascade,
    15 CONSTRAINT stnd_reseq UNIQUE(service_guid, group_id, standard_sequence_
    id)
    16 );
    Table created.
    SQL>
    SQL> create table ESB_containerid_lease (
    2 container_id varchar2(100) PRIMARY KEY,
    3 renewal_time timestamp
    4 );
    Table created.
    SQL>
    SQL> create index resequencer_index1 on ESB_MESSAGE_MAP (STATUS, SERVICE_GUID, G
    ROUP_ID, SEQUENCE_ID);
    Index created.
    SQL>
    SQL> -- Create xref_data table if it is not already created by user
    SQL> CREATE TABLE XREF_DATA
    2 (
    3 XREF_TABLE_NAME VARCHAR2(2000) NOT NULL,
    4 XREF_COLUMN_NAME VARCHAR2(2000) NOT NULL,
    5 ROW_NUMBER VARCHAR2(48) NOT NULL,
    6 VALUE VARCHAR2(2000) NOT NULL,
    7 IS_DELETED VARCHAR2(1) NOT NULL,
    8 LAST_MODIFIED VARCHAR2(100) NOT NULL,
    9 LAST_ACCESSED VARCHAR2(100) NOT NULL
    10 );
    CREATE TABLE XREF_DATA
    ERROR at line 1:
    ORA-00955: name is already used by an existing object
    SQL>
    SQL> CREATE INDEX XREF_ROW_NUMBER ON XREF_DATA(ROW_NUMBER);
    CREATE INDEX XREF_ROW_NUMBER ON XREF_DATA(ROW_NUMBER)
    ERROR at line 1:
    ORA-00955: name is already used by an existing object
    SQL> CREATE INDEX XREF_VALUE ON XREF_DATA(VALUE);
    CREATE INDEX XREF_VALUE ON XREF_DATA(VALUE)
    ERROR at line 1:
    ORA-00955: name is already used by an existing object
    SQL>
    SQL> commit;
    Commit complete.
    SQL> @@upgrade_10134_10135_oracle.sql
    SQL> Rem
    SQL> Rem $Header: integration/sql/oracle/upgrade_10134_10135_oracle.sql /st_pcbp
    el_10.1.3.1/1 2009/03/20 00:47:34 vnuthi Exp $
    SQL> Rem
    SQL> Rem upgrade_10134_10135_oracle.sql
    SQL> Rem
    SQL> Rem Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved.
    SQL> Rem
    SQL> Rem NAME
    SQL> Rem upgrade_10134_10135_oracle.sql - <one-line expansion of the name>
    SQL> Rem
    SQL> Rem DESCRIPTION
    SQL> Rem <short description of component this file declares/defines>
    SQL> Rem
    SQL> Rem NOTES
    SQL> Rem <other useful comments, qualifications, etc.>
    SQL> Rem
    SQL> Rem MODIFIED (MM/DD/YY)
    SQL> Rem vnuthi 03/19/09 - Created
    SQL> Rem
    SQL>
    SQL> SET ECHO ON
    SQL> SET FEEDBACK 1
    SQL> SET NUMWIDTH 10
    SQL> SET LINESIZE 80
    SQL> SET TRIMSPOOL ON
    SQL> SET TAB OFF
    SQL> SET PAGESIZE 100
    SQL>
    SQL>
    SQL> ALTER TABLE ESB_FAULTED_INSTANCE add (WSIF_RETRYABLE VARCHAR2(1));
    ALTER TABLE ESB_FAULTED_INSTANCE add (WSIF_RETRYABLE VARCHAR2(1))
    ERROR at line 1:
    ORA-00942: table or view does not exist
    SQL> commit;
    Commit complete.
    SQL>
    SQL>
    SQL> ALTER TABLE WF_EVENTS
    2 ADD ("FQ_PATH" LONG VARCHAR );
    ALTER TABLE WF_EVENTS
    ERROR at line 1:
    ORA-00942: table or view does not exist
    SQL>
    SQL> DECLARE
    2 CURSOR guids_c IS select guid from wf_events;
    3 CURSOR steps_c(cguid VARCHAR2) IS select name from (
    4 select guid,name,system_guid owner_guid from wf_events
    5 where owner_guid is null
    6 union
    7 select guid,name,owner_guid from wf_events
    8 where owner_guid is not null
    9 union
    10 select guid,name,null owner_guid from wf_systems
    11 where guid in (select distinct system_guid from wf_events) )
    12 start with guid=cguid connect by guid= prior owner_guid;
    13
    14
    15 path VARCHAR2(32767);
    16 sguid wf_events.guid%TYPE;
    17
    18 BEGIN
    19
    20 OPEN guids_c;
    21 LOOP
    22 FETCH guids_c into sguid;
    23 EXIT WHEN guids_c%notfound;
    24
    25 path := '';
    26
    27 FOR rec IN steps_c(sguid)
    28 LOOP
    29 path := rec.name || '.' || path;
    30 END LOOP;
    31
    32 path := trim(trailing '.' from path);
    33 --dbms_output.put_line('GUID ' ||  sguid || ' = ' || path );
    34
    35 update wf_events wf set fq_path = path where wf.guid = sguid;
    36 END LOOP;
    37 CLOSE guids_c;
    38
    39 commit;
    40 END;
    41 /
    CURSOR guids_c IS select guid from wf_events;
    ERROR at line 2:
    ORA-06550: line 2, column 38:
    PL/SQL: ORA-00942: table or view does not exist
    ORA-06550: line 2, column 21:
    PL/SQL: SQL Statement ignored
    ORA-06550: line 4, column 59:
    PL/SQL: ORA-00942: table or view does not exist
    ORA-06550: line 3, column 37:
    PL/SQL: SQL Statement ignored
    ORA-06550: line 16, column 9:
    PLS-00201: identifier 'WF_EVENTS.GUID' must be declared
    ORA-06550: line 16, column 9:
    PL/SQL: Item ignored
    ORA-06550: line 22, column 24:
    PLS-00320: the declaration of the type of this expression is incomplete or
    malformed
    ORA-06550: line 22, column 5:
    PL/SQL: SQL Statement ignored
    ORA-06550: line 27, column 24:
    PLS-00320: the declaration of the type of this expression is incomplete or
    malformed
    ORA-06550: line 27, column 5:
    PL/SQL: Statement ignored
    ORA-06550: line 35, column 12:
    PL/SQL: ORA-00942: table or view does not exist
    ORA-06550: line 35, column 5:
    PL/SQL: SQL Statement ignored

    got the problem. i am running oraesb as sysdba which i should not do.

  • How to insert the data from XML to a table

    Hi,
    I'm using Oracle 10g Express Edition
    I need help in How to insert the data from XML file into the table.
    Below is the example i'm working on..
    I have create ridb user with below mentioned privileges:
    Account Status Locked Unlocked
    Default Tablespace: USERS
    Temporary Tablespace: TEMP
    User Privileges :
    Roles:
    CONNECT
    RESOURCE
    Direct Grant System Privileges:
    CREATE DATABASE LINK
    CREATE MATERIALIZED VIEW
    CREATE PROCEDURE
    CREATE PUBLIC SYNONYM
    CREATE ROLE
    CREATE SEQUENCE
    CREATE SYNONYM
    CREATE TABLE
    CREATE TRIGGER
    CREATE TYPE
    CREATE VIEW
    & table is created TRIALZIPCODES below mentioned is the DDL:
    CREATE TABLE TRIALZIPCODES
    STATE_ABBR VARCHAR2(20) NOT NULL
    , ZIP_CODE NUMBER(10, 0) NOT NULL
    , ZIP_CODE_EXT VARCHAR2(20)
    Below is the XML FILE: which is stored in C:\OracleProject Folder
    File name: trial.xml
    <?xml version="1.0" ?>
    <metadata>
    - <Zipcodes>
    - <mappings Record="4">
    <STATE_ABBREVIATION>CA</STATE_ABBREVIATION>
    <ZIPCODE>94301</ZIPCODE>
    </mappings>
    - <mappings Record="5">
    <STATE_ABBREVIATION>CO</STATE_ABBREVIATION>
    <ZIPCODE>80323</ZIPCODE>
    <ZIP_CODE_EXTN>9277</ZIP_CODE_EXTN>
    </mappings>
    </Zipcodes>
    </metadata>
    PL/SQL Procedure:which i'm trying to execute from SQLDeveloper
    create or replace
    PROCEDURE TRIAL AS
    BEGIN
    DECLARE
    -- declare attributes
    charString varchar2(80);
    finalStr varchar2(4000) := null;
    rowsp integer;
    v_FileHandle UTL_FILE.FILE_TYPE;
    l_context_handle dbms_xmlgen.ctxHandle;
    insCtx DBMS_XMLStore.ctxType;
    begin
    -- DBMS_XMLGEN.setRowTag ( ctx IN ctxHandle, rowTag IN VARCHAR2);
    -- DBMS_XMLGEN.setRowSetTag ( ctx IN ctxHandle, rowSetTag IN VARCHAR2);
    -- the name of the table as specified in our DTD
    DBMS_XMLGEN.SETROWSETTAG(l_context_handle,'zipcodes');
    -- the name of the data set as specified in our DTD
    DBMS_xmlgen.setRowTag(l_context_handle,'mappings');
    -- for getting the output on the screen
    dbms_output.enable(1000000);
    -- open the XML document in read only mode
    v_FileHandle := utl_file.fopen('c:/OracleProject','trial.xml', 'r');
    loop
    BEGIN
    utl_file.get_line(v_FileHandle, charString);
    exception
    when no_data_found then
    utl_file.fclose(v_FileHandle);
    exit;
    END;
    dbms_output.put_line(charString);
    if finalStr is not null then
    finalStr := finalStr || charString;
    else
    finalStr := charString;
    end if;
    end loop;
    -- for inserting the XML data into the table
    insCtx := DBMS_XMLSTORE.NEWCONTEXT('RIDB.TRIALZIPCODES');
    insCtx := DBMS_XMLSTORE.INSERTXML(insCtx, finalStr);
    dbms_output.put_line('INSERT DONE '||TO_CHAR(rowsp));
    DBMS_XMLStore.closeContext(insCtx);
    END;
    END TRIAL;
    For the first time when i complied i got the errors as :
    Procedure RIDB.PROCEDURE1@RIDB
    Error(16,14): PLS-00201: identifier 'UTL_FILE' must be declared
    Error(16,14): PL/SQL: Item ignored
    Error(29,1): PLS-00320: the declaration of the type of this expression is incomplete or malformed
    Error(29,1): PL/SQL: Statement ignored
    Error(33,1): PL/SQL: Statement ignored
    Error(33,19): PLS-00320: the declaration of the type of this expression is incomplete or malformed
    Error(36,1): PL/SQL: Statement ignored
    Error(36,17): PLS-00320: the declaration of the type of this expression is incomplete or malformed
    So i logged in as sys & grant the permission to execute on UTL_FILE to ridb (user):
    SQL Statement:
    grant execute on utl_file to ridb
    So, it got compiled successfully but when i execute it gives me error as:
    Source does not have a runnable target.
    What does this mean?
    So I browse through forum & i got to know that i need to initial the UTL_FILE_DIR ="C:/OracleProject" in init.ora
    So can i edit the init.ora with notepad.When i tried to do that it says permission denied
    In my system it shows the init.ora file in path C:\oraclexe\app\oracle\product\10.2.0\server\config\scripts
    but there is also other file initXETemp in the same path do i need to do the changes in it.
    I have tried even editing the SPFILE as mentioned below:
    C:\oraclexe\app\oracle\product\10.2.0\server\dbs\SPFILEEXE - I had edit this file using notepad & set the value of UTL_FILE_DIR ="C:/OracleProject". So next time when i restarted i'm unable to log on to the database.
    So i had reinstall the software again.
    Could you please let me know how to proceed..

    hi,
    I have created the directory from sys database
    CREATE or replace DIRECTORY XML_DIR2 AS 'C:\OracleProject';
    & grant read,write access to the user
    grant read,write on directory XML_DIR2 to RIDB;
    & i had change the tag name in the xml file as shown below:
    <?xml version = '1.0'?>
    <metadata>
    <Zipcodes>
    <mappings Record="4">
    <STABBRE>CA</STABBRE>
    <ZIPCODE>94301</ZIPCODE>
    </mappings>
    <mappings Record="5">
    <STABBRE>CO</STABBRE>
    <ZIPCODE>80323</ZIPCODE>
    <ZIPCODEEXT>9277</ZIPCODEEXT>
    </mappings>
    </Zipcodes>
    </metadata>
    TRIALZIPCODE table as shown below:
    CREATE TABLE "RIDB"."TRIALZIPCODE"
    (     "STABBRE" VARCHAR2(20 BYTE),
         "ZIPCODE" NUMBER(*,6) NOT NULL ENABLE,
         "ZIPCODEEXT" NUMBER
    ) PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS LOGGING
    STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
    PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
    TABLESPACE "USERS" ;
    I have tried two methods as shown below:
    Procedure 1:
    create or replace
    PROCEDURE TRIAL_V2 AS
    BEGIN
    DECLARE
    -- declare attributes
    charString varchar2(80);
    finalStr varchar2(4000) := null;
    rowsp integer;
    v_FileHandle UTL_FILE.FILE_TYPE;
    l_context_handle dbms_xmlgen.ctxHandle;
    insCtx DBMS_XMLStore.ctxType;
    cnt NUMBER;
    xmldoc xmltype := xmltype( bfilename('XML_DIR2','trialxml.xml'), nls_charset_id('AL32UTF8') );
    --XML_DIR VARCHAR2(40) := 'C:\\OracleProject';
    BEGIN
    insCtx := DBMS_XMLStore.newContext('DEV.TRIALZIPCODES');
    DBMS_XMLStore.setUpdateColumn(insCtx, 'STABBRE');
    DBMS_XMLStore.setUpdateColumn(insCtx, 'ZIPCODE');
    DBMS_XMLStore.setUpdatecolumn(insCtx, 'ZIPCODEEXT');
    DBMS_XMLStore.setRowTag(insCtx, 'mappings');
    cnt := DBMS_XMLStore.insertXML(insCtx, xmldoc);
    DBMS_XMLStore.closeContext(insCtx);
    END;
    Procedure 1 was compiled with out errors but when i execute i got the error as :
    Source does not have a runnable target.
    Procedure 2_
    CREATE OR REPLACE PROCEDURE TRIAL_V3 AS
    BEGIN
    DECLARE
    -- declare attributes
    charString varchar2(80);
    finalStr varchar2(4000) := null;
    rowsp integer;
    v_FileHandle UTL_FILE.FILE_TYPE;
    l_context_handle dbms_xmlgen.ctxHandle;
    insCtx DBMS_XMLStore.ctxType;
    cnt NUMBER;
    xmldoc xmltype := xmltype( bfilename('XML_DIR2','trialxml.xml'), nls_charset_id('AL32UTF8') );
    --XML_DIR VARCHAR2(40) := 'C:\\OracleProject';
    BEGIN
    INSERT INTO trialzipcode (STABBRE, ZIPCODE, ZIPCODEEXT)
    SELECT extractvalue(x.column_value, 'mappings/STABBRE'),
    extractvalue(x.column_value, 'mappings/ZIPCODE'),
    extractvalue(x.column_value, 'mappings/ZIPCODEEXT')
    FROM TABLE(
    XMLSequence(
    EXTRACT(
    xmltype( bfilename('XML_DIR2','trialxml.xml'), nls_charset_id('AL32UTF8') ),
    'metadata/Zipcodes/mappings'
    ) x
    END;
    END TRIAL_V3;
    Procedure 2 was complied without errors but when i execute i got the error as:
    Connecting to the database RIDB.
    ORA-22288: file or LOB operation FILEOPEN failed
    The system cannot find the file specified.
    ORA-06512: at "SYS.DBMS_LOB", line 523
    ORA-06512: at "SYS.XMLTYPE", line 287
    ORA-06512: at "RIDB.TRIAL_V3", line 12
    ORA-06512: at line 2
    Process exited.
    Disconnecting from the database RIDB.
    Could you please let me know how to proceed...

  • This is a show stopper

    I am relatively new to PL/SQL scripting, trying to pull data from Oracle DB 11g through SQL*PLUS.
    I am putting all the select items of the select query into ORACLE RECORD as defined below.
    I am not putting the entire select query as it is quite long list of items.
    Appreciate your help & Thank you in advance.
    DECLARE
      file_dir varchar2(20) := '/usr/tmp2';
      file_name varchar2(20) := 'Emp_Data';
      file utl_file.file_type;
      cursor PnJD_cur is
       select query;
      emp_rec PnJD_cur%rowtype;
    BEGIN
      OPEN PnJD_cur;
      WHILE TRUE
      LOOP
      FETCH PnJD_cur INTO emp_rec;
      EXIT WHEN PnJD_cur%NOTFOUND;
      file := utl_file.fopen(file_dir,file_name||'.csv','w');
      utl_file.put(file, emp_rec);
      utl_file.fclose(file);
      END LOOP;
      CLOSE PnJD_cur;
      dbms_output.put_line(file_name||'.csv');
    END;
    and execute the query & receive below error.
            emp_rec PnJD_cur%rowtype;
    ERROR at line 125:
    ORA-06550: line 125, column 10:
    PLS-00402: alias required in SELECT list of cursor to avoid duplicate column
    names
    ORA-06550: line 125, column 10:
    PL/SQL: Item ignored
    ORA-06550: line 131, column 22:
    PLS-00320: the declaration of the type of this expression is incomplete or
    malformed
    ORA-06550: line 131, column 2:
    PL/SQL: SQL Statement ignored
    ORA-06550: line 135, column 25:
    PLS-00320: the declaration of the type of this expression is incomplete or
    malformed
    ORA-06550: line 135, column 2:
    PL/SQL: Statement ignored
    Thank you
    Gaura

    Here's an example from my library of examples, for creating CSV files based on a supplied query...
    As sys user:
    CREATE OR REPLACE DIRECTORY TEST_DIR AS '\tmp\myfiles'
    GRANT READ, WRITE ON DIRECTORY TEST_DIR TO myuser
    As myuser:
    CREATE OR REPLACE PROCEDURE run_query(p_sql IN VARCHAR2
                                         ,p_dir IN VARCHAR2
                                         ,p_header_file IN VARCHAR2
                                         ,p_data_file IN VARCHAR2 := NULL) IS
      v_finaltxt  VARCHAR2(4000);
      v_v_val     VARCHAR2(4000);
      v_n_val     NUMBER;
      v_d_val     DATE;
      v_ret       NUMBER;
      c           NUMBER;
      d           NUMBER;
      col_cnt     INTEGER;
      f           BOOLEAN;
      rec_tab     DBMS_SQL.DESC_TAB;
      col_num     NUMBER;
      v_fh        UTL_FILE.FILE_TYPE;
      v_samefile  BOOLEAN := (NVL(p_data_file,p_header_file) = p_header_file);
    BEGIN
      c := DBMS_SQL.OPEN_CURSOR;
      DBMS_SQL.PARSE(c, p_sql, DBMS_SQL.NATIVE);
      d := DBMS_SQL.EXECUTE(c);
      DBMS_SQL.DESCRIBE_COLUMNS(c, col_cnt, rec_tab);
      FOR j in 1..col_cnt
      LOOP
        CASE rec_tab(j).col_type
          WHEN 1 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_v_val,2000);
          WHEN 2 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_n_val);
          WHEN 12 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_d_val);
        ELSE
          DBMS_SQL.DEFINE_COLUMN(c,j,v_v_val,2000);
        END CASE;
      END LOOP;
      -- This part outputs the HEADER
      v_fh := UTL_FILE.FOPEN(upper(p_dir),p_header_file,'w',32767);
      FOR j in 1..col_cnt
      LOOP
        v_finaltxt := ltrim(v_finaltxt||','||lower(rec_tab(j).col_name),',');
      END LOOP;
      --  DBMS_OUTPUT.PUT_LINE(v_finaltxt);
      UTL_FILE.PUT_LINE(v_fh, v_finaltxt);
      IF NOT v_samefile THEN
        UTL_FILE.FCLOSE(v_fh);
      END IF;
      -- This part outputs the DATA
      IF NOT v_samefile THEN
        v_fh := UTL_FILE.FOPEN(upper(p_dir),p_data_file,'w',32767);
      END IF;
      LOOP
        v_ret := DBMS_SQL.FETCH_ROWS(c);
        EXIT WHEN v_ret = 0;
        v_finaltxt := NULL;
        FOR j in 1..col_cnt
        LOOP
          CASE rec_tab(j).col_type
            WHEN 1 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_v_val);
                        v_finaltxt := ltrim(v_finaltxt||',"'||v_v_val||'"',',');
            WHEN 2 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_n_val);
                        v_finaltxt := ltrim(v_finaltxt||','||v_n_val,',');
            WHEN 12 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_d_val);
                        v_finaltxt := ltrim(v_finaltxt||','||to_char(v_d_val,'DD/MM/YYYY HH24:MI:SS'),',');
          ELSE
            DBMS_SQL.COLUMN_VALUE(c,j,v_v_val);
            v_finaltxt := ltrim(v_finaltxt||',"'||v_v_val||'"',',');
          END CASE;
        END LOOP;
      --  DBMS_OUTPUT.PUT_LINE(v_finaltxt);
        UTL_FILE.PUT_LINE(v_fh, v_finaltxt);
      END LOOP;
      UTL_FILE.FCLOSE(v_fh);
      DBMS_SQL.CLOSE_CURSOR(c);
    END;
    This allows for the header row and the data to be written to seperate files if required.
    e.g.
    SQL> exec run_query('select * from emp','TEST_DIR','output.csv');
    PL/SQL procedure successfully completed.
    Output.csv file contains:
    empno,ename,job,mgr,hiredate,sal,comm,deptno
    7369,"SMITH","CLERK",7902,17/12/1980 00:00:00,800,,20
    7499,"ALLEN","SALESMAN",7698,20/02/1981 00:00:00,1600,300,30
    7521,"WARD","SALESMAN",7698,22/02/1981 00:00:00,1250,500,30
    7566,"JONES","MANAGER",7839,02/04/1981 00:00:00,2975,,20
    7654,"MARTIN","SALESMAN",7698,28/09/1981 00:00:00,1250,1400,30
    7698,"BLAKE","MANAGER",7839,01/05/1981 00:00:00,2850,,30
    7782,"CLARK","MANAGER",7839,09/06/1981 00:00:00,2450,,10
    7788,"SCOTT","ANALYST",7566,19/04/1987 00:00:00,3000,,20
    7839,"KING","PRESIDENT",,17/11/1981 00:00:00,5000,,10
    7844,"TURNER","SALESMAN",7698,08/09/1981 00:00:00,1500,0,30
    7876,"ADAMS","CLERK",7788,23/05/1987 00:00:00,1100,,20
    7900,"JAMES","CLERK",7698,03/12/1981 00:00:00,950,,30
    7902,"FORD","ANALYST",7566,03/12/1981 00:00:00,3000,,20
    7934,"MILLER","CLERK",7782,23/01/1982 00:00:00,1300,,10
    The procedure allows for the header and data to go to seperate files if required.  Just specifying the "header"
    filename will put the header and data in the one file.
    Adapt to output different datatypes and styles are required.

  • 'alias required in SELECT..'  - Why can't I see this?

    Please help I'm going mad here!
    The error message is:
    ERROR at line 1:
    ORA-06550: line 113, column 37:
    PLS-00402: alias required in SELECT list of cursor to avoid duplicate column
    names
    ORA-06550: line 113, column 37:
    PL/SQL: Item ignored
    ORA-06550: line 137, column 13:
    PLS-00320: the declaration of the type of this expression is incomplete or
    malformed
    ORA-06550: line 136, column 7:
    PL/SQL: SQL Statement ignored
    ..Yet I disagree.. I cant see any 2 fields called the same.
    (FYI the cursor it speaks of is called 'c_check_employee').
    And the code.
    /* Formatted on 2009/02/27 15:35 (Formatter Plus v4.8.7) */
    SET serveroutput ON SIZE 1000000 FORMAT WRAPPED
    SET verify OFF
    SET feedback OFF
    DECLARE
    -- Debugging/error handling
    -- Work variables
       p_emp_number                     VARCHAR2 (14);
       v_rec_cnt                        NUMBER                          := 0;
       insert_flag                      VARCHAR2 (8);
       l_validate                       BOOLEAN                     DEFAULT FALSE;
       l_obj                            NUMBER;
       l_datetrack_update_mode          VARCHAR2 (30)             := 'CORRECTION';
       l_assignment_sequence            NUMBER;
       l_name_combination_warning       BOOLEAN                         := FALSE;
       l_assign_payroll_warning         BOOLEAN                         := FALSE;
       l_org_now_no_manager_warning     BOOLEAN;
       l_other_manager_warning          BOOLEAN;
       l_spp_delete_warning             BOOLEAN;
       l_entries_changed_warning        VARCHAR2 (30);
       l_tax_district_changed_warning   BOOLEAN;
       l_person_id                      NUMBER;
       l_assignment_id                  NUMBER;
       l_special_ceiling_step_id        NUMBER;
       l_per_effective_end_date         DATE
                                        := TO_DATE ('11-Jul-2049', 'DD-MON-YYYY');
       l_people_group_id                NUMBER;
       l_group_name                     VARCHAR2 (30);
       l_assignment_number              VARCHAR2 (35);
       l_effective_end_date             DATE
                                        := TO_DATE ('11-Jul-2049', 'DD-MON-YYYY');
       l_date                           DATE                           := SYSDATE;
       ip_p_address_id                  per_addresses.address_id%TYPE;
       ip_p_object_version_number       NUMBER;
       ip_p_party_id                    per_addresses.party_id%TYPE;
       l_per_object_version_number      NUMBER;
       l_asg_object_version_number      NUMBER;
       l_full_name                      VARCHAR2 (240);
       l_per_comment_id                 NUMBER;
       l_per_effective_start_date       DATE;
       l_concatenated_segments          VARCHAR2 (12);
       l_soft_coding_keyflex_id         NUMBER;
       l_comment_id                     NUMBER;
       l_no_managers_warning            BOOLEAN;
    -- Get employee details info from work table
       CURSOR get_employee_details
       IS
          SELECT std_validate, std_person_id, std_assignment_id, std_hire_date,
                 std_business_group_id, std_last_name, std_sex,
                 std_date_of_birth, std_email_address, std_employee_number,
                 std_first_name, std_marital_status, std_middle_names,
                 std_nationality, std_title, std_national_identifier,
                 std_address_line1, std_address_line2, std_address_line3,
                 std_address_line4, std_post_code, std_telephone_1,
                 std_position_id, std_job_id, std_location_id,
                 std_organization_id, std_supervisor_id,
                 std_default_code_comb_id, std_set_of_books_id, std_payroll_id,
                 std_grade_id, std_pay_basis_id, std_assn_ovn
            FROM SU_TEMPLOYEE_DETAILS;
    -- checks employee details info from PER_ALL_PEOPLE_F table
       CURSOR c_check_employee (p_emp_number VARCHAR2)
       IS
          SELECT paas.assignment_id, per.person_id, per.business_group_id,
                 per.last_name, per.start_date, per.date_of_birth, per.email_address,
                per.employee_number, per.first_name, per.marital_status, per.middle_names,
         per.nationality, per.national_identifier, per.sex, per.title, padd.address_id,
         padd.primary_flag,padd.address_line1, padd.address_line2, padd.address_line3,
                 padd.town_or_city, padd.postal_code, padd.telephone_number_1, padd.telephone_number_2,
         padd.telephone_number_3,paas.job_id,   paas.location_id,paas.organization_id, paas.assignment_type, paas.primary_flag, paas.supervisor_id,paas.default_code_comb_id,
    paas.set_of_books_id,paas.assignment_number, paas.period_of_service_id,paas.object_version_number
            FROM per_all_people_f per,
                 per_all_assignments_f paas,
                 per_addresses padd
           WHERE per.employee_number = p_emp_number
             AND per.person_id = padd.person_id
             AND paas.person_id(+) = per.person_id;
       emp_rec                          c_check_employee%ROWTYPE;
    -- Cursor retrieves latest Object Version Number from per_assignments_f table..
       CURSOR csr_ovn (cp_person_id IN per_all_people_f.person_id%TYPE)
       IS
          SELECT MAX (paas.object_version_number)
            FROM per_assignments_f paas, per_all_people_f per
           WHERE paas.person_id = per.person_id
             AND per.employee_number = paas.assignment_number
             AND per.person_id = cp_person_id;
    BEGIN
    -- Process each record in the work table
       FOR v_emp IN get_employee_details
       LOOP
    -- determine whether customer already exists
          OPEN c_check_employee (v_emp.std_employee_number);
          FETCH c_check_employee
           INTO emp_rec;
          IF c_check_employee%NOTFOUND
          THEN
             insert_flag := 'I';
          ELSE
             insert_flag := 'X';
          END IF;
          CLOSE c_check_employee;
    -- Obtain the most recent Object Version Number..
          OPEN csr_ovn (v_emp.std_person_id);
          FETCH csr_ovn
           INTO l_obj;
          --   IF csr_ovn%NOTFOUND     THEN        RAISE NO_DATA_FOUND;   END IF;
          CLOSE csr_ovn;
    -- Create new PER_ALL_PEOPLE_F and PER_ADDRESSES record from
    --            info in  table record
          IF insert_flag = 'I'
          THEN
             BEGIN                             -- Importing Employee Procedure --
                --      DBMS_OUTPUT.PUT (CHR (10));
                --      DBMS_OUTPUT.PUT_LINE ('Importing employees....  ');
                BEGIN
                   Hr_Employee_Api.create_gb_employee
                      (p_validate                       => l_validate,
                       p_hire_date                      => v_emp.std_hire_date,
                       p_business_group_id              => v_emp.std_business_group_id,
                       p_date_of_birth                  => v_emp.std_date_of_birth,
                       p_email_address                  => v_emp.std_email_address,
                       p_first_name                     => v_emp.std_first_name,
                       p_middle_names                   => v_emp.std_middle_names,
                       p_last_name                      => v_emp.std_last_name,
                       p_sex                            => v_emp.std_sex,
                       p_ni_number                      => v_emp.std_national_identifier,
                       p_employee_number                => v_emp.std_employee_number,
                       p_person_id                      => l_person_id,
                       p_title                          => v_emp.std_title,
                       p_assignment_id                  => l_assignment_id,
                       p_per_object_version_number      => l_per_object_version_number,
                       p_asg_object_version_number      => l_asg_object_version_number,
                       p_per_effective_start_date       => l_per_effective_start_date,
                       p_per_effective_end_date         => l_per_effective_end_date,
                       p_full_name                      => l_full_name,
                       p_per_comment_id                 => l_per_comment_id,
                       p_assignment_sequence            => l_assignment_sequence,
                       p_assignment_number              => l_assignment_number,
                       p_name_combination_warning       => l_name_combination_warning,
                       p_assign_payroll_warning         => l_assign_payroll_warning
                   Hr_Person_Address_Api.create_person_address
                      (p_validate                     => l_validate,
                       p_effective_date               => v_emp.std_hire_date,
                       p_pradd_ovlapval_override      => NULL,
                       p_validate_county              => NULL,
                       p_person_id                    => l_person_id,
                       p_primary_flag                 => 'Y',
                       p_style                        => 'GB_GLB',
    --                p_date_from                    => v_emp.std_hire_date,
                       p_date_from                    => SYSDATE,
                       p_date_to                      => NULL,
                       p_address_line1                => v_emp.std_address_line1,
                       p_address_line2                => v_emp.std_address_line2,
                       p_address_line3                => v_emp.std_address_line3,
                       p_town_or_city                 => v_emp.std_address_line4,
                       p_postal_code                  => v_emp.std_post_code,
                       p_country                      => v_emp.std_nationality,
                       p_telephone_number_1           => v_emp.std_telephone_1,
                       p_party_id                     => ip_p_party_id,
                       p_address_id                   => ip_p_address_id,
                       p_object_version_number        => l_obj
                                                      --ip_p_object_version_number
                   Hr_Assignment_Api.update_emp_asg_criteria
                      (p_validate                          => l_validate,
                       p_effective_date                    =>  l_date,    --   SYSDATE
                       p_datetrack_update_mode             => l_datetrack_update_mode,
                       p_assignment_id                     => l_assignment_id,
                       p_object_version_number             => l_obj,
                       p_organization_id                   => v_emp.std_organization_id,
                       p_location_id                       => v_emp.std_location_id,
                       p_job_id                            => v_emp.std_job_id,
                       p_position_id                       => v_emp.std_position_id,
                       p_special_ceiling_step_id           => l_special_ceiling_step_id,
                       p_effective_start_date              => l_date,
                       p_effective_end_date                => l_effective_end_date,    --IN/OUT
                       p_people_group_id                   => l_people_group_id, --IN/OUT
                       p_group_name                        => l_group_name,  --IN/OUT
                       p_org_now_no_manager_warning        => l_org_now_no_manager_warning,   --IN/OUT
                  p_other_manager_warning         => l_other_manager_warning,   --IN/OUT
                       p_spp_delete_warning                => l_spp_delete_warning, --IN/OUT
                       p_entries_changed_warning           => l_entries_changed_warning,  --IN/OUT
                       p_tax_district_changed_warning      => l_tax_district_changed_warning  --IN/OUT
                  Hr_Assignment_Api.update_emp_asg
                      (p_validate                    => l_validate,           -- in
                       p_effective_date              => l_date,
                       p_datetrack_update_mode       => 'CORRECTION',
                       p_assignment_id               => l_assignment_id,
                       p_object_version_number       => l_obj,
                       p_supervisor_id               => v_emp.std_supervisor_id, 
                       p_default_code_comb_id        => v_emp.std_default_code_comb_id,
                       p_set_of_books_id             => v_emp.std_set_of_books_id,
                       p_concatenated_segments       => l_concatenated_segments, -- out
                       p_soft_coding_keyflex_id      => l_soft_coding_keyflex_id,     -- out
                       p_comment_id                  => l_comment_id,       -- out
                       p_effective_start_date        => l_date,           -- out
                       p_effective_end_date          => l_effective_end_date,
                       p_no_managers_warning         => l_no_managers_warning,
                       p_other_manager_warning       => l_other_manager_warning
                --     DBMS_OUTPUT.PUT_LINE ('Employee No:'|| v_emp.std_employee_number|| '  imported successfully..' );
                EXCEPTION
                   WHEN OTHERS
                   THEN
                      RAISE NO_DATA_FOUND;
                      --        DBMS_OUTPUT.PUT (CHR (10));
                      DBMS_OUTPUT.PUT_LINE (   'Ah, Employee:'
                                            || v_emp.std_employee_number
                                            || ' failed to load.. '
                                            || SQLERRM
                --      DBMS_OUTPUT.PUT (CHR (10));
                END;
             END;
             --        DBMS_OUTPUT.PUT (CHR (10));
             v_rec_cnt := v_rec_cnt + 1;
    --         DBMS_OUTPUT.PUT_LINE (   'There were '|| v_rec_cnt|| '  records read in..');
    -- End of customer related details
          END IF;
       END LOOP;
       COMMIT;
    END;
    EXIT;
    many thanks..

    Check primary_flag .... ;)
    Regards.
    Satyaki De.
    Alex is Winner.... ;)
    Edited by: Satyaki_De on Mar 2, 2009 5:33 PM

  • Error When Prompting for Substitution Variable

    Hi - I'm receiving an error when I try to run the following using the substitution variable - but only when I enter a string; when I enter a numeric value it runs fine.
    DECLARE
        l_SCR_Info            VARCHAR2(50) := '''SCR'||&SCR_NUM||'-'||'''';
    begin
    dbms_output.put_line(l_SCR_Info);
    end;Here is the error I receive when I supply a string value when prompted:
    ORA-06550: line 3, column 52:
    PLS-00201: identifier 'AB' must be declared
    ORA-06550: line 3, column 27:
    PL/SQL: Item ignored
    ORA-06550: line 10, column 22:
    PLS-00320: the declaration of the type of this expression is incomplete or malformed
    ORA-06550: line 10, column 1:
    PL/SQL: Statement ignoredCan anyone shed some light on what I'm missing here?
    Thanks!
    Christine

    Hi,
    It looks like you just want one string there:
    l_SCR_Info            VARCHAR2(50) := '''SCR&SCR_NUM-''';Remeber how substitution variables work: SQL*Plus replaces them with values before sending the code to the back end to be compiled.
    If you give a value like AB for the variable, the code you posted is equivalent to:
         l_SCR_Info            VARCHAR2(50) := '''SCR'|| AB ||'-'||'''';by the time it reaches the compiler. AB is not inside quotes, so the compiler looks for a variable or function called AB.
    If you gave a number:
         l_SCR_Info            VARCHAR2(50) := '''SCR'|| 123 ||'-'||'''';there's no problem; the compile knows what the literal number 123 is.

  • Using a Variable for Table Name  with a cursor

    Hello All
    Is it possible to use a Parameter passed to a procedure as the table name
    in a cursor selection statment. I thought the below would work but I get
    a error. Does anyone have any ideas?? The Error is listed below to.
    Here's the code I just complied
    CREATE OR REPLACE PROCEDURE Dup_Add(NEWQATABLE IN VARCHAR2) IS
    CURSOR c1 IS SELECT MUNI,PROV FROM NEWQATABLE GROUP BY MUNI, PROV;
    c1rec c1%ROWTYPE;
    BEGIN
    OPEN c1;
    LOOP
    FETCH c1 INTO c1rec;
    EXIT WHEN c1%NOTFOUND;
    DBMS_OUTPUT.PUT_LINE(c1rec.MUNI);
    END LOOP;
    CLOSE c1;
    END;
    Here is the errors
    LINE/COL ERROR
    3/8 PLS-00341: declaration of cursor 'C1' is incomplete or malformed
    3/15 PL/SQL: SQL Statement ignored
    3/38 PLS-00201: identifier 'NEWQATABLE' must be declared
    5/7 PL/SQL: Item ignored
    10/3 PL/SQL: SQL Statement ignored
    10/17 PLS-00320: the declaration of the type of this expression is
    incomplete or malformed
    12/3 PL/SQL: Statement ignored
    12/24 PLS-00320: the declaration of the type of this expression is
    incomplete or malformed
    LINE/COL ERROR
    Thanks
    Peter

    If you are going to have a table name or a column name as a parameter, then you have to open the cursor dynamically. The following example uses Native Dynamic SQL (NDS) to open a ref cursor dynamically. I also eliminated the group by clause, since it is intended for use with aggregate functions and you weren't using an aggregate function. Also notice that there are some other differences in terms of defining variables and fetching and so forth.
    SQL> CREATE TABLE test_table
      2  AS
      3  SELECT deptno AS muni,
      4         dname  AS prov
      5  FROM   dept
      6  /
    Table created.
    SQL> CREATE OR REPLACE PROCEDURE Dup_Add
      2    (newqatable IN VARCHAR2)
      3  IS
      4    TYPE cursor_type IS REF CURSOR;
      5    c1 cursor_type;
      6    c1muni NUMBER;
      7    c1prov VARCHAR2 (20);
      8  BEGIN
      9    OPEN c1 FOR 'SELECT muni, prov FROM ' || newqatable;
    10    LOOP
    11      FETCH c1 INTO c1muni, c1prov;
    12      EXIT WHEN c1%NOTFOUND;
    13      DBMS_OUTPUT.PUT_LINE (c1muni || ' ' || c1prov);
    14    END LOOP;
    15    CLOSE c1;
    16  END;
    17  /
    Procedure created.
    SQL> SHOW ERRORS
    No errors.
    SQL> SET SERVEROUTPUT ON
    SQL> EXECUTE dup_add ('test_table')
    10 ACCOUNTING
    20 RESEARCH
    30 SALES
    40 OPERATIONS
    PL/SQL procedure successfully completed.

Maybe you are looking for

  • Cannot add item in A/P Invoice

    Hi, all, I want create a A/P invoice without copy from PO or GRPO. However, after I input BP Code, I am not able to add item in Matrix row. Seems that it is blocked Any ideas? Thanks

  • Lost right click meny Acrobat X Win7 64 latest update!

    Running Acrobat X Pro with Windows 7 64bit. Installed correctly and included Windows 7 right click menu to convert files, etc. Notified that a security update available, so I installed it and restarted system. After restart, Acrobat functions no long

  • MEDIASOURCE- won't burn a cd! Can't find a cd recorder device is fo

    Hey, i just got a creative zen 20 gig installed the media source program fine. And i got to work fine it finds cds, rips them onto the computer and to the zen, but it when i try to burn a cd using the program it says it can't find a cd recording devi

  • Get associated avi file from avi file reference

    For normal bytestream files, there is a "refum to path" function (under File I/O -> Advanced File Functions) that will give the associated file path for the input file reference.  This does not seem to work when an AVI file reference (opened using IM

  • Cannot drag songs to playlist

    I have updated my iTunes to the version 9 For some reason I cannot drag any songs from my library to any playlist Can anybody help me Gordon