Runtime privelleges in plsql
Hi,
I am preparing for 1Z0-144. I have found a topic in it as "Control the run-time privileges of a subprogram".
I am not understading what this exactly mean.
Can anyone please tell me whart are the run-time privelleges of as subprogram in plsql.
Thanks,
Vinod
Don't be confused! See these
A privilege is a right to execute a particular type of SQL statement or to access another user's object. Some examples of privileges include the right to:
Connect to the database (create a session)
Create a table
Select rows from another user's table
Execute another user's stored procedure
There are two distinct categories of privileges:
System privileges
Schema object privileges
only!
Similar Messages
-
FILE NAMING IN RUNTIME in scheduler/plsql code in 102g. please help, thankU
Hi,
we have a scheduler job which calls/executes a stored procedure that generates a report file. however we need to give file name run at run time and need to copy it to shared folder. we do not want use any shell scripts here and like to complete this work with either PLSQL block or scheduler job. please suggest us how we can specify file name at each run time that differs hour wise.
the procedure code for example is: failure: not getting file name correctly
DECLARE
dtime VARCHAR2(11):=to_Char(sysdate,'YYYYMMDD_HH24');
F1 UTL_FILE.FILE_TYPE;
BEGIN
F1 := UTL_FILE.FOPEN('DIR_REPORTS','REP_''dtime''.txt','W',32767);
UTL_FILE.PUT_LINE(F1,' Data');
UTL_FILE.FFLUSH (F1);
UTL_FILE.NEW_LINE(F1);
end;
please give us your help on nameing file at runtime .. filename_yyyymmdd_hh24.txt.
thanks in advance.
/mrF1 := UTL_FILE.FOPEN('DIR_REPORTS','REP_'||dtime||'.txt','W',32767);
line giving
ORA-29283: invalid file operation
ORA-06512: at "SYS.UTL_FILE", line 475
ORA-29283: invalid file operation
ORA-06512: at line 5
errors. earlier i was able to generate files earlier but not with suggested change.. anything to be done more???
thank you .. please assist.. -
RPE-01008: Recovery of this request is in progress, while executing
While I am trying to execute a mapping I am getting the following error..RPE-01008: Recovery of this request is in progress... The deployment went fine, but execution throws this error. The log file looks like
2007/10/13-21:22:20-JST [1B8E059] Error creating the temp directory C:\OraHome_1/owb/temp
2007/10/13-21:22:22-JST [1B8E059] Free Memory(bytes)=738744 Total Memory(bytes)=2031616 Used Memory(bytes)=1292872 Used Memory(percent)=64%
2007/10/13-21:22:23-JST [1B8E059] Runtime Platform Service Version 10.2.0.2.8 starting
2007/10/13-21:22:23-JST [1B8E059] Client-side startup request
2007/10/13-21:22:23-JST [1B8E059] Platform Repository Name dwhownr on Service icgdwh at Host 10.109.65.67
2007/10/13-21:22:23-JST [1B8E059] Explicit garbage collection - every 1 execution(s)
2007/10/13-21:22:23-JST [1B8E059] Recovery starting
2007/10/13-21:22:23-JST [1B8E059] Recovering execution with audit ID 4109
2007/10/13-21:22:23-JST [1B8E059] Explicit garbage collection - requested
2007/10/13-21:22:23-JST [1B8E059] AuditId=4109: Processing execute request
2007/10/13-21:22:23-JST [1B8E059] Free Memory(bytes)=1149088 Total Memory(bytes)=2162688 Used Memory(bytes)=1013600 Used Memory(percent)=47%
2007/10/13-21:22:23-JST [1B8E059] Recovering execution with audit ID 4117
2007/10/13-21:22:23-JST [157AA53] Connection Manager - off
2007/10/13-21:22:23-JST [1B8E059] Explicit garbage collection - requested
2007/10/13-21:22:23-JST [1B8E059] AuditId=4117: Processing execute request
2007/10/13-21:22:23-JST [1B8E059] Free Memory(bytes)=1122832 Total Memory(bytes)=2162688 Used Memory(bytes)=1039856 Used Memory(percent)=49%
2007/10/13-21:22:23-JST [1B8E059] Service startup complete
2007/10/13-21:22:23-JST [157AA53] Thin driver connection time - 94 millisecond(s)
2007/10/13-21:22:23-JST [1DF8B99] Thin driver connection time - 94 millisecond(s)
2007/10/13-21:22:23-JST [1DF8B99] Initializing execution for auditId= 4117 parentAuditId= null topLevelAuditId=4117 taskName=ICDMAPFCTAWB
2007/10/13-21:22:23-JST [157AA53] Initializing execution for auditId= 4109 parentAuditId= null topLevelAuditId=4109 taskName=ICDMAPFCTAWB
2007/10/13-21:22:24-JST [1DF8B99] oracle.wh.runtime.platform.service.controller.RecoveryInProgress: RPE-01008: Recovery of this request is in progress.
at oracle.wh.runtime.platform.service.controller.AdapterContextImpl.initialize(AdapterContextImpl.java:1570)
at oracle.wh.runtime.platform.service.controller.ExecutionContextImpl.initialize(ExecutionContextImpl.java:1508)
at oracle.wh.runtime.platform.service.controller.ExecutionController.initialize(ExecutionController.java:32)
at oracle.wh.runtime.platform.service.controller.ExecutionController.execute(ExecutionController.java:50)
at oracle.wh.runtime.platform.service.controller.ExecutionController.execute(ExecutionController.java:23)
at oracle.wh.runtime.platform.service.ExecutionManager.run(ExecutionManager.java:36)
at java.lang.Thread.run(Thread.java:534)
2007/10/13-21:22:24-JST [157AA53] oracle.wh.runtime.platform.service.controller.RecoveryInProgress: RPE-01008: Recovery of this request is in progress.
at oracle.wh.runtime.platform.service.controller.AdapterContextImpl.initialize(AdapterContextImpl.java:1570)
at oracle.wh.runtime.platform.service.controller.ExecutionContextImpl.initialize(ExecutionContextImpl.java:1508)
at oracle.wh.runtime.platform.service.controller.ExecutionController.initialize(ExecutionController.java:32)
at oracle.wh.runtime.platform.service.controller.ExecutionController.execute(ExecutionController.java:50)
at oracle.wh.runtime.platform.service.controller.ExecutionController.execute(ExecutionController.java:23)
at oracle.wh.runtime.platform.service.ExecutionManager.run(ExecutionManager.java:36)
at java.lang.Thread.run(Thread.java:534)
2007/10/13-21:22:24-JST [1DF8B99] Attempting to create adapter 'class.RuntimePlatform.0.NativeExecution'
2007/10/13-21:22:24-JST [157AA53] Attempting to create adapter 'class.RuntimePlatform.0.NativeExecution'
2007/10/13-21:22:24-JST [157AA53] Attempting to create native operator 'class.RuntimePlatform.0.NativeExecution.PLSQL'
2007/10/13-21:22:24-JST [1DF8B99] Attempting to create native operator 'class.RuntimePlatform.0.NativeExecution.PLSQL'
2007/10/13-21:22:24-JST [157AA53] Native execution operator initiating recovery by recoverable operator oracle.wh.runtime.platform.operator.plsql.NativePLSQLOperator
2007/10/13-21:22:24-JST [1DF8B99] Native execution operator initiating recovery by recoverable operator oracle.wh.runtime.platform.operator.plsql.NativePLSQLOperator
2007/10/13-21:22:24-JST [157AA53] Native PLSQL Operator recovery starting
2007/10/13-21:22:24-JST [1DF8B99] Native PLSQL Operator recovery starting
2007/10/13-21:22:24-JST [1DF8B99] Thin driver connection time - 94 millisecond(s)
2007/10/13-21:22:25-JST [1DF8B99] PLSQL callspec: declare "$MAP_ENV$" wb_rt_mapaudit.wb_rt_name_values;begin "$MAP_ENV$"(1).param_name := 'OBJECT_ID';"$MAP_ENV$"(1).param_value := 1170;"$MAP_ENV$"(2).param_name := 'AUDIT_ID';"$MAP_ENV$"(2).param_value := 4117;"$MAP_ENV$"(3).param_name := 'OPERATING_MODE';"$MAP_ENV$"(3).param_value := '3';"$MAP_ENV$"(4).param_name := 'PURGE_GROUP';"$MAP_ENV$"(4).param_value := 'WB';"$MAP_ENV$"(5).param_name := 'MAX_NO_OF_ERRORS';"$MAP_ENV$"(5).param_value := '1000';"$MAP_ENV$"(6).param_name := 'COMMIT_FREQUENCY';"$MAP_ENV$"(6).param_value := '1000';"$MAP_ENV$"(7).param_name := 'AUDIT_LEVEL';"$MAP_ENV$"(7).param_value := '2';"$MAP_ENV$"(8).param_name := 'BULK_SIZE';"$MAP_ENV$"(8).param_value := '1000'; ? := "ICDMAPFCTAWB"."MAIN"(p_env=>"$MAP_ENV$");end;
2007/10/13-21:22:25-JST [157AA53] Thin driver connection time - 110 millisecond(s)
2007/10/13-21:22:25-JST [157AA53] PLSQL callspec: declare "$MAP_ENV$" wb_rt_mapaudit.wb_rt_name_values;begin "$MAP_ENV$"(1).param_name := 'OBJECT_ID';"$MAP_ENV$"(1).param_value := 1170;"$MAP_ENV$"(2).param_name := 'AUDIT_ID';"$MAP_ENV$"(2).param_value := 4109;"$MAP_ENV$"(3).param_name := 'OPERATING_MODE';"$MAP_ENV$"(3).param_value := '3';"$MAP_ENV$"(4).param_name := 'PURGE_GROUP';"$MAP_ENV$"(4).param_value := 'WB';"$MAP_ENV$"(5).param_name := 'MAX_NO_OF_ERRORS';"$MAP_ENV$"(5).param_value := '1000';"$MAP_ENV$"(6).param_name := 'COMMIT_FREQUENCY';"$MAP_ENV$"(6).param_value := '1000';"$MAP_ENV$"(7).param_name := 'AUDIT_LEVEL';"$MAP_ENV$"(7).param_value := '2';"$MAP_ENV$"(8).param_name := 'BULK_SIZE';"$MAP_ENV$"(8).param_value := '1000'; ? := "ICDMAPFCTAWB"."MAIN"(p_env=>"$MAP_ENV$");end;
it shows Error creating the temp directory C:\OraHome_1/owb/temp, but the temp folder is alreadt there in the <OWB_HOME>/owb.
Can somebody help me to solve this issue? The owb repository version is 10.2.0.2 ..A few mappings got executed. The error is coming for a mapping which is quite a big one...Hi,
If you are trying to deploy the table from Client straight, OWB generates UPGRADE statement,and this never worked. It is a bug.
go to Deployment manager, select the table in question and then use the "Replace" action. this should work. But, the data you have loaded previously will be vanished, as "Replace" drops the table and re-creates it.
Thanks
mahesh -
Hi everybody, In form 4.5 we have to compile .fmb and .fmx extension. Can anybody tell me, what extension we have to compile in
Form 6i?
Thanks
KazHi kaz,
as bert say. there is no changes in forms 6i concerning the file extensions.
Forms source is .fmb
Forms Runtime is .fmx
PLSQL library source .pll
PLSQL library runtime .plx
Reports Source is .rdf
Reports runtime is .rep
Object library is .olb
and normally when compiling we do not state the destination filename.extension so that it takes the defaults....
Regars
Yogeeraj
null -
we are getting below issue while generating WSDL .Can you please help me some one ?
Error Description
Error occured while service was processing.
Error Details
oracle.apps.fnd.soa.util.SOAException: ServiceProcessingError: Exception returned from JCA Service Runtime. file:/u01/oracle/VIS/inst/apps/VIS_oracle-ebs/soa/PLSQL/4892/XXBT_MIDAS_ORDER_CREATION.wsdl [ XXBT_MIDAS_ORDER_CREATION_ptt::XXBT_MIDAS_ORDER_CREATION(InputParameters,OutputParameters) ] - WSIF JCA Execute of operation 'XXBT_MIDAS_ORDER_CREATION' failed due to: Could not instantiate InteractionSpec oracle.tip.adapter.apps.AppsStoredProcedureInteractionSpec due to: Error while setting JCA WSDL Property. Property setIRepOverloadSeq is not defined for oracle.tip.adapter.apps.AppsStoredProcedureInteractionSpec Please verify the spelling of the property. ; nested exception is: ORABPEL-12532 Error while setting JCA WSDL Property. Property setIRepOverloadSeq is not defined for oracle.tip.adapter.apps.AppsStoredProcedureInteractionSpec Please verify the spelling of the property. ; nested exception is: org.collaxa.thirdparty.apache.wsif.WSIFException: Could not instantiate InteractionSpec oracle.tip.adapter.apps.AppsStoredProcedureInteractionSpec due to: Error while setting JCA WSDL Property. Property setIRepOverloadSeq is not defined for oracle.tip.adapter.apps.AppsStoredProcedureInteractionSpec Please verify the spelling of the property. ; nested exception is: ORABPEL-12532 Error while setting JCA WSDL Property. Property setIRepOverloadSeq is not defined for oracle.tip.adapter.apps.AppsStoredProcedureInteractionSpec Please verify the spelling of the property. at oracle.apps.fnd.soa.provider.services.jca.JCAHandler.invoke(JCAHandler.java:169) at oracle.apps.fnd.soa.provider.services.jca.JCAHandler.handleRequest(JCAHandler.java:113) at oracle.apps.fnd.soa.provider.SOAProvider.processMessage(SOAProvider.java:342) at oracle.j2ee.ws.server.provider.ProviderProcessor.doEndpointProcessing(ProviderProcessor.java:956) at oracle.j2ee.ws.server.WebServiceProcessor$1.run(WebServiceProcessor.java:358) at java.security.AccessController.doPrivileged(Native Method) at javax.security.auth.Subject.doAs(Subject.java:396) at oracle.j2ee.ws.server.WebServiceProcessor.invokeEndpointImplementation(WebServiceProcessor.java:355) at oracle.j2ee.ws.server.provider.ProviderProcessor.doRequestProcessing(ProviderProcessor.java:466) at oracle.j2ee.ws.server.WebServiceProcessor.processRequest(WebServiceProcessor.java:114) at oracle.j2ee.ws.server.WebServiceProcessor.doService(WebServiceProcessor.java:96) at oracle.j2ee.ws.server.WebServiceServlet.doPost(WebServiceServlet.java:194) at javax.servlet.http.HttpServlet.service(HttpServlet.java:763) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:713) at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:370) at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:871) at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:453) at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:313) at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:199) at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260) at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303) at java.lang.Thread.run(Thread.java:619) org.collaxa.thirdparty.apache.wsif.WSIFException: file:/u01/oracle/VIS/inst/apps/VIS_oracle-ebs/soa/PLSQL/4892/XXBT_MIDAS_ORDER_CREATION.wsdl [ XXBT_MIDAS_ORDER_CREATION_ptt::XXBT_MIDAS_ORDER_CREATION(InputParameters,OutputParameters) ] - WSIF JCA Execute of operation 'XXBT_MIDAS_ORDER_CREATION' failed due to: Could not instantiate InteractionSpec oracle.tip.adapter.apps.AppsStoredProcedureInteractionSpec due to: Error while setting JCA WSDL Property. Property setIRepOverloadSeq is not defined for oracle.tip.adapter.apps.AppsStoredProcedureInteractionSpecHi HDeiby,
I didn't find the "setIRepOverloadSeq" in wsdl file.i have verified all wsdl files but i didn't find. Please let me know excat file name .
[applmgr@oracle-ebs 4892]$ ls -ltr
total 24
-rwxrwxrwx 1 applmgr dba 3167 Sep 5 02:46 XXBT_MIDAS_ORDER_CREATION.wsdl
-rwxrwxrwx 1 applmgr dba 706 Sep 5 02:46 XXBT_MIDAS_ORDER_CREATION_PKG.wsdl
-rwxrwxrwx 1 applmgr dba 3534 Sep 5 02:46 XXBT_MIDAS_ORDER_CREATION_PKG_soap.wsdl
-rwxrwxrwx 1 applmgr dba 3328 Sep 5 02:46 XXBT_MIDAS_ORDER_CREATION_PKG_soap_http.wsdl
-rwxrwxrwx 1 applmgr dba 1328 Sep 5 02:46 APPS_XXBT_MIDAS_ORDER_CREATION_PKG_XXBT_MIDAS_ORDER_CREATION.xsd
-rwxrwxrwx 1 applmgr dba 1245 Sep 5 02:46 AppsContextHeader.wsdl -
Interpreting PLSQL RUNTIME DUMP
Currently some jobs that import lots of data have crashed.
I got an 100+ MB .trc in bdump directory, containing numerous times information like below snippet:
/usr/local/oracle/admin/PROD/bdump/prod_j001_5205.trc
Oracle9i Enterprise Edition Release 9.2.0.8.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.8.0 - Production
ORACLE_HOME = /usr/local/oracle/product/9.2.0
System name: Linux
Node name: oracle.X.X
Release: 2.6.9-89.ELsmp
Version: #1 SMP Mon Apr 20 10:34:33 EDT 2009
Machine: i686
Instance name: PROD
Redo thread mounted by this instance: 1
Oracle process number: 34
Unix process pid: 5205, image: [email protected] (J001)
*** 2010-10-20 16:49:57.854
*** SESSION ID:(45.2871) 2010-10-20 16:49:57.816
*********START PLSQL RUNTIME DUMP************
***Got ORA-6540 while running PLSQL***
ANONYMOUS BLOCK:
library unit=a2a5dc78 line=1 opcode=228 static link=0 scope=0
FP=b04387c PC=9cf83a5f Page=0 AP=0 ST=b043b60
DL0=b7625ebc GF=b7625f08 DL1=b7625edc DPF=b7625f00 DS=99e8aa64
DON library unit variable list instantiation
0 a2a5dc78 b7625f08 b76784f8
1
2
3
4
5
6
7
scope frame
2 0
1 b04387c
package variable address size
0 b7625f34 172
1 b7625fe0 172
2 b762608c 172
3 b7626138 172
4 b76261e4 172
5 b7626290 172
6 b762633c 172
7 b76263e8 172
8 b7626494 172
9 b7626540 172
10 b76265ec 172
version=43123476 instantiation size=2008
line pcode offset
1 27
1 70
1 86
1 103
1 117
1 140
1 154
1 171
1 175
1 218
1 234
1 251
1 265
1 288
1 302
1 319
1 323
1 366
1 382
1 399
1 413
1 437
1 451
1 469
1 473
1 516
1 532
1 549
1 563
1 587
1 601
1 619
1 623
1 666
1 682
1 699
1 713
1 737
1 751
1 769
1 780
***********END PLSQL RUNTIME DUMP************Unfortunatly I have little experience regarding interpreting these kind of dumps...am googling and searching on it now, but perhaps somebody here has done this numerous times already...
I'm finding out what's the best way to use the information from the dump and locate at what point in the code during processing the error occurs.
Unfortunatly this happens during extensive dynamic SQL processing, and the 'custom error handling' fails as well, so I have no other information than like the snippet above. I think I know what package errors out and what procedure, but is there a way to map the information above to the correct line number and/or package variable? Can this information linked to the DataDictionary for example?
That would be far more efficient than debugging this legacy 'code'...
Regarding the error code:
ORA-06540: PL/SQL: compilation error
Cause: A pl/sql compilation error occurred. However, the user generally will not see this error message. Instead, there will be accompanying PLS-nnnnn error messages.
Action: See accompanying PLS-nnnnn error messages.
Unfortunatly I haven't found any accompanying PLS messages....
http://download.oracle.com/docs/cd/B19306_01/server.102/b14219/e4100.htm#sthref2034
Thanks in advance for pointers/hints/tips.
edit
Found MOS doc [ID 3658039.8], and given the dynamic SQL code + lots of data to crunch (and thus killing the shared pool) I'm wondering if it could be that something comparable is going on here...especially since the jobs do not crash when importing much smaller files.
Edited by: hoek on Oct 22, 2010 2:15 PMHello,
Are you scheduling any program in background which is calling ws_query? WS_QUERY is only used to excute files in the presentation server and will not work in the background
Vikranth -
Finding commits in plsql during runtime
Hi,
In any application, we will have many commit statements issued in many places. How can we find out as to where all commits have happened during runtime.
Basically in our application, when am trying an operation, am getting the error ORA-01086: savepoint <save point name> never established.
My guess is that there is a commit somewhere because of which system is not able to rollback to that save point.
So I would like to find out where is commit is issued.
Is there any way to find this.
Thanks in Advance.
VijayDuplicate Post.
Please mark this Answered and redirect to Finding commits in plsql -
Suggest plsql code for form security during runtime
Hi
I made a project using forms 6I . I created 4 forms in all. I created a Menu item too like create,insert, delete,modify records, reports print etc. Now What I want is if user want to enter a particular form he should select appropriate menu item from the menu But what I my exact need is if user attempt to enter a form a small popup dialogue box should be displayed in the middle of the screen and asks for a password . So I want a pl&sql function or procedure which creates a default password and match the same when the user enterered the same in popup dialogue box and allow or reject the user request. Please suggest me a full DETAILED PL/SQL CODE FOR THIS PURPOSE. OR ANY FORM 6I FEATURE.
thanks in advance
prasanth as.The dialog box is part of the ftandard Forms functionality. What you need to do is set up the user account with the password set to EXPIRED and no grace logins. The Admin Guide tells you how to do this.
Cheers, APC -
Error while trying to access a SSWA PLSQL function
Hi,
I am trying to access a report as a web page by defining the function as follows :
Type : SSWA PLSQL FUNCTION
HTML Call : OracleOASIS.RunReport
Parameters : report=EMPDET
This function is attached to the menu and when I try to access the page I get this error.
"Error: The requested URL was not found, or cannot be served at this time.
Incorrect usage."
The URL that shows in the page is as follows(<server:port> I removed the server name and port) :
http://<server:port>/dev60cgi/rwcgi60?GDEV_APPS+DESFORMAT=HTML+SERVER=GDEV_APPS+report=EMPDET+p_session_id=A9C71A70B9B1D9BD2DCC0FC3AF9BC324+p_user_id=1133+p_responsibility_id=50230+p_application_id=800+p_security_group_id=0+p_language_code=US+NLS_LANG=AMERICAN_AMERICA+NLS_DATE_FORMAT=DD-MON-RRRR+NLS_NUMERIC_CHARACTERS=.%2C+NLS_DATE_LANGUAGE=AMERICAN+NLS_SORT=BINARY+paramform=NO
Surprisingly other functions which are defined in this manner work fine. Do I need to register my report anywhere or are there any other settings I need to do for the report to show up.
Can someone let me know.
ThanksHi ;
pelase check below which could be similar error like yours
Troubleshooting of Runtime Errors of Customer Intelligence Reports [ID 284829.1]
Regard
Helios -
How to assign the output of a function to a text area: a PLSQL challenge
I have a function that returns a PLSQL table of varchar4(4000)
Here is its signature in a package:
create or replace package researcher_request_pk
is
TYPE query_table_type is table of varchar2(4000) index by binary_integer;
FUNCTION RequestSQL(P_RRQ_ID in number) return query_table_type;
end;
I use this to get around the 32k limit on clobs and varchar2 variables
I want to assign the output of the function to a text area. I've tried the following PLSQL in a dynamic action and also as the source attribute of the Text Area but it doesn't populate the text area.
Here is the code i'm using
declare
v_table researcher_request_pk.query_table_type;
begin
v_table:=researcher_request_pk.RequestSQL(:P64_RRQ_ID);
for i in 1..v_table.count loop
htp.prn(v_table(i));
end loop;
end;
Any ideas on the correct syntax to do this?
thanks in advance
PaulPThanks for your reply
The function does populate the PLSQL table with data. e.g. If I place that exact code in a PLSQL region it generates the output on the screen with no problems. The problem is just generating the output into the text area.
I want the text area to display the output of the PLSQL table (-a dynamic select SQL statement) which I then plan to execute to return records.( i.e. I've build my own runtime query builder)
My plan is to allow the user to edit the SQL output first before sending the statement for execution.
Funnily enough I do get the very first word of the first cell appearing, namely 'SELECT' but nothing else. Maybe the "||" that follows has something to do with the rest of it not appearing?? hmmm... will experiment more.
thanks
PaulP -
Could any body look into this exception....
I am stuggling with this for the last one week........
I have generated the webservices from PLSql procedure, deployed and tested in oc4j which is successfull running and I can access the webservice too.....
The same ear file, when i deploy in to weblogic I am getting the follwing error, can anybody look in to this and help me....
<May 20, 2006 2:09:14 PM GMT+05:30> <Error> <Deployer> <BEA-149231> <Unable to s
et the activation state to true for the application 'gtry-gtry-WS'.
weblogic.application.ModuleException: [HTTP:101216]Servlet: "gwsSoapHttpPort" fa
iled to preload on startup in Web application: "gtry-gtry-context-root".
java.lang.IllegalStateException: could not find schema type named {{http}//orass
pcon/Gws.wsdl/types/}EmpRecUser
at weblogic.wsee.bind.runtime.internal.AnonymousTypeFinder$GlobalTypeNod
e.getSchemaType(AnonymousTypeFinder.java:181)
at weblogic.wsee.bind.runtime.internal.AnonymousTypeFinder.getTypeNamed(
AnonymousTypeFinder.java:86)
at weblogic.wsee.bind.runtime.internal.Deploytime109MappingHelper.create
BindingTypeFrom(Deploytime109MappingHelper.java:888)
at weblogic.wsee.bind.runtime.internal.Deploytime109MappingHelper.proces
sTypeMappings(Deploytime109MappingHelper.java:466)
at weblogic.wsee.bind.runtime.internal.Deploytime109MappingHelper.initBi
ndingFileFrom109dd(Deploytime109MappingHelper.java:246)
at weblogic.wsee.bind.runtime.internal.Deploytime109MappingHelper.<init>
(Deploytime109MappingHelper.java:162)
at weblogic.wsee.bind.runtime.internal.RuntimeBindingsBuilderImpl.create
RuntimeBindings(RuntimeBindingsBuilderImpl.java:80)
at weblogic.wsee.ws.WsBuilder.createRuntimeBindingProvider(WsBuilder.jav
a:272)
at weblogic.wsee.ws.WsBuilder.buildService(WsBuilder.java:94)
at weblogic.wsee.ws.WsFactory.createServerService(WsFactory.java:58)
at weblogic.wsee.server.servlet.WebappWSServlet.initRuntime(WebappWSServ
let.java:70)
at weblogic.wsee.server.servlet.WebappWSServlet.initImpl(WebappWSServlet
.java:32)
at weblogic.wsee.server.servlet.BaseWSServlet.init(BaseWSServlet.java:40
at javax.servlet.GenericServlet.init(GenericServlet.java:256)
at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(St
ubSecurityHelper.java:276)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(Authenticate
dSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:
121)
at weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecuri
tyHelper.java:68)
at weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubL
ifecycleHelper.java:58)
at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHel
per.java:48)
at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubI
mpl.java:493)
at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppS
ervletContext.java:1688)
Thanks in Advance
Jayanthy.Hi Supriya,
Check the following:
* Whether the Report is locked in the server.
* Are the parameters you pass from the form to report have the similar data types.
Hope your problem is fixed.
Regards. -
SQL types over PLSQL types while using Oracle Applications adapter in BPEL
Use SQL types over PL/SQL types while using Oracle Applications adapter
in BPEL/ ESB
This document will be focusing on Oracle Applications adapter. However Database adapter is much like OA adapter (even OA adapter uses DB Adapter), so the readers who are interested to explore DB adapters, can relate things with this document and go further as well.
Some Guidelines for writing PL/SQL APIs for OA Adapter
As we know when we create a partner link from the OA adapter wizard it sometimes writes some wrapper script supportive to the OA Adapter WSDL which contains below
* Object type for PL/SQL RECORD
* Nested table of the given type for PL/SQL TABLE. For example, the nested table of NUMBER.
* INTEGER substituted for PL/SQL BOOLEAN
* Wrapper Script for converting above three set of data types . (PLSQL to SQL and SQL to PLSQL conversion functions)
In runtime this wrapper script for converting PL/SQL to SQL and SQL to PL/SQL is an extra overhead.
So the first advice would be to avoid the use of the below as parameters of PLSQL API being called by OA Adapter.
* PL/SQL RECORD
* PL/SQL TABLE. For example, the nested table of NUMBER.
* PL/SQL BOOLEAN
In other way we can say we should try to use only SQL data types in arguments if we are planning to call any PL/SQL API from the OA Adapter.
If the requirement is to use a table or record uses the Object type. In place of BOOLEAN better to use VARCHAR or INTEGER what ever fulfills your requirement. Following this guideline we can reduce a huge number of Line of codes to be run each time the adapter being called.
Generally, Oracle E-Biz standard APIs use PL/SQL record types and table types so when there is a requirement to call these API’s from OA Adapter (this is a common requirement in development), and if we directly browse the API in OA Adapter Configuration Wizard and create the partner link, again a huge number of code is written by the wizard in the wrapper script (a number of extra mapping of fields which are not being used in the interface).
In this case better would be to create an Object type with only the required fields which are being used in that call and use them as parameters for the PLSQL API.Find the complete document
http://www.4shared.com/file/167171882/29525116/Use_SQL_types_over_PLSQL_types.html -
Need suggestion on PLSQL Create and EXECUTE IMMEDIATE
Most of you already know plsql doesn't like create table, so we have to use EXECUTE IMMEDIATE for creating table. What if I want to see if the table exist, if not then create the table, later I will insert data into that table.
My problem is it returned me the error saying I am try to insert into a non existing table when trying to compile my code. I think plsql doesn't pick up the execute statement.
what I did is, both create and insert are executed by using EXECUTE IMMEDIATE. Anyone have such experience before and willing to share your knowledge?
PS: I am having same problem for creating sequence as well.I think plsql doesn't pick up the execute statement.Since it is a runtime instruction, it will pick it up at runtime. but to be able to run, it needs to compile the code and in order to compile (so it can run) the code it needs that table/sequence you are referencing to exist already. So, you need to run the code to get the table and run needs to compile the code and compile needs the table to compile. can't go from here to there when you try to mix dynamic sql with static sql on the same object within the same program unit (or dependent units).
-
Calling sql script in plsql procedure
Hello,
I have a sql script named mytest.sql and i want to execute this from a stored procedure.
following is the contents of this script
spool d:\mytestsql.txt
select * from tab;
spool off
Actually i want my sql script to run daily to export some tables data.
I can execute this script from a sql prompt but i want to run it from enterprise manager.
I am using oracle 10gR2 on windows2000 system.
Any idea about scheduling the sql script to run automatically??
How to execute this sql script from a plsql procedure??
ThanksHi all,
Thanks for all the replies. I have found the solution with external procedures.
Following is the complete step by step guide.
1. Create the OSCommand Java Class using the following statement:
connect as any user:
create or replace and compile java source named oscommand as
import java.io.*;
public class OSCommand{
public static String Run(String Command){
try{
Runtime.getRuntime().exec(Command);
return("0");
catch (Exception e){
System.out.println("Error running command: " + Command +
"\n" + e.getMessage());
return(e.getMessage());
2. Create the following Wrapper Function using the following statement:
CREATE or REPLACE FUNCTION OSCommand_Run(Command IN STRING)
RETURN VARCHAR2 IS
LANGUAGE JAVA
NAME 'OSCommand.Run(java.lang.String) return int';
3. connect as sys
Execute dbms_java.grant_permission( 'FKHALID','SYS:java.io.FilePermission', '<<ALL FILES>>','execute');
execute dbms_java.grant_permission( 'FKHALID','SYS:java.lang.RuntimePermission', 'writeFileDescriptor', '*' );
execute dbms_java.grant_permission( 'FKHALID','SYS:java.lang.RuntimePermission', 'readFileDescriptor', '*' );
commit;
note: here fkhalid is the oracle user.
connect as fkhalid user:
Declare
expdp_cmd Varchar2(2000);
Begin
expdp_cmd := OSCommand_Run('cmd /c sqlplus fkhalid@mtcedwt/pwd @d:\ORA_DUMPS\mydbexp.sql');
DBMS_OUTPUT.Put_Line(expdp_cmd);
End;
In Unix
Set Serverout On
Declare
x Varchar2(2000);
Begin
x := OSCommand_Run('/home/test/myoscommand.sh')
DBMS_OUTPUT.Put_Line(x);
End;
I will check the dbms_scheduler also and will let you know the results.
Thanks -
Error in PLSQL Procedure...
Hi Guys,
I have the following functions inside a package...
I was trying to create directories dynamically in the runtime in side a plsql...
FUNCTION Get_Site_Dir_Name (
site_ IN VARCHAR2,
dir_type_ IN VARCHAR2 ) RETURN VARCHAR2
IS
BEGIN
RETURN (REPLACE(site_, ' ', NULL) || UPPER(dir_type_));
END Get_Site_Dir_Name;
PROCEDURE Set_Dir_Path (
dir_path_ IN VARCHAR2,
site_ IN VARCHAR2,
dir_type_ IN VARCHAR2 )
IS
BEGIN
CREATE OR REPLACE DIRECTORY Get_Site_Dir_Name(site_, dir_type_) AS dir_path_;
END Set_Dir_Path;But this gives me an error when deploying...
Warning: Package Body created with compilation errors.
Errors for PACKAGE BODY SITE_API:
LINE/COL ERROR
1354/4 PLS-00103: Encountered the symbol "CREATE" when expecting one of
the following:
begin case declare exit for goto if loop mod null pragma
raise return select update while with <an identifier>
<a double-quoted delimited-identifier> <a bind variable> <<
close current delete fetch lock insert open rollback
savepoint set sql execute commit forall merge pipe
Can some one help me with this?
Many Thanks....dir_name_ := 'TESTDIR';
stmt_ := 'EXECUTE IMMEDIATE CREATE OR REPLACE DIRECTORY :dir_name AS :dir_path;';
EXECUTE IMMEDIATE stmt_
USING IN dir_name_,
IN dir_path_;Remove ;
stmt_ := CREATE OR REPLACE DIRECTORY :dir_name AS :dir_path';or
SQL> Declare
2 dir_name varchar2(20) := 'TESTDIR';
3 dir_path varchar2(20) := 'C:\';
4 stmt varchar2(100);
5 Begin
6 EXECUTE IMMEDIATE 'CREATE DIRECTORY '||dir_name||' AS '''||dir_path||'''';
7 Dbms_output.put_line('Directory is created');
8 end;
9 /
Directory is created
PL/SQL procedure successfully completed.Twinkle
Edited by: Twinkle on Nov 18, 2009 4:39 PM
Maybe you are looking for
-
Dual G5, no longer burns CDs
I have a dual G5, about 4 months old. If I insert a blank CD, the CD drive whirrs for maybe 10-15 seconds, then it ejects the CD. Audio CDs play fine. Data DVDs read fine. However, blank media gets rejected. This started happening after I installed O
-
Mass Activity for 0FC_COLL_01
Hi, I have to do the Mass activity for datasource 0FC_COLL_01 in the ISU system but not found any related on stuff for that. Does any one have idea about the transaction code and steps for that. Regards, Javed
-
Batch specific report in sales
Dear All, Any batch specific reports available in SAP in sales side like What are all deliveries are associated,ship to party, delivery type and invoice numbers and invoice types related to a particular batch. Regards, DP
-
Add a new component in Production order while not being in BOM
Hi all, I would like to know how to forbid the addition of a new component in a Production order that doesn't exist in the BOM. Currently when we create a Production Order, the components of its materials are read from the BOM. If we add a component
-
What does "reading xmp..." actually mean?
I know this may seem like a silly question, but i cannot find the answer to it anywhere. Some projects take ages to get past this stage, others don't. What is media encoder doing whilst displaying "Reading XMP..."? One project in particular stays on