How to avoid the ORA-01722 in Collection queries?

I'm in the middle of 11 g migration of 12 c and reproduciple face ORA-01722: virheellinen (invalid number) errors with selects for existing collections.

Never paid any attention to it, but good to know that this can happen.

So it's potentially get ORA-01722 invalid number

select to_number(coll.c007) c007
  from my,apex_collections coll
 where 
      my.id                 =  coll.n002  -- my_id
  and coll.collection_name = 'TUNE_COLL'
  and to_number(coll.c007) = 1  -- first level 

While this isn't:

select to_number(c007) FROM (
select c007
from my,apex_collections coll
where 
      my.id                 =  coll.n002  -- my_id
  and coll.collection_name = 'TUNE_COLL'
--  and to_number(coll.c007) = 1  -- first level
) where  to_number(c007) = 1  -- first level

What is nasty, it's that the responsibe 25 pages of theme with parts of report gets berzerk when error messages between and so on.

I read the following articles, and it really seems that it comes and goes...

Robert Schaefer's blog: Spooky "ORA-01722: invalid number" errors when using the collections of the Apex

http://deneskubicek.blogspot.fi/2013/03/Apex-collections-and-joins.html

But did not find any quick way to resolve all queries on collections. Somehow, this seems to be because I exceeds the number of columns n001-005 and start using vc c001... columns for numbers.

So what is the best alternative to doing things?

1.) divide collections a number c001... so that the numbers will always n001 numbers...   (it is a time consuming task)

2.) extra make selects select collection... is it enough to convert vc/characters to numbers.

3.) or in any another cool tip - are there for example views on collections?

Paavo /rgrds

Paavo wrote:

The error comes randomly, and maybe it has something to do with the existing 'temporary' collections already.

They may have something extraordinary in c007 which cannot be to_numbered with different collection_name.

It has developed before, and this is indeed the cause. The optimizer apply predicates in a different order than that was used earlier. That is, instead of limiting the lines of the collection by the name of the collection to the collection of TUNE_COLL first, then filtering by the value converted C007, she asks C007 firstly, clause that straightens to lines of collections where C007 value can not be converted to a number. This tends to occur during or after the SUMMIT or base data at level, as in this case.

The fix is beef - cross selects all collections and difficulty where the conditions so that they appear only at specific collection_name?

Surely it is necessary on all access collection still? And as explained above, it will not necessarily solve the problem, because the optimizer can change the execution plan and apply predicates in any order.

Why you have exceeded the n001-n005 number of columns? What values are held in these? Preferably, I would suggest using these columns to store digital keys that are used in joins, values put numerical values only referenced in query projections in the columns of characters c001-c050 (and of course to do the same for date values). Then, you can create a view of the collection which explicitly converts values of the column returned to numbers or dates. Using views on top of collections, it is good practice in any case because it allows explicit column names to use in queries rather than a lot of impenetrable n00x and c0xx, which avoids thinking sitting developers "which column is now the postal code?

Tags: Database

