Home » SQL & PL/SQL » SQL & PL/SQL » package
package [message #661909] Wed, 05 April 2017 23:52 Go to next message
jay12
Messages: 2
Registered: April 2017
Junior Member
Can anyone go through following code and validate? it is getting compiled. But it is not working as expected.
Re: package [message #661910 is a reply to message #661909] Thu, 06 April 2017 00:29 Go to previous messageGo to next message
Michel Cadot
Messages: 65848
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

Can YOU go through this topic and feedback.

Please read OraFAQ Forum Guide and How to use [code] tags and make your code easier to read.
Also always post your Oracle version, with 4 decimals, as solution depends on it.

With any SQL or PL/SQL question, please, Post a working Test case: create statements for all objects so that we will be able work to reproduce what you have.
Use SQL*Plus and copy and paste your session, the WHOLE session.

Re: package [message #661925 is a reply to message #661909] Thu, 06 April 2017 02:38 Go to previous messageGo to next message
flyboy
Messages: 1856
Registered: November 2006
Senior Member
I have briefly gone through that code and I can confirm that it works as coded. Especially all those
EXCEPTION
  WHEN OTHERS THEN
    NULL;
"handlers" do exactly what they do - ignore whenever any statement inside that block fails due to any reason.

You may find more details in this article: http://www.orafaq.com/wiki/WHEN_OTHERS

If you expect that the code "handled" by "WHEN OTHERS THEN NULL" is arbitrary (it does not matter whether it was not executed), some other peace may be wrong. Hard to tell as you did not describe the "as expected" behaviour at all.
Re: package [message #661926 is a reply to message #661925] Thu, 06 April 2017 03:30 Go to previous message
cookiemonster
Messages: 13291
Registered: September 2008
Location: Rainy Manchester
Senior Member
You need to get rid of the when others as already mentioned.
Past that - do you really expect people who know nothing about your system generally, the purpose of this code specifically and who have their own jobs to do, to review 1200 lines of code looking for mistakes?

You need to debug it yourself to find out what's going on. If you find that a specific bit is misbehaving and you show us that bit and tell us what it's supposed to do and what it's currently doing then we can probably help.
Previous Topic: Split clob data and store in table
Next Topic: Avoid Distinct
Goto Forum:
  


Current Time: Sat Oct 20 23:20:58 CDT 2018