Unable to invoke the package

Hi all

Database version: 11.2.0.3.0

I have it here the package
CREATE OR REPLACE PACKAGE seagrs_validate_serial_pkg 
AS

-- Declaration of the collection variable
TYPE srl_prod_type IS RECORD
(serial_number  VARCHAR2(100)
,product_number VARCHAR2(100)
,return_message VARCHAR2(500)
,return_status  NUMBER
); 

TYPE srl_prod_tbl_type IS TABLE OF srl_prod_type;

PROCEDURE seagrs_validate_serial(p_serial_prod_in IN OUT srl_prod_tbl_type,                                                   
                                 p_error_msg_out  OUT VARCHAR2,
                                 p_error_code_out OUT VARCHAR2,
                                 p_ret_status_out OUT NUMBER);
END seagrs_validate_serial_pkg;
CREATE OR REPLACE PACKAGE BODY seagrs_validate_serial_pkg
AS

PROCEDURE seagrs_validate_serial(p_serial_prod_in IN OUT srl_prod_tbl_type,                                                   
                                 p_error_msg_out  OUT VARCHAR2,
                                 p_error_code_out OUT VARCHAR2,
                                 p_ret_status_out OUT NUMBER) 
IS  

l_srl_prt_cnt NUMBER;
l_serial_num  VARCHAR2(100);  
l_part_num    VARCHAR2(100);
l_serial_type VARCHAR2(1);
l_error_msg   VARCHAR2(300);

-- Defining user defined exceptions
   exp_part_serial EXCEPTION;

   
BEGIN
--
----------------------------------------------------------------------------
-- FORMAT VALIDATION OF PRODUCT NUM AND SERIAL NUM
----------------------------------------------------------------------------
--
IF (p_serial_prod_in IS NULL ) THEN
         l_error_msg := 'Error - serial and product numbers are missing.';
         RAISE exp_part_serial;        
ELSE
  l_srl_prt_cnt:=p_serial_prod_in.COUNT;
END IF;      

FOR i IN 1..l_srl_prt_cnt
  LOOP
     IF p_serial_prod_in(i).serial_number IS NOT NULL THEN 
   SELECT regexp_replace(regexp_replace(regexp_replace(upper(p_serial_prod_in(i).serial_number ),
                                                        '( *[[:punct:]])',
                                                        ''),
                                         '(*[[:space:]])',
                                         ''),
                          '(*[[:cntrl:]])',
                          '') as serial_number
      INTO l_serial_num    
      FROM DUAL;
      
         IF REGEXP_LIKE(l_serial_num, '^[[:alnum:]]{7,30}$') THEN           
            IF SUBSTR(l_serial_num, 1, 2) = 'ST' THEN                 
              p_serial_prod_in(i).return_message:= 'Invalid Serial: '||l_serial_num||',  serial Number cannot start with ST'; 
              p_serial_prod_in(i).return_status:=1;           
            END IF;             
          ELSE
            p_serial_prod_in(i).return_message:= 'Invalid Serial: '||l_serial_num||', serial number need to be minimum 7 characters and maximum of 30 characters';  
            p_serial_prod_in(i).return_status:=1;
          END IF;     
   
  ELSIF p_serial_prod_in(i).product_number IS NOT NULL THEN  
   SELECT regexp_replace(regexp_replace(regexp_replace(upper(p_serial_prod_in(i).product_number),
                                                      '( *[[:punct:]])',
                                                      ''),
                                       '(*[[:space:]])',
                                       ''),
                        '(*[[:cntrl:]])',
                        '') AS product_number
    INTO l_part_num
    FROM dual;   
    
       IF REGEXP_LIKE(l_part_num, '^[[:alnum:]]{2,20}$') THEN
          IF SUBSTR(l_part_num, -3, 3) = '000' THEN                    
            p_serial_prod_in(i).return_message:='Part Number: '||l_part_num||', ending with 000 are not allowed';        
            p_serial_prod_in(i).return_status:=1;
          END IF;
        ELSE
          p_serial_prod_in(i).return_message:='Part Number: '||l_part_num||', should not be less than 2 number';
          p_serial_prod_in(i).return_status:=1;
        END IF;        
  END IF;        
