Error in the Query used in APEX_COLLECTION.CREATE_COLLECTION_FROM_QUERY_B
Dear All,
I am using the following in a PL/SQL Before Header process.
Please help me with the following :
APEX_COLLECTION.CREATE_COLLECTION_FROM_QUERY_B ('LEASE', 'SELECT LSE_NUM
FROM RE_LEASE
WHERE LSE_COM_NUM = :P0_COM_NUM');I am getting the following error:
ORA-20104: create_collection_from_query_b Error:ORA-20104: create_collection_from_query ExecErr:ORA-01008: not all variables bound
If I change the above as
APEX_COLLECTION.CREATE_COLLECTION_FROM_QUERY_B ('LEASE', 'SELECT LSE_NUM
FROM RE_LEASE
WHERE LSE_COM_NUM = ' || :P0_COM_NUM);Then I get the following error :
ORA-20104: create_collection_from_query_b Error:ORA-20104: create_collection_from_query ParseErr:ORA-00936: missing expression
I am using the above to create Next and Previous buttons using the reference provided by ATD in the Re: How to do page break
Note: If I do not use any Items in the WHERE as below then I do not get any errors and it works as required.
APEX_COLLECTION.CREATE_COLLECTION_FROM_QUERY_B ('LEASE', 'SELECT LSE_NUM
FROM RE_LEASE');I want to use Items in the query for the collection. Please help.
Best Regards
Arif Khadas
Hi Jari,
Thanks Jari for the reply. Your solution does work as well but please if you can throw some more light on q'! (first line) and !' (last line).
q'!
SELECT LSE_NUM
FROM RE_LEASE
WHERE LSE_COM_NUM = (SELECT v('P0_COM_NUM') FROM DUAL)
!'Best Regards
Arif Khadas
Similar Messages
-
Error while accessing Query using Query Analyzer
dear experts...
while accesiing the query using query analayzer...
we are getting below error...
What has happened?
URL http://xxx.xxx.xxx.xx:XXXX/irj/servlet/prt/portal/prtroot/pcd!3aportal_content!2fcom.sap.pct!2fplatform_add_ons!2fcom.sap.ip.bi!2fiViews!2fcom.sap.ip.bi.bex call was terminated because the corresponding service is not available.
Note
The termination occurred in system BI1 with error code 404 and for the reason Not found.
The selected virtual host was 0 .
What can I do?
Please select a valid URL.
If you do not yet have a user ID, contact your system administrator.
ErrorCode:ICF-NF-http-c:001-u:ANAND-l:E-i:PSRCCPRDA003_BI1_00-v:0-s:404-r:Notfound
HTTP 404 - Not found
Your SAP Internet Communication Framework Team
thanks for helping me...
anandHi friends,,
instead of getting the link like
http://128.222.125.57:9000/sap/bw/bex?cmd=ldoc&infocube=ZMC_SRH1&query=AGINGV21A&sap-language=EN(working link)
am getting below link...which is getting an error....
http://128.222.125.57:9000/sap/bw/://:/irj/servlet/prt/portal/prtroot/pcd!3aportal_content!2fcom.sap.pct!2fplatform_add_ons!2fcom.sap.ip.bi!2fiViews!2fcom.sap.ip.bi.bex?QUERY=AGINGV21A
above marked is the unwanted thing so how can i change my link in query designer???
please suggest me firneds -
I have an package with source , data flow and destination to execute on begin and commit.
in the below i have just used for questioning purpose with diagram removing my Data Flow task explaining my problem
on execution, i get error as
[Execute SQL Task] Error: Executing the query "COMMIT TRAN DimCompanyCode" failed with the following error: "The COMMIT TRANSACTION request has no corresponding BEGIN TRANSACTION.". Possible failure reasons: Problems with the query, "ResultSet"
property not set correctly, parameters not set correctly, or connection not established correctly.
as mentioned , i have checked the ResultSet, parameters , connection establish.. all are fine.
Kindly advice on what has to be done.
ShanmugaRajTo avoid this error, the RetainSameConnection property should set to 'True' for the Connection Manager - Application_DB.
Narsimha -
Hi
DECLARE @XMLA nvarchar(3000)
, @DateSerial nvarchar(35);
-- Change date to format YYYYMMDDHHMMSS
SET @DateSerial = CAST(GETDATE() AS DATE);
--SELECT @DateSerial
Set @XMLA =
N' <Batch xmlns="http://schemas.microsoft.com/analysis services/2003/engine">
<ErrorConfiguration xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ddl2="http://schemas.microsoft.com/analysisservices/2003/engine/2"
xmlns:ddl2_2="http://schemas.microsoft.com/analysisservices/2003/engine/2/2" xmlns:ddl100_100="http://schemas.microsoft.com/analysisservices/2008/engine/100/100" xmlns:ddl200="http://schemas.microsoft.com/analysisservices/2010/engine/200"
xmlns:ddl200_200="http://schemas.microsoft.com/analysisservices/2010/engine/200/200">
<KeyErrorLimit>-1</KeyErrorLimit>
<KeyNotFound>IgnoreError</KeyNotFound>
<NullKeyNotAllowed>IgnoreError</NullKeyNotAllowed>
</ErrorConfiguration>
<Parallel>
<Process xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ddl2="http://schemas.microsoft.com/analysisservices/2003/engine/2" xmlns:ddl2_2="http://schemas.microsoft.com/analysisservices/2003/engine/2/2"
xmlns:ddl100_100="http://schemas.microsoft.com/analysisservices/2008/engine/100/100" xmlns:ddl200="http://schemas.microsoft.com/analysisservices/2010/engine/200" xmlns:ddl200_200="http://schemas.microsoft.com/analysisservices/2010/engine/200/200"
xmlns:ddl300="http://schemas.microsoft.com/analysisservices/2011/engine/300" xmlns:ddl300_300="http://schemas.microsoft.com/analysisservices/2011/engine/300/300">
<Object>
<DatabaseID>MultidimensionalProject5</DatabaseID>
<CubeID>giri</CubeID>
<MeasureGroupID>Fact Internet Sales</MeasureGroupID>
</Object>
<Type>ProcessFull</Type>
<WriteBackTableCreation>UseExisting</WriteBackTableCreation>
</Process>
</Parallel>
</Batch>';
EXEC (@XMLA) At SHALL-PCAdventureWorksDw ;
iam executive the query when iam getting below error.
[Execute SQL Task] Error: Executing the query "DECLARE
@XMLA nvarchar(3000)
, @DateSerial nvarch..." failed with the following error: "Incorrect syntax near '-'.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set
correctly, or connection not established correctly.
how to solve this error;
please help meWhat are you trying to do? What sort of data source is SHALL-PCAdventureWorksDw?
When you use EXEC() AT, I would execpt to see an SQL string to be passed to EXEC(), but you are passing an XML string????
If you explain why you think this would work in the first place, maybe we can help you.
Erland Sommarskog, SQL Server MVP, [email protected] -
Is there any way to get the query used in discoverer from backend??
Hi All,
I am new to dicoverer.
Is there any way to get the query used in discoverer from backend??
Thanks,
SachinHi,
you can view the SQL from within the discoverer menu:
in desktop: View-> SQL Inspector
in Plus: Tools-> Show SQL
The SQL in the DB tables is encrypted so it's a problem getting it from there.
You can export the workbook into SQL but it is not working for every worksheet (subquery, inline pivot tables...)
you can create a batch file to export them all using the output of this script:
select null,null,'echo off'
from dual
union all
select distinct
qs.qs_doc_name Workbook_name,
qs.qs_doc_details Worksheet_Name,
'start /wait <path>\dis51usr.exe /connect '||'&p_user_name'||'/'||'&p_password'||'@'||'&p_env'||' /apps_user /apps_responsibility "&responsibility" /opendb '||
chr(34)||qs.qs_doc_name||chr(34)||' /sheet "'||qs.qs_doc_details||'"'||' /export SQL "C:\Export Discoverer SQL\'||qs.qs_doc_name||'-'||qs.qs_doc_details||'.sql" /batch'
from eul_us.eul5_qpp_stats qs
where qs.qs_doc_name is not null
--order by 1,2
union all
select null,null,'echo off'
from dual
union all
select null,null,'exit'
from dual -
What is the standard format of the query used to bring bw report as iview ?
Please tell me the format of the query used to bring bw report into the portal when we have webtemplateid .
Koti ReddyHI,
It's well described in help,
for EP 6.0 and BW 3.5: http://help.sap.com/saphelp_nw04/helpdata/en/27/6c013a53271a05e10000000a11402f/frameset.htm
for EP 7.0 and BI 7.0 is more difficult, but You have a wizard:
http://help.sap.com/saphelp_nw2004s/helpdata/en/43/ef05462480025ae10000000a1553f7/frameset.htm
http://help.sap.com/saphelp_nw70/helpdata/en/33/39fa40ee14f26fe10000000a1550b0/frameset.htm
Regards,
Jarek -
How to write the query using Index
Hi All,
I have to fetch the records from Database table using Index, how can i write the query using Index. Can any body plz send me the sample code.
Help Me,
Balu.Hi,
See the below Example.
select * from vbak up to 100 rows
into table t_vbak
where vbeln > v_vbeln.
sort t_vbak by vbeln descending.
read table t_vbak index 1.
Regards,
Ram
Pls reward points if helpful. -
create table my_employee
(id number(4)primary key,
last_name varchar2(25),
first_name varchar2(25),
userid varchar2(8),
salary number(9,2)
I want to write an INSERT statement to MY_EMPLOYEE table . Concatenate the first letter of the first name and first seven characters of the last name to produce user ID using a single sql statement
I wrote the query like this and i am getting logical error
insert into my_employee
values(&id,'&last_name','&first_name',substr('&&first_name',1,1)||substr('&last_name',1,7),&salary);
SQL> insert into my_employee
2 values(&id,'&last_name','&first_name',substr('&&first_name',1,1)||substr('&last_name',1,7),&sal
ary);
Enter value for id: 20
Enter value for last_name: popopopp
Enter value for last_name: qwertyyuu
Enter value for salary: 300000
old 2: values(&id,'&last_name','&first_name',substr('&&first_name',1,1)||substr('&last_name',1,7),
new 2: values(20,'popopopp','o',substr('o',1,1)||substr('qwertyyuu',1,7),300000)
1 row created.
it is asking the last_name two timesyou can do it with a .sql script
c:\my_emp.sql
PROMPT
PROMPT instering my_employees
PROMPT
ACCEPT ID NUMBER PROMPT 'ID ? : '
ACCEPT FIRST_NAME CHAR PROMPT 'FIRST_NAME ?: '
ACCEPT LAST_NAME CHAR PROMPT 'LAST_NAME ?: '
ACCEPT SALARY NUMBER PROMPT 'SALARY ? : '
insert into my_employee values(&id,'&last_name','&first_name',substr('&&first_name',1,1)||substr('&last_name',1,7),&salary);
SELECT * FROM my_employee where id=&&id;
and then from sqlplus @c:\my_emp.sql
scott@ORCL> @C:\MY_EMP
instering my_employees
ID ? : 20
FIRST_NAME ?: john
LAST_NAME ?: papas
SALARY ? : 1000
old 1: insert into my_employee values(&id,'&last_name','&first_name',substr('&&first_name',1,1)||substr('&last_name',1,7),&salary)
new 1: insert into my_employee values( 20,'papas','john',substr('john',1,1)||substr('papas',1,7), 1000)
1 row created.
old 1: SELECT * FROM my_employee where id=&&id
new 1: SELECT * FROM my_employee where id= 20
ID LAST_NAME FIRST_NAME USERID SALARY
20 papas john jpapas 1000
scott@ORCL> -
Error executing a query using VPD and BC4J
Hi all,
Our team is developing an application using an Oracle DB 9.2.0.4 and BC4J 10g (9.0.5.16.0) as persistence layer.
We also are using the VPD (virtual private database) to have security in the database at row level.
The problem we are facing is that every some time (days) we get a jdbc error when a query (see below) that uses VPD policies is executed. Once the error occurs I execute it from sqlplus without getting any error .. it only occurs from our java application.
To temporary solve this problem, we delete and recreate the VPD policies, then the application continue working fine for some time ...
I'll appreciate any comment / suggestions
Thank in advance.
Eduardo.
ERROR LOG:
oracle.jbo.SQLStmtException: JBO-27122: SQL error during statement preparation. Statement: SELECT * FROM (SELECT CalLocation.ID,
CalLocation.CODE, eo
CalLocation.NAME,
CalLocation.ZIP,
CalLocation.PHONE,
CalLocation.FAX,
CalLocation.ADDRESS1,
CalLocation.ADDRESS2,
CalLocation.URL,
CalLocation.OWNER,
CalLocation.CTY_ID,
CalLocation.DESCRIPTION,
ORefCity.CODE CTY_CODE,
ORefCountry.ID CTR_ID,
ORefCountry.CODE CTR_CODE,
ORefRegion.ID REG_ID,
ORefRegion.CODE REG_CODE
FROM CAL_LOCATIONS CalLocation,
OREF_CITIES ORefCity,
OREF_COUNTRIES ORefCountry,
OREF_REGIONS ORefRegion
WHERE ORefCity.ID = CalLocation.CTY_ID
and ORefCountry.ID = ORefCity.CTR_ID
and ORefRegion.ID = ORefCountry.REG_ID) QRSLT WHERE ( ( (CTY_ID = 867) ) )
## Detail 0 ##
java.sql.SQLException: Io exception: Broken pipe
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:189)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:231)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:345)
at oracle.jdbc.driver.OracleStatement.open(OracleStatement.java:717)
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:2605)
at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:457)
at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:387)The symptoms we have been getting are quite similar to the bug 3662364 .
I'm going to implement the patch for that bug and see what happend then.
Thank you very much for your help.
Regards,
Eduardo. -
Hello all,
I can't open a PP project without this error message appearing:
"The preset used by one or more sequences in this project requires third-party components that could not be located. These sequences will be modified to use a custom sequence setting instead. To continue editing using the original preset, quit the application without saving the project, reinstall any third-party components that are required and reopen the project".
What I had been doing before this occurred was editing a PP project using ProRes sequences and multi-camera editing. Multi-camera was not working very well and after a few attempts to fix that I gave up and finished the job cutting 3 layers of video instead. AME refused to render the three finished sequences of over 1hr duration so rendered final videos from the PP sequences.
I tried deleting plists for AME, PP and QT, repairing disc permissions and rebooting but there was no improvement.
Client is satisfied for now but will want to come back to this job at a later date so decided to uninstall and re-install AME and PP in the hope both would be ready to work properly when needed again. AME works fine in conjunction with a different PP project but now I can't open the PP project in question without the above error message appearing.
Having searched the net it would seem that the problem may be caused by ProRes but I haven't been able to find a definitive solution for the problem. Does anyone know either:
1. How to fix this?
2. If I chose the "modified using a custom sequence setting", can I be sure that my sequences will look the same even if they don't use ProRes? The final deliverable format will be mp4 so as long as the overall look doesn't change then I can afford a change in the edit codec. It's just that with three sequences over an hour long, I don't want days of work to be ruined.
Other older PP projects of mine open and work fine.
Premiere Pro CC 8.2.0
Media Encoder CC 8.2.0.54
OSX 10.10.2
Any help would be greatly appreciated.
Duncan.Adobe web chat come up with a solution.
Open the PP project.
Export your sequence or project as a Final Cut Pro XML file.
Set up a new PP project.
Import the Final Cut Pro XML file.
This will get you back up an running.
Since getting back to editing this project I have found that some things will be lost or change in using XML:
You will lose position key framing, black video clips, dissolve fx, audio levels, audio dynamic fx, the ability to open a multi camera clip and change the camera view.
You will keep cut points, crop fx.
Not perfect but only took a couple of hours to save 3 days work. -
Error executing the Query after deploying and executing the application in WLS 6.1 SP3
Hi,
We are trying to run a application by deploying a war file on Web Logic Server
6.1 SP3. After deploying and at the time of execution of the application, the
server console displays this error message
java.sql.SQLException: ORA-00600: internal error code, arguments: [ttcgcshnd-1],
[0], [], [], [], [], [], []
While debugging thru the application we found that this error comes at the time
of execution of the query thru the Statement.executeQuery method of java.sql.Statement
class.
This same application when deployed on Web Logic Server 8.1 runs perfectly, without
any hitches.
Please, provide me the solution to this asap.Look for sometime around November. No exact date.
Eric
"Dominic Tulley" <[email protected]> wrote in message
news:[email protected]..
Thanks Eric,
you know what I'm going to ask next right?
Any ideas when SP4 comes out?
Cheers,
-Dominic
"Eric Gross" <[email protected]> wrote in message
news:[email protected]..
The next version of Apache that we will support will be 2.0.42/2.0.43
and
the module for that will be included in the next Service Pack for6.1(SP4)
and 7.0(SP2).
The problem with Apache 2 is that when a new release comes out a newmodule
needs to be compiled. Most of the time. For 2.0.42/2.0.43 this is notthe
case.
Regards,
Eric
"Dominic Tulley" <[email protected]> wrote in
message
news:3da3f246$[email protected]..
I'm trying to set this up (initially just apache in front of a single
WLS
server but ultimately I want to put it in front of a cluster).
I've installed Apache 2.0.40.
I've copied the mod_wl_20.so file into the apache modules folder.
I've edited the httpd.conf file and added the line:
LoadModule weblogic_module modules/mod_wl_20.so
When I run apache -t to check the configuration I get the following:
C:\Program Files\Apache Group\Apache2\bin>apache -t
Syntax error on line 173 of C:/Program Files/Apache
Group/Apache2/conf/httpd.conf:
Cannot load C:/Program Files/Apache Group/Apache2/modules/mod_wl_20.sointo
server: The specified procedure could not be found.
So what's going on here?
Looking at previous postings it sounds like there's an issue with
versions
of apache after 2.0.39 but I can't find a download for that version.Also,
it sounded like the issues were for WLS 7, not 6.1. Can this work
with
2.0.40 or am I wasting my time?
If I get the mod_wl_20.so from dev2dev I get the "incompatible plugin"
message that has been mentioned in this group already.
Any suggestions appreciated,
-Dominic -
How to build dynamic query strings in the query using DB adapter 'Pure SQL'
Dear Forum,
I am building an application which will access DB to fetch some result set. The query involves retrieving data from multiple tables(nearly 10 tables). So I have created a DB adapter using 'execute pure sql' option. With this query works fine, but my inputs parameters will vary. So I need to make my query dynamic to append the query strings at runtime depending on the inputs.
For example I have 3 input variables - input1,input2 and input3 (in my request xsd) which are used in the pure sql query. Now if I get a 4th input parameter input4 in the request, I need to append this to query string as 'AND input4=[some value]' at runtime. Otherwise my query should have only 3 parameters. Please suggest how this can be achieved.
Regards,
Satya.This is a strange requirement, depending on the columns you have and what are optional in them, one way is to have separate operations and each opeartion will have different inputs and for each operation , a different DB Adapter is called. But this way, it results in more number of operations for the service as well as more number of references in the composite. Even if you pass the column inputs to the SQL procedure, it will result in a large number of if-else cases..
Thanks,
N -
Dear All,
Please tell me syntax error in the below query. When I'm going to write numeric number in this filed "$[ OVPM.DocNUm ]". It's working fine. But when I'm writing this it give me error.Please clear me where am wrong????I
SELECT T0.[AcctNum] FROM VPM1 T0 WHERE T0.[DocNum] =$ [OVPM.DocNUm ]
Regards
Edited by: Anwar Ali Sohail on Sep 27, 2011 11:43 AMHI
Try This
SELECT T0.[CheckNum] FROM VPM1 T0 INNER JOIN OVPM T1 ON T0.DocNum = T1.DocEntry WHERE T0.[DocNum] = $[OVPM.DocNum]
OR
SELECT T0.[AcctNum] FROM VPM1 T0 INNER JOIN OVPM T1 ON T0.DocNum = T1.DocEntry WHERE T0.[DocNum] = $[OVPM.DocNum]
Edited by: kambadasan on Sep 27, 2011 4:26 PM -
Programmatically change the query used to generate Oracle Reports
I have two queries. Depending on some parameter value, I would like to use one of these queries to generate my report. Is it possible to programmatically change the SQL query used to generate the Oracle Report.
ThanksThere are two options:
- The easy way
In the report paper layout create two frames, one for each query , and at runtime
display only one based on your parameters. (using format triggers on the frames)
- the not so easy way (but more elegant)
create the query at runtime using xml customizations using the examples from
the following documentation:
http://download-
uk.oracle.com/docs/cd/B14099_17/bi.1012/b14048/pbr_xml.htm#i1006734
16.3 Creating XML Data Models
16.4.1.3 Applying an XML Report Definition in PL/SQL
16.4.1.3.2 Applying an XML Definition Stored in Memory
Regards and Good Luck
Ionut S -
Hide an error from the application using a servererror trigger?
We have an application designed for an old oracle version which issues some sql which is no more supported in todays database version.
We want to use the application unchanged with a new database server.
Old Server Version: 7.3.4 (still in production...)
New Server Version: 10.2 or 11.2
The application issues an
ALTER SESSION SET OPTIMIZER_GOAL = FIRST_ROWS ;
which results in ORA-01986 and the application dies.
We would like to hide the error 01986 from the application using a trigger:
create or replace
trigger catch01986
after servererror
on schema
begin
if (ora_is_servererror (1986)) then
null; -- what to do here? we want clear the ora-01986 from the error stack
end if;
end catch01986;How to handle the error, so that the alter session set ... statement is just ignored and no error code is returned to the application?
I asked already some days ago in Database-General Forum, but triggers belong to PL/SQL, so i repost here.
Tnx for help in advance!Hi,
hoek wrote:
A totally weird and untested (and unable to test today) thought:
http://technology.amis.nl/blog/447/how-to-drive-your-colleagues-nuts-dbms_advanced_rewrite-oracle-10g
Very interesting for real dirty solution.
Does not work for my problem, DBMS_ADVANCED_REWRITE works only for select statements.
BEGIN
SYS.DBMS_ADVANCED_REWRITE.DECLARE_REWRITE_EQUIVALENCE (
'alter_session_equivalence',
'ALTER SESSION SET OPTIMIZER_GOAL = FIRST_ROWS',
'ALTER SESSION SET OPTIMIZER_MODE = RULE',
FALSE);
END;
ORA-30389: the source statement is not compatible with the destination statement
ORA-00903: invalid table name
ORA-06512: at "SYS.DBMS_ADVANCED_REWRITE", line 29
ORA-06512: at "SYS.DBMS_ADVANCED_REWRITE", line 185
ORA-06512: at line 2
30389. 00000 - "the source statement is not compatible with the destination statement"
*Cause: The SELECT clause of the source statement is not compatible with
the SELECT clause of the destination statement
*Action: Verify both SELECT clauses are compatible with each other such as
numbers of SELECT list items are the same and the datatype for
each SELECT list item is compatible
hoek wrote:You already had some trigger code, catching the error and sending it to null, why didn't that work?The trigger is fired when the error occurs, but after completion of the trigger, the error code is still delivered to the client.
I dont know how to handle the error within the trigger.
Does the client read the error stack and does it die after reading an error from the stack?The client just checks the error code. On error it terminates.
With the SERVERERROR TRIGGER i did the following tests:
Test 1: trigger does nothing
CREATE OR REPLACE
TRIGGER CATCH01986
AFTER SERVERERROR
ON SCHEMA
BEGIN
IF (ORA_IS_SERVERERROR (1986)) THEN
NULL;
END IF;
END CATCH01986;
ALTER SESSION SET OPTIMIZER_GOAL = FIRST_ROWS;
ORA-01986: OPTIMIZER_GOAL is obsolete
01986. 00000 - "OPTIMIZER_GOAL is obsolete"
*Cause: An obsolete parameter, OPTIMIZER_GOAL, was referenced.
*Action: Use the OPTIMIZER_MODE parameter.
-- Client Application reports errorcode 1986Test 2: Trigger raises NO_DATA_FOUND
CREATE OR REPLACE
TRIGGER CATCH01986
AFTER SERVERERROR
ON SCHEMA
BEGIN
IF (ORA_IS_SERVERERROR (1986)) THEN
RAISE NO_DATA_FOUND;
END IF;
END CATCH01986;
ALTER SESSION SET OPTIMIZER_GOAL = FIRST_ROWS;
ORA-04088: error during execution of trigger 'AH.CATCH01986'
ORA-01403: no data found
ORA-06512: at line 9
ORA-01986: OPTIMIZER_GOAL is obsolete
04088. 00000 - "error during execution of trigger '%s.%s'"
*Cause: A runtime error occurred during execution of a trigger.
*Action: Check the triggers which were involved in the operation.
-- Client Application reports errorcode 4088Test 3: Trigger raising an APPLICATION ERROR
CREATE OR REPLACE
TRIGGER CATCH01986
AFTER SERVERERROR
ON SCHEMA
BEGIN
IF (ORA_IS_SERVERERROR (1986)) THEN
DBMS_STANDARD.RAISE_APPLICATION_ERROR(-20999, 'this makes no sense', true);
END IF;
END CATCH01986;
ALTER SESSION SET OPTIMIZER_GOAL = FIRST_ROWS;
ORA-00604: error occurred at recursive SQL level 1
ORA-20999: this makes no sense
ORA-06512: at line 10
ORA-01986: OPTIMIZER_GOAL is obsolete
00604. 00000 - "error occurred at recursive SQL level %s"
*Cause: An error occurred while processing a recursive SQL statement
(a statement applying to internal dictionary tables).
*Action: If the situation described in the next error on the stack
can be corrected, do so; otherwise contact Oracle Support.
-- Client Application reports errorcode 604Test 4: Adding an EXCEPTION part to the trigger does not help, this will catch only exceptions raised while the trigger executes:
CREATE OR REPLACE
TRIGGER CATCH01986
AFTER SERVERERROR
ON SCHEMA
BEGIN
IF (ORA_IS_SERVERERROR (1986)) THEN
DBMS_STANDARD.RAISE_APPLICATION_ERROR(-20999, 'this makes no sense', true);
END IF;
EXCEPTION
WHEN OTHERS THEN
NULL;
END CATCH01986;
ALTER SESSION SET OPTIMIZER_GOAL = FIRST_ROWS;
ORA-01986: OPTIMIZER_GOAL is obsolete
01986. 00000 - "OPTIMIZER_GOAL is obsolete"
*Cause: An obsolete parameter, OPTIMIZER_GOAL, was referenced.
*Action: Use the OPTIMIZER_MODE parameter.
-- Client Application reports errorcode 1986So i do not know what to do inside the trigger to clean the error stack so that the client will receive no errorcode.
Maybe you are looking for
-
Missing and duplicate entries in the calendar
I'm a long time (1997) Palm user who's moved to a BB 8330 last month. I can't seem to get calendar syncing to work correctly. In some instances, I am missing items on Outlook. I often have duplicate entries on the handheld. I've searched the forums a
-
Hi everyone, Pretty new to SAP. I am struggling to find answers to the following questions: How do you use client 000, 001 and 066? Apart from initial installation and support (066) can theses clients be used in development, testing and production en
-
IConcertCal 2.2 -- HELP!
I recently downloaded iConcertCal 2.2, in short it *****. I don't want it. I deleted all the files I could find for it but it's till in the visualizer tabs in iTunes, and it's popping up stupid concert dates that I don't want when I'm switching songs
-
Perfmon report.html missing
Hello Guys, I've configured perfmon to run for an hour with the memory and cpu counters, Workflow, 1.The perfmon is scheduled to run from 10 to 11 GMT. 2.Once the run completes it calls a Scheduled Task "\MICROSOFT\WINDOWS\sendMail" and this script
-
Printers not recognised in Mac OSX 7.5
My Epson R1800 print drivers are not recognised in Print & Scan Preferences. I just can't print. I can't access any drivers. Don't understand what I am doing wrong. Everything was working OK and suddenly my printer went off line. I removed it from th