Similar Questions

  • How to avoid the ORA-25188

    Hi all

    I am importing of tables using impdp.
    I truncated the existing tables so don't not to remove existing constraints.
    I want to say-able all constraints so that the children tables will not get a FK constraint error.
    But I came across this ORA 25188:
    SQL> ALTER TABLE OFFCYC_BGEN_K disable constraint XT367P0;
    ALTER TABLE OFFCYC_BGEN_K disable constraint XT367P0
    *
    ERROR at line 1:
    ORA-25188: cannot drop/disable/defer the primary key constraint for 
    index-organized tables or sorted hash cluster 
    Or I just ignore it because it will not affect the loading? for the FK errors.

    Help, please...

    Thank you very much

    Primary key is necessary for the ITO so to do, the answer would be that it will not be removable IMO.

    Aman...

  • Satellite Pro 4200 how to avoid the mistakes of the ACPI

    Satellite Pro 4200 how to avoid the ACPI errors after installing SP2 for windows XP Prof
    The problem is that my computer after installation service Pack 2 need about 15 minutes from time of shoutdown - what should I do to avoid this problem.
    Piotr Plecke

    Hello
    in this case it would be interesting what Type of laptop it is exactly.

    You will find this model on the bottom of your laptop. There is a review of it.

    Some models have a Bios update available, others not, for example.

    Please send additional information!

    Good bye

  • Camileo S10 - how to avoid the 'information' during video playback on TV

    I just received my Camileo S10... very nice indeed... but how to avoid the track and reading data to be shown on the screen during playback on my TV...?

    Go to the movies, then before you start playing click the OK button. This also works when you save. You must do this before playing or recording.

  • How to avoid the launch of Labview VI when he invokes in Teststand environment?

    Hi, friends.

    I am a student of teststand. I wrote a few screws by Labview. Now, I want to invoke in teststand environment.

    But when I run the sequence. LabVIEW automatically launches.

    How to avoid the launch of Labview when I run the sequence?

    Thank you.

    LabVIEW programs require a runtime engine. Under the TestStand configuration drop-down, select adapters. You can change the LabVIEW adapter to select the runtime rather than the development system.

    This should prevent the main screen of LabVIEW to appear, but you will not be able to change your LabVIEW VIs while they run of TestStand using the runtime engine.

  • How to avoid the launch of Labview when called by Teststand VI

    Hi, friends.

    I am a student of teststand. I wrote a few screws by Labview. Now, I want to invoke in teststand environment. But when I run the sequence. LabVIEW automatically launches. How to avoid the launch of Labview when I run the sequence?

    Thank you.

    I'm not sure that I follow what you're saying...  But it seems that when the VI is called, the LabVIEW Development software is started and you want to avoid this.

    If you create an executable file or a dll and that any call within TestStand, she should not call the development environment.  You must have the LabVIEW runtime engine installed on the target computer.

    For several years I used TestStand with LV, if my memory does not have to be precise.  I think that the above worked for me.  However, it seems that I remember something to have the LV code in debug mode, causing to open development environment... but it's a distant memory.    You do not use breakpoints where the LV VI is called, are you?

    R

  • How to avoid the minimizin of the screen when the user down ups slide

    How to avoid the minimizin of the screen when the user ups the down slide.

    Hello

    I guess that not possible because this is a feature of the system. Be able to substitute the blow to the gesture of bottom up would mean for combat when a user can switch to another application. It is not something that an application must be able to do it at all.

  • How to avoid the string * empty * on new pushScreen

    Someone knows how to avoid the string * empty * coming on each press of the screen and instead * void * can I have my own channel at the same place... Please let me know its possible or not...

    Thank you

    read the API:

    http://www.BlackBerry.com/developers/docs/4.7.0api/NET/rim/device/API/UI/component/ListField.html#se... (java.lang.String, int)

  • How to avoid the color address IOS in email HTML Template?

    Hello

    How to avoid the color address IOS in email HTML Template?

    Thank you

    Rahul Bhambri

    Hello Rahul,

    Please use css in your style sheet

    a {[x-Apple - detectors of data]

    color: inherit! important;

    text-decoration: none! important;

    font size: inherit! important;

    Police-family: inherit! important;

    Police-weight: inherit! important;

    line-height: inherit! important;

    }

    Thank you

    edynamic expert Eloqua

  • How to avoid the report query needs a unique key to identify each line

    Hello

    How to avoid the error below

    The report query needs a unique key to identify each row. The supplied key cannot be used for this query. Please change the report attributes to define a unique key column.

    I have master-detail tables but without constraints, when I created a query as dept, emp table he gave me above the error.

    Select d.deptno, e.ename

    by d, e emp dept

    where e.deptno = d.deptno

    Thank you and best regards,

    Ashish

    Hi mickael,.

    Work on interactive report?

    You must set the column link (in the attributes report) to something other than "link to display single line." You can set it to 'Exclude the column link' or 'target link to Custom.

  • Question CP9: HTML5: Apple: Android: how to avoid the click on the Play button / tap?

    Hello

    Captivate 9.0.0.223: HTML5 draft.

    I'm sorry to ask this question, it's a little old chestnut on HTML5 in Apple iOS and Android.

    I have searched on the internet and forums for a solution underway, but could not find something that works.

    The problem is how to avoid the PLAY button, which forces the user to click / tap on it, when the project is accessible on an Apple or Android system.

    Play_icon.png

    The project will be published on the internet for use on any Windows, Apple or Android device.

    I have no control over the Web server or devices that will use the people, so that any changes to the software server or browser is out of the question.

    I have tried both a plain HTML5 and a responsive project, but neither avoid the Play button. I put an example of 1 slide on these links.

    http://www.hoffits.com/test_responsive/index.html

    http://www.hoffits.com/test_html5/index.html

    The bottom line is: ' is it possible to remove the need for the user to click / press the Play button?

    Thank you.

    Peter

    Cardiff

    In Wales

    UK

    In your normal HTML5, there is a line (I think it's 46) with this code:

    CP. DoCPInit();

    Add cp.movie.play (); Located below.

    so:

    CP. DoCPInit();

    CP. Movie.Play ();

  • How to avoid the glossy look and brilliant nostrils?

    I just built my first character of fuse and when I import into Photoshop, its nostrils are incandescent - as if the light shines through the back of his head!

    This fuse:

    Screen Shot 2016-01-17 at 04.27.53.png

    Becomes this in Photoshop:

    Screen Shot 2016-01-17 at 04.47.21.png

    I use a brush to set the nostrils, but have no idea how fix eye - of the suggestions?

    Even better - any ideas on how to avoid the glossy look and glowing nostrils?

    Thank you very much
    Malcolm

    Hey, Malcolm.

    Best way to explain what basically rendering 3D correctly really takes a lot of time, haha.  So that you may be able to work with the real-time 3D model and make changes quickly, we use two different rendering methods.

    There is an "Interactive" mode which is not like the beautiful light/shade, but is very fast - and that's what you see when you interact with the default template.

    Then, there is a mode "Raytraced" which is much more advanced calculations and stuff to give you a proper lighting / shadow.  Raytraced rendered may take time if so we can not use it all the time.

    In order to get the lights/shadows appropriate you need to perform a path Ray would make on the document.  Best way to do this:

    • Select your 3D layer in the layers panel
    • Make a selection in the drawing area to the area that you want to make (I recommend to test rendering of area to check the lighting/shadows before committing to make the whole layer).
    • Push the button is rendered at the bottom of the properties panel (it looks like a cube in a rectangle box, right next to the delete icon).

    There are other things that you must do if you want to get the best image search quality such as the addition of secondary lights!  You can add more lights in the 3D Panel using the small icon of light at the bottom.  Have 2-3 stage lights and adjusting their colors can make a big difference with the Assembly of your character in the scene.  Here is a small image for some comparisons:

    You can see the image with two lights a look much more realistic lighting and shadows and raytraced of one and two versions are much nicer and cleaner!

    Hope that helps!

  • How to avoid the FDM-command being moved files from the OpenBatch folder

    Hello world

    I have a little problem with Batch Processing of the FDM - I need to stop the movement of files in the folder OpenBatch - when a batch is executed.

    The installer by using the Task Manager, a load a Batch Script and Script integration all works very well. However, the process must run every 3 hours, so I need the file "A_LedgerTransLocation_Actual_nov - 2013_RR.txt" to remain in the \Inbox\Batches\OpenBatch\ folder at any time.

    How to avoid the file is moved?


    Best regards
    Frederik




    PS: I noticed on the OTN Forum is it may be possible to script a solution such as:

    FSO1 = CreateObject ("Scripting.FileSystemObject") set
    Set File1 = FSO1. GetFile ("FDM Directory\FDM Application\Inbox\Batches\Openbatch\A_LedgerTransLocation_Actual_nov-2013_RR.txt")
    The BATCHENG value. PcolFiles = BATCHENG.fFileCollectionCreate (CStr (strDelimiter), File1)

    However this is not possible, as the controllers of the company need to edit the. TXT file themselves. They will not be able to edit the script too.

    I don't think you can prevent the FDM, move the file. I'm assuming that the file change in each period to use the last period of POV, so I think that option easiset to copy the file (based on a part of the name (location?) to a temporary location before began the FOM and write again later.)

  • How to avoid the link of a null value in a column of link

    Hello

    How to avoid the link of a column with the value zero. Is that the link should be disabled for the column with the value null, and it must be enabled for all that have a value.

    Ex

    DEPTNO NAME (link column)

    10 SCOTT
    20 MAC
    30 SMITH
    40         -
    50 SAM

    I don't want to link to the value null in the name column, but the name remaining should have link. Please help me.


    Kind regards
    Barro

    Hello

    One way is like this:
    1. create a column not displayed, called link_display in your report to return N or Y depending on whether you want the link by adding the SQL report:

        NVL2(name, 'Y', 'N') link_display 
    

    2. in the header of the region, define a class for the column name using:

    
    

    3. for the name column containing the link add link attributes: class = "" display_link_ #LINK_DISPLAY # ""

    Rod West

  • Re: How to avoid the password displayed in the Unix box APPS.

    Hello


    How to avoid the APPS password displayed in the Unix box using the command ps for concurrent program with the run method defined as 'host '.

    Kind regards.

    Salvation;

    What is the version of the EBS?

    Please see:
    Apps to hide password
    Hide the apps password

    Respect of
    HELIOS

Maybe you are looking for