p_serial_prod_in(i).return_message:=null;  
p_serial_prod_in(i).return_status:=0;
 END LOOP;
 p_error_msg_out:=NULL;
 p_ret_status_out:=0;
EXCEPTION    
      WHEN exp_part_serial THEN
         p_error_code_out := SQLCODE;
         p_error_msg_out := l_error_msg;
         p_ret_status_out := 1;

      WHEN OTHERS THEN
         p_error_code_out := sqlcode;
         p_error_msg_out :=  SUBSTR(SQLERRM || DBMS_UTILITY.FORMAT_ERROR_STACK || DBMS_UTILITY.FORMAT_ERROR_STACK,1,500);
         P_RET_STATUS_OUT := 1;   
END;         
END seagrs_validate_serial_pkg;
I tried to call the package as below, it generates an error. Help, please
DECLARE   
  l_return_code varchar2(500);  
  l_return_message varchar2(500);
  xx apps.seagrs_validate_serial_pkg.srl_prod_type;
  l_status NUMBER;    
BEGIN  
  xx.serial_number := 'STH006N5';  
  apps.seagrs_validate_serial_pkg.seagrs_validate_serial(apps.seagrs_validate_serial_pkg.srl_prod_tbl_type(xx),l_return_code,l_return_message,l_status);
 dbms_output.put_line(l_return_code||' '||l_status||' '||l_return_message);  
  dbms_output.put_line(xx.return_message);
END;

Error report:
ORA-06550: line 8, column 58:
PLS-00363: expression 'APPS.SEAGRS_VALIDATE_SERIAL_PKG.SRL_PROD_TBL_TYPE(XX)' cannot be used as an assignment target
ORA-06550: line 8, column 3:
PL/SQL: Statement ignored
06550. 00000 -  "line %s, column %s:\n%s"
*Cause:    Usually a PL/SQL compilation error.
*Action:
Thanks and greetings
Srinivas

The first parameter of this procedure is IN OUT, it must be a variable.

DECLARE
   l_srl_prod apps.seagrs_validate_serial_pkg.srl_prod_type;
   l_srl_prod_tbl apps.seagrs_validate_serial_pkg.srl_prod_tbl_type;

   l_return_code VARCHAR2 (500);
   l_return_message VARCHAR2 (500);
   l_return_status NUMBER;
BEGIN
   l_srl_prod.serial_number := 'STH006N5';
   l_srl_prod_tbl := apps.seagrs_validate_serial_pkg.srl_prod_tbl_type (l_srl_prod);

   apps.seagrs_validate_serial_pkg.seagrs_validate_serial (
      l_srl_prod_tbl, l_return_code, l_return_message, l_return_status);

   DBMS_OUTPUT.put_line (
      l_return_code || ' ' || l_return_status || ' ' || l_return_message);

   DBMS_OUTPUT.put_line (l_srl_prod_tbl (1).return_message);
END;
/

Tags: Database

Similar Questions

  • Unable to find the package in the connections even if the user has access to DBA_OBJECTS and DBA_SOURCE

    Hello

    We have a user with access to the DBA_SOURCE database and DBA_OBJECTS.

    I am able to select both DBA_OBJECTS and DBA_SOURCE.

    But when I try to look for any package or the procedure I am not able to see the packages and procedures in the Connections window.

    With the help of TOAD, the database user is able to view packages and procedures.

    Is there a workaround for SQL Developer? If this is not the case, a request for improvement can be saved?

    Kind regards

    -Debo

    If we determine that you have access to the DBA_ data dictionary views, here's what we run to load the node procs

    Select * from)

    SELECT OBJECT_NAME, OBJECT_ID,

    Cast (last_ddl_time as timestamp) LAST_MODIFIED,.

    DECODE THE INVALID (STATUS, 'INVALID', 'TRUE', 'FALSE').

    'TRUE' executable,

    Has_body 'FALSE. '

    PLSQL_DEBUG, o.created

    OF SYS. Dba_OBJECTS o, Dba_plsql_object_settings s

    WHERE o.OWNER =: SCHEMA

    AND s.OWNER (+) =: SCHEMA

    AND s.name (+) = o.OBJECT_NAME

    AND s.TYPE (+) =: TYPE

    AND OBJECT_TYPE =: TYPE

    AND SUBOBJECT_NAME IS NULL

    AND OBJECT_ID NOT IN (SELECT PURGE_OBJECT FROM RECYCLEBIN)

    )

  • Invoke the DDL after RAISE_APPLICATION_ERROR

    Is there a way to call the DDL statements below after I invoke the package 'triggered error '? In the Sub statement control does not go to the DDL statements, please notify

    EXCEPTION WHEN OTHERS THEN

    retval: = 1;

    RAISE_APPLICATION_ERROR (-20003, SQLERRM);

    RUN IMMEDIATELY 'ALTER TABLE CUSTOMER_LOAN_XREF ENABLE CONSTRAINT FK_CUSTOMER_LOAN_XREF_CUSTOMER;

    RUN IMMEDIATELY 'ALTER TABLE CUSTOMER_LOAN_XREF ENABLE CONSTRAINT FK_CUSTOMER_LOAN_XREF_LOAN;

    Thank you

    Ariean wrote:

    That would create an implicit validation of my transaction I want to avoid, please correct me if I'm wrong. Thank you

    For example, to create a procedure with pragma autonomous_transaction with

    RUN IMMEDIATELY 'ALTER TABLE CUSTOMER_LOAN_XREF ENABLE CONSTRAINT FK_CUSTOMER_LOAN_XREF_CUSTOMER;

    RUN IMMEDIATELY 'ALTER TABLE CUSTOMER_LOAN_XREF ENABLE CONSTRAINT FK_CUSTOMER_LOAN_XREF_LOAN;

    SY.

  • Lock the package

    Hi all

    I can't compile my package because of a lock held on it. Let me give the details for clarity.
    select * from dba_ddl_locks where session_id=111 and owner='RAHUL';
    
    session_id  owner       name                type                           mode_held         mode_requested
    111           RAHUL     RAHUL_PKG        BODY                          NULL              None
    111           RAHUL     RAHUL_PKG     Table/Procedure/Type      NULL              None
    The details of the session of the 111 session id is as below
    select sid,serial#,user#,username,command,status,process,sql_exec_start from v$session where sid=122
    
    
     sid          serial#          user#                   username                     command                             status                     process      SQL_EXEC_START 
    111          3558             222                         RAHUL                      47                                   KILLED                   4420            13-DEC-12 02.00.00 AM
    Strange is that we tried to kill this session and State above «KILLED» of the same shows, the dba_ddl_locks stilll shows the details of the lock on the RAHUL_PKG package and we are unable to compile the package (the locking session runs from December 13, 2012) and we are unable to kill. Also, is that if I run a package that refers to another package, then we used to be able to compile the package referenced until and unless the dependent package has finished running?


    Thank you

    Published by: Rahul K on February 13, 2013 22:59

    The command "+ alter system kill session +" does not end the session - he asked the session to terminate (probably through a structure of the IPC in the LMS).

    The session must be able to read this request to kill - and end it. So instead of killing the process, this cette commande command looks more like a request for suicide.

    In some cases the session itself is waiting on a call (call blocking / synchronous). Which means that he cannot just see this request to kill. In this case, the session is shown as killed, but still running, the database.

    In such a case, we can kill the physical process (or thread on Windows) that killed session. And sometimes it's the only alternative when call blocking on which that session waits, is stuck and would never return control to the session.

    It is pretty safe to kill the (correct) physical process/thread in this way. Oracle is pretty robust in this respect - and has its own threads/processes of internal management which will detect that you have removed physically the session and will clean up after him.

  • I'm unable to download apps from creative cloud to my MacBook Pro.  I downloaded the package install twice.  I can double click on the installer and it seems to be downloading, but it just guard spinning for 10-15 minutes, then gives me an error and a pro

    ??? I'm unable to download apps from creative cloud to my MacBook Pro.  I downloaded the package install twice.  I can double click on the installer and it seems to be loading but it just guard spinning for 10-15 minutes, then gives me an error and a blue button to get help.  We have other MacBook Pro in the studio and just downloaded quickly.  Any ideas?

    Hello

    Run Adobe Cleaner tool - https://helpx.adobe.com/creative-cloud/kb/cc-cleaner-tool-installation-problems.html

    Download creative cloud of Download Adobe Creative Cloud apps | Adobe Creative Cloud free trial

    If this does not help then follow the steps mentioned below.

    1. Access \User\\Library\Application Support\Adobe *

    And/Library/Application Support / Adobe *.

    To access the hidden user library folder, see library user access hidden files. Mac OS 10.7 and later.

    1. Find and delete the files AAMUpdater and OOBE
    2. / Library/Application Support/Adobe (rename Adobe Application Manager and Adobe of joint office)
    3. Go > utilities > (rename Adobe Application Manager and creative cloud)
    4. Download Creative cloud-apps Download Adobe Creative Cloud | Adobe Creative Cloud free trial

    Let us know if this will help.

  • I bought creative photography cloud and I managed to install Lightroom, but I am unable to install Photoshop (which must be included in the package) - the question is that, in the creative menu cloud app PS is always the trial version (which will be ex

    I bought creative photography cloud and I managed to install Lightroom, but I am unable to install Photoshop (which must be included in the package) - the problem is that in the creative menu cloud soft PS is always the trial version (which ends in 3 days) and the only option is to click on the 'buy now '. How can I download the full version of PS cc?

    Hi filippof9777091

    Please try the following steps to resolve this problem:

    1. Rename the folder SLCache in SLCacheold, present at the following location:

    Windows: C:\Program Files (x 86) \Common Files\Adobe

    Mac: System/Library/Application Support / Adobe

    2. Rename SLStore file toSLStoreold, present at the following location:

    Windows: C:\ProgramData\Adobe

    Mac: System/Library/Application Support / Adobe

    3 Rename the OOBE OOBEOLD folder

    Windows : C:\Users\User name\AppData\Local\Adobe

    MAC: ~/Library/Application Support/Adobe

    Later, please try: connect and disconnect activate Cloud Creative applications

    Kind regards

    Rahul

  • Unable to set the name of the package

    Hello world!

    A few weeks ago, I wore my application of enyo webOS, ReadOnTouch PRO, for the BlackBerry Playbook via APK Android converter. But I had some problems with this version and approval when denied. So I decided it's better to go with native WebWorks rather than convert good APK walked, because I do not plan to publish my app for Android. So, I changed my code to make it work with WebWorks and everything works fine in the Playbook Simulator. So far so good.

    After the signature of my app and uploading it to the provider portal, I have the following message:

    File bundle (rot.bar) was rejected. Package ID is required for all .bar file. If this is an upgrade, ID of Package must match ID of Package in the bundle of original file.

    I already googled and searched on this forum, so I've read (and I thought if I understand) this link: http://devblog.blackberry.com/2012/03/package-id-rejected-by-app-world/

    I always use the same keys, as with the old version of android, but when I look at the two generated MANIFEST. MF files, they differ in the package name (and package-id). Is it possible to change my current name of package to the former? The old name of the package is com.svenziegler.readontouch.android, but when I try to name my zip file (I work with the WebWorks SDK on the command-line, mac os) for that name then bbwp fails to sign the application due to an invalid application name. I also read that the name of the zip file should not exceed 10 characters... So, I don't really have a clue what can or should I do?

    Another question: the version number in my new config.xml (no not just with the android version) are the same, as the old version of the Android manifest?

    Can someone help me please? It would be great!

    See you soon,.

    Sven

    Hello Sven,

    In your config.xml file WebWorks file must be a element. If you plug your old application name it and repackage the application (and sign with the same keys), then this may be enough to build the same Package ID. However, this will make your application name (as shown on devices) long enough.

    My recommendation, if you do not have the attachments to the application of App World you already have (i.e. it was did not for sale yet) then it would be probably easier just to create a presentation that is completely new to build your WebWorks. If you want to reuse the same name, you can change the name of the existing product to something else.

    The version number should not affect the overall Package ID. It only should be based on the Application name and the keys to sign the application for code signing.

    Let me know how it goes.

    Erik Oros

    BlackBerry Development Advisor

  • BlackBerry App world & Marmalade - unable to update the application due to the incompatibility of the Package Id

    When you try to submit an upgrade of my existing BlackBerry PlayBook application, my .bar file is rejected due to incompatibility of package-id.

    I looked at the content of the folder bar and compared it to the original version that I presented. Indeed, the package Id has changed.

    What has not changed, it is the id of the application signing certificate or id of the author. The original was presented with marmalade version 6.1, and was built with marmalade version 6.2.

    Any idea on what is causing this discrepancy? Y at - there no fix for this other that screw up my existing version and from new BlackBerry App World? I really want to do because my clients lead are no longer updated.

    In fact, I finally could get an it again. I run the tool for configuring Jam once more, then updated the packages of Marmalade by running the .mkb file. After these two steps, my release was accepted as being compatible with my previous version.

    Thanks for the work around to the subject of manually update the configuration file. I'll take advantage of that in the future if need be.

  • Unable to show the Step property in package ODI

    Hello

    I use ODI 11.1.1.7 x 64... everything works fine, but when creating packages... .i can add interface in there but can not see anything in the property inspector set. In all other Windows Inspector works very well except the package.

    I use Java instead of 1.6 1.7. Is it related to java

    Anyone faced similar problems?

    Thank you

    Step in a package properties do not appear in the property inspector. Rather is displayed in the lower part of the diagram editor itself. I think that if you maximize the editor package, you will see the properties panel in the lower part of the diagram Panel.

    Thank you

  • "Unable to copy the related files needed" when you try to package files

    I try to files in the package for a client and I get the message "cannot copy the related files needed. Nothing shows as missing or inaccurate.  Someone else encountered this?

    The InBooklet plugin has nothing to do with the links or packaging - it was the old tool tax inside the code. I think it's a red herring, and you really need check the names of folders and files for think like slashes and asterisks.

    What version of InDesing. do you currently use and what OS?

  • Satellite P755-103 - cannot install the package of added value

    Hello

    I recently bought a Satellite P755-103. In order to maintain the updated drivers, I downloaded Toshiba Value Package added to the downloads section of the page Web of Toshiba. (2 times, I'm sure that the driver is for my 64-bit version of Windows 7).
    When I tried to install it, I got the repair and the options remove. Repair gave me this error: RegDBGetItem failed (1). So I removed completely the driver so that I can install it again. During the installation of the driver that I got the same error, so I couldn't install it, so now I'm unable to activate the shortcut keys PVAT gives me access.

    If anyone knows something that might help with this problem please say something, it would be very apreciated.
    Sorry for my English.

    Thank you

    Hello

    Value added package is still listed in the list of Windows software? If so, I would recommend removing it. Then restart your computer and try to reinstall the VAP.

    If it doesn t work I would try CCleaner. That is a nice freeware tool to clean the registry. You can find the tool using Google. Just run the registry cleaner and then you should be able to install VAP.

    Generally speaking, it s is not necessary to update the drivers if everything is ok. If you n t have any problems you can forget about these updates. ;)

  • The system is unable to complete the update of security for Windows XP (KB2661637).

    Original title: update security for Windows XP (KB2661637)

    The system is unable to complete the update of security for Windows XP (KB2661637).  How can I get my system to accept the update?

    Hi Joseph,.

    You receive messages or error codes?

    You can reset the default Windows Update components and check if you can install the update.

    How to reset the Windows Update components?

    You can also try to download the standalone update package and check.

    Update security for Windows XP (KB2661637)

  • Unable to get the upgrade to Windows 7 purchased to start

    I bought an upgrade to a provider. I have acquired a product key. I invoke Windows Anytime Upgrade according to the directions and the only option is to upgrade to Vista. Then I went to the Microsoft page to buy the product. I have Vista 64-bit with all updates installed on my Toshibe Satellite computer. I ran the Upgrade Advisor and everything was satisfactory.

    Unable to get the upgrade to Windows 7 purchased to start

    I call Windows Anytime Upgrade according to the guidelines

    I have Vista 64-bit

    Windows 7 anytime upgrade: you have Vista or XP currently installed?

    If the product you have Windows 7 'Anytime Upgrade' does not allow to move from XP/Vista to Windows 7. You can buy the product at retail of Windows 7 Upgrade not the ' Anytime Upgrade '.

    Windows 7 'Anytime Upgrade' is for moving from one version of Windows 7 to a higher version, such as Windows 7 Home Premium to Windows 7 Professional.

    You can buy Windows 7 here:

    http://www.microsoftstore.com/store/msstore/cat/CategoryID.44066700

  • Unable to update the firmware in Mezz KX4 - KR DP 10 GbE Ethernet X 520 14.5.9 version

    Hello

    Try to update Intel x 520 10GbE mezzanine NIC firmware on a blade of M620 fails with the following error:

    SUP0517: Unable to update the firmware in Mezz KX4 - KR DP 10 GbE Ethernet X 520 version 14.5.9.
    Detailed description:
    The image of the firmware specified in the operation did not properly apply. An internal error occurred.
    Recommended action:
    Try the operation again. If the problem persists, download the latest update of your service provider package and try the operation again.

    BIOS, iDRAC, Lifecycle Controller firmwares are newer. I tried to upgrade from iDRAC and directly from controller (using SUU) life cycle, the same thing. haven't tried yet the OS. I want to update firmware, because she refuses to get DHCP address when you try to boot from PXE to deploy the operating system. At the same time in the controller of lifecycle, in the configuration of the network, I was able to successfully get the addresses of the DHCP server and scan the Dell FTP site for firmware updates.

    Any ideas? Thank you.

    Egils

    I would like to start the update of the direct OMSA. Once updated, this should not happen again.

  • Today I imported recently an android project in my workspace in eclipse android 4.2.2 then when I run the application it is show Eroor: unable to solve the target 'unknown target problem Android android-7 "tru."

    Eclipse SDK

    Version: 4.2.2
    Build id: M20130204-1200

    When I right click on the app and clcik as run as application Android Iam see following errors: -.

    The path location type Resource Description
    Is only permitted to line /tru system AndroidManifest.xml 20 problem with lint Android apps

    The path location type Resource Description
    Is only permitted to line /tru system AndroidManifest.xml 20 problem with lint Android apps

    The path location type Resource Description
    Unable to solve the target 'unknown target problem Android android-7 "tru."

     

    including AndroidManifest.xml is as below:

     

     


    http://schemas.Android.com/APK/RES/Android ".
    package = "com. Tru.
    Android: versionName = "3.47" android: versionCode = "073434" >



    Android: largeScreens = "true".
    Android: anyDensity = "true" / >





    Error: it is only allowed to the system applications

     

     

    A number of permissions of the Android app is not supported. The impact of these unsupported features varies.

    Visit this link and check the authorization of any authorized all in porting the app... If the permissions that your application requires in the right list you might need to make some changes in your application

    https://developer.BlackBerry.com/PlayBook/Android/apisupport/unsupportedapi_playbook_app_permissions...

Maybe you are looking for