Call PLSQL function in Controller...
Hi,
Is there a way to call a PLSQL function in the controller? We have a function, which determines if we are in production or not. We then set a url based on this info.
Is there a way to call a PLSQL function in the controller?
Yes, there is , but not recommended, make a call to AM from the CO , from the AM call the pl/sql proc, and return the result to the CO.We have a function, which determines if we are in production or not. We then set a url based on this info.
There is another way of doing it, please see this thread, this might help
How to get Value of URL to determine Production instance
Thanks
Tapash
Similar Messages
-
Call plsql function from esb-xsl mapping
Hi
I want to call a plsql function that takes an inparameter from an xsl mapping file.
I tried to use the orcl:query-database function for this, but i couldn't get it to work when I wanted to dynamically pass the value of the inparameter to the function taken from the XML file used as input in the xsl transformation:
If I hardcode the parameter value like this, it works fine:
orcl:query-database('select emx_parameters.get_parameter_value('DEADLINE') result from dual',false(),false(),'jdbc/DB')
But if i dynamically want to assign the inparameter, it doesn't work for me:
orcl:query-database('select emx_parameters.get_parameter_value('/Header/ParameterName') result from dual',false(),false(),'jdbc/DB')
Maybe it has something to do with the ' signs, but I tried a lot of combinations it nothing worked for me.
Has anyone any ideas how to do this?
Thanks
KalleHi
If anyone is interested i managed to solve it this way:
I build up the sql query string with xsl variables like this:
<xsl:variable name="start">select emx_parameters.get_parameter_value('</xsl:variable>
<xsl:variable name="param" select='/Header/ParameterName'/>
<xsl:variable name="end">') result from dual</xsl:variable>
<xsl:variable name="expr" select="concat($start,$param,$end)"/>
And then I called the orcl:query-database method with the variable as in-parameter.
orcl:query-database($expr,false(),false(),"jdbc/DB")
Maybe there is another way, but this worked for me.
//Kalle -
How to call Plsql function in discoverer
Hello,
Can anyone tell me how to call plsql fuunction in Oracle Business Intelligence Desktop Discoverer?
what i was doing here is i am able to register my function in Administration but i dont know when i need to make call and where i need to pass parameters to make call that function.
its lil urgent, can any of you guys send me the instructions step by step
Thanks in advance!!
sidThanks for your reply Michael,some how i found that make call from calculation , but the problem here is i was not able to pass parameter thru function.please find the scenario below,
case(1) i have function without parameters, it does some DML operations inside that and it is working fine.when i refresh i see tables getting populated.
case(2)I have another function as shown below with parameters(input) but i was getting error (One of The function arguments has an incorrect datatype:POST_SAVE_DOCUMENT)
my function is like this:
create or replace function POST_SAVE_DOCUMENT
(P_WORKBOOKOWNER in VARCHAR2,
P_WORKBOOK in VARCHAR2,
P_WORKSHEET in VARCHAR2,
P_SEQUENCE in number,
P_SQL_SEGMENT in VARCHAR2
return number AS
BEGIN
delete from my_sql;
insert into my_sql
( WORKBOOKOWNER,
WORKBOOK,
WORKSHEET,
SEG_SEQUENCE,
SQL_SEGMENT)
VALUES ( P_WORKBOOKOWNER,
P_WORKBOOK,
P_WORKSHEET,
P_SEQUENCE,
P_SQL_SEGMENT
return 1;
end;
i dont see anything wrong here with in this function, but some how i have a problem with parameter.
Can you give some idea or solution to get rid of this problem.
Finally ..i did not see anything under item radio button (The recommended way now is to click the Items radio button, find an item that you want to pass to a parameter, then on the right-hand side highlight the placeholder for the parameter, then finally you click the Paste button. You repeat this for all the parameters and then click OK to finish the calculation.
Thanks in adavance!!
Thanks
S!D
Edited by: user12861418 on Apr 28, 2010 2:01 PM -
How can I call a plsql function from an attribute?
I have an attribute defined in an element. I want execute a PLSQL function from the attribute, and display the returne value with an HTML template.
I've defined the attribute's type like PLSQL, and I've put the called of the function in the value of the attribute, but it doesn't work. The only value I obtain is an URL (I think that is the URL of the function or someting like this).
How can I call to my function from the attribute and display the returnes value in the page?
Thanks.Thanks, but it doesn't work. I have an attribute called ID_BOL and I want to associate a sequence to that attribute. I've created a function, with the sequence. This function return de value of the sequence. I want taht the attribute takes the value of the sequenece dinamically.
I've tried it, creating the type attribute like PLSQL, and calling the function from the attribute, but it doesn't work.
How can I return the sequence value to my attribute?
Thanks. -
How to create SSWA plsql function in Oracle Apps of HTML call .html
Hello Team,
I am working on Oracle Apps 11i (11.5.10.2)
I want to know , what is the process to create a , "SSWA plsql function" in Oracle Apps of type "HTML" and html call tab.
How to create that Function and how to attach the PL/SQL code to these functions.
How it works.
Please help me to understand this concept from basics.
Kind RegardsHi;
Please review:
how to setup a forms function in R12 to launch an URL?
http://www.trutek.com/serendipity/index.php?/archives/15-An-Example-of-How-to-Create-Custom-Functions,-Menus,-and-Responsibilities.html
Regard
Helios -
Please suggest solutiion for calling a plsql function in report
Hi,
I did a small project using forms and reports 6i. Now i prepared a repor that will calucalate the sum(expenditure)per report level. Now the problem is i want to print the sum which is in number form , in words. That is if the sum is 50000 then i want to print "fifty thousand". For this conversion from number to figure i wrote a small programme , which successfully compiled and created a function.
Now I want to create a field in the report and in which I want to call this plsql function and perform the number conversion of sum(expenditure)per report field. Please describe in detail how to make reference between these two fields i.e sum(expenditure)per report and field in which I want to run plsql code and thereby converting the sum into figures.
the programme i used to convert currency from number to words is please see link.http:/orafaq.com/scripts/cheqprint.txt
Thanks in advance
Prasanth a.s.Hi,
If the amount does not exceed more than 5,373,484 then you can use the following method to print the number in words.
Test Db>Select to_char( to_date(5373484,'J'),'Jsp') from dual ;
TO_CHAR(TO_DATE(5373484,'J'),'JSP')
Five Million Three Hundred Seventy-Three Thousand Four Hundred Eighty-Four
There's no need to write DB function unless you are sure that the value can exceed 5373484.
You can do the following :
1. Create a Summary column on the report column on which you want the data summed - Report level or at any level required
2. Create a Formula Column - Report Level or any other level - Wherever required [ Same level as in Step 1]
3. The trigger text of this formula column would use the column which is summation of the Expenditure field column (Summary Column) and this function should return Varchar2
Declare
lSumInWords Varchar2(1000) := Null;
Begin
Select TO_CHAR(TO_DATE(:CS_1,'J'),'JSP')
Into lSumInWords
From dual;
Return (lSumInWords);
End;
3. In Your report layout, use this formula column for printing.
Good Luck.
-- Shailender Mehta -- -
How to call plsql procedure or function and getting back the string?
Hi Everyone,
i am using Jdev 11.1.1.5.0.
i have a requirement to call plsql procedure or function from my backing bean java file and get back the returned value from the procedure or function.
what piece of simple code i need to write in my backing bean?
please suggest.
Thanks.As always you write the method to call he pl/sql in the application module, expose this method to the client (so you see it in the datacontroll) then create a operation binding to the method and call this operation from the bean. The result you get by operation.getResult();
You should never call pl/sql from the bean directly!
The doc shows how to call the procedure from an application module: http://docs.oracle.com/cd/E21764_01/web.1111/b31974/bcadvgen.htm#sm0297
Timo -
Jobs gets hanged when a call is made to PLSQL function in Data Services XI
Hi,
I am facing the below issue after migration of BODI 11.7 to BODS XI 3.1.
The job is not proceeding after the below mentioned statements.
print('before call');
$is_job_enable=DS_TEST.TEST.MY_PKG.IS_JOB_ENABLED(job_name());
print($is_job_enable);
MY_PKG.IS_JOB_ENABLED plsql function will return Number.
$is_job_enable is a global variable declared as decimal (10, 0).
This Job works fine in Data Integrator 11.7.3 version and gets handed in Data Services XI 3.1.
I tried changing the global variable $is_job_enable to int and created new data sources before doesn't solve the problem. Can anyone tell me what is the issue?
Thanks & Regards
Maran MK
The trace file says
5260 3284 JOB 5/5/2009 4:43:17 AM Job <TEST_JOB> is started.
5260 3284 PRINTFN 5/5/2009 4:43:17 AM before call
5260 3284 SP 5/5/2009 4:43:18 AM Stored procedure call <MY_PKG.IS_JOB_ENABLED> is started.
5260 3284 SP 5/5/2009 4:43:18 AM SQL query submitted for stored procedure call <MY_PKG.IS_JOB_ENABLED> is: <BEGIN :AL_SP_RETURN :=
5260 3284 SP 5/5/2009 4:43:18 AM "TEST"."MY_PKG"."IS_JOB_ENABLED"("P_JOB_NAME" => :P_JOB_NAME); END;
5260 3284 SP 5/5/2009 4:43:18 AM >.
5260 3284 SP 5/5/2009 4:43:18 AM Stored procedure call <E> input parameter <P> has value of <TEST_JOB>.
5260 3284 SP 5/5/2009 4:43:18 AM Stored procedure call <E> return value is <1.0000000>.
5260 3284 SP 5/5/2009 4:43:18 AM Stored procedure call <MY_PKG.IS_JOB_ENABLED> is done.
The below error occurs only in Windows and not in Linux environment.
5260 3284 SYS-170101 5/5/2009 4:43:21 AM |Session TEST_JOB
5260 3284 SYS-170101 5/5/2009 4:43:21 AM System Exception <ACCESS_VIOLATION> occurred. Process dump is written to <E:\Program Files\Business Objects\Data
5260 3284 SYS-170101 5/5/2009 4:43:21 AM Services\log\BODI_MINI20090505044318_5260.DMP> and <E:\Program Files\Business Objects\Data
5260 3284 SYS-170101 5/5/2009 4:43:21 AM Services\log\BODI_FULL20090505044318_5260.DMP>
5260 3284 SYS-170101 5/5/2009 4:43:21 AM Process dump is written to <E:\Program Files\Business Objects\Data Services\log\BODI_MINI20090505044318_5260.DMP> and
5260 3284 SYS-170101 5/5/2009 4:43:21 AM <E:\Program Files\Business Objects\Data Services\log\BODI_FULL20090505044318_5260.DMP>
5260 3284 SYS-170101 5/5/2009 4:43:21 AM Call stack:
5260 3284 SYS-170101 5/5/2009 4:43:21 AM 001B:00CA9EAB, ActaDecimalImpl<RWFixedDecimal<RWMultiPrecisionInt<3> >,RWMultiPrecisionInt<3>,ActaDecimal28,char
5260 3284 SYS-170101 5/5/2009 4:43:21 AM [29]>::operator=()0315 byte(s), x:\src\rww\actadecimalimpl.cpp, line 13140004 byte(s)
5260 3284 SYS-170101 5/5/2009 4:43:21 AM 001B:00D8A267, Convert()+0999 byte(s), x:\src\eval\calc.cpp, line 0303
5260 3284 SYS-170101 5/5/2009 4:43:21 AM 001B:00DBF9E0, XVal_cast::compute()+0272 byte(s), x:\src\core\compute.cpp, line 1664
5260 3284 SYS-170101 5/5/2009 4:43:21 AM 001B:00DBC239, XStep_assn::execute()+0057 byte(s), x:\src\core\step.cpp, line 0069
5260 3284 SYS-170101 5/5/2009 4:43:21 AM 001B:00DBB30D, XStep_sblock::execute()+0029 byte(s), x:\src\core\step.cpp, line 0707
5260 3284 SYS-170101 5/5/2009 4:43:21 AM 001B:00DBB30D, XStep_sblock::execute()+0029 byte(s), x:\src\core\step.cpp, line 0707
5260 3284 SYS-170101 5/5/2009 4:43:21 AM 001B:00DBE0BC, XPlan_spec::execute()+0348 byte(s), x:\src\core\plan.cpp, line 0082
5260 3284 SYS-170101 5/5/2009 4:43:21 AM 001B:00DC5EA0, XPlan_desc::execute()+0336 byte(s), x:\src\core\xplan.cpp, line 0153
5260 3284 SYS-170101 5/5/2009 4:43:21 AM 001B:00DBD68E, XPlan_spec::compute()0206 byte(s), x:\src\core\plan.cpp, line 01450011 byte(s)
5260 3284 SYS-170101 5/5/2009 4:43:21 AM 001B:00DBD891, XPlan_spec::compute()+0225 byte(s), x:\src\core\plan.cpp, line 0244
5260 3284 SYS-170101 5/5/2009 4:43:21 AM 001B:0074533A, AE_Main_Process_Options()+31498 byte(s), x:\src\xterniface\actamainexp.cpp, line 3485
5260 3284 SYS-170101 5/5/2009 4:43:21 AM 001B:00747EDA, AE_Main()1498 byte(s), x:\src\xterniface\actamainexp.cpp, line 07680030 byte(s)
5260 3284 SYS-170101 5/5/2009 4:43:21 AM 001B:004029F9
5260 3284 SYS-170101 5/5/2009 4:43:21 AM Registers:
5260 3284 SYS-170101 5/5/2009 4:43:21 AM EAX=0000000E EBX=03E392E0 ECX=04B455A0 EDX=012346D8 ESI=02B75D88
5260 3284 SYS-170101 5/5/2009 4:43:21 AM EDI=04B455A0 EBP=00212738 ESP=002124BC EIP=00CA9EAB FLG=00210206
5260 3284 SYS-170101 5/5/2009 4:43:21 AM CS=001B DS=0023 SS=0023 ES=0023 FS=003B GS=0000
5260 3284 SYS-170101 5/5/2009 4:43:21 AM Exception code: C0000005 ACCESS_VIOLATION
5260 3284 SYS-170101 5/5/2009 4:43:21 AM Fault address: 00CA9EAB 01:00585EAB E:\Program Files\Business Objects\Data Services\bin\acta.dllHi Manoj & Tiji,
Thanks for your comments. Please find the below outcome.
print($is_job_enable); -- is not executed if PLSQL function is called.
I changed $is_job_enable to VARCHAR, still the same issue.
I created new project and executed the same in new job, still the same issue (all objects are new except Datastore).
The dmp happens only when we the PLSQL function is called. I commented the Function call, the execution proceeds further but got hanged in other PLSQL function call (different than the 1st one)
Is this bug in 12.1?
Can you tell any Hot fix available? If possible please give me the SAP Notes Number.
Is there any other way to execute the PLSQL functions/procedures in 12.1?
Thanks
Maran MK -
Calling confirm function from PLSql
Hi:
I have a button on a form. When the button is clicked, a stored procedure is called and display a confirmation box to the user. If the answer is "ok", I want to call a SQL report using the portal30.wwa_app_module.set_target(). If the answer is "cancel", I want to stop form processing.
I have the following code. It is calling the stored procedure and displaying the confirmation box correctly. But it is not calling portal30.wwa_app_module.set_target() when answered "ok".
1. ... before displaying the page
htp.p('<script language="javascript">');
htp.p('
function confirmFunction(msg)
if (confirm(msg)){
return true;
return false;
function callPLSQL(msg)
frm = document.getElementById("frame1");
if (frm)
frm.src="/pls/portal30/getcount.store_proc_name?v="+msg;
return true;
htp.p('</script>');
2. ..after displaying the form
htp.p('<iframe id="frame1" src="#x" style="display:none"></iframe>');
3. OnClick of the button:
return callPLSQL('This is a test. Do you wish to continue?');
4. Custom PL/SQL Button Event Handler:
declare
vdept number :=null;
begin
vdept := p_session.get_value_as_NUMBER(
p_block_name =>'DEFAULT',
p_attribute_name => 'A_DEPTNO');
portal30.wwa_app_module.set_target(portal30.wwctx_api.get_server_protocol
||'://'
||portal30.wwctx_api.get_host
||portal30.wwctx_api.get_script_prefix
||'/'
||portal30.wwctx_api.get_dad_name
||'/'
||'DEPT_RPT.show?p_arg_names=deptnumber&p_arg_values='
||vdept, 'CALL' );
end;
Please help...
Thanks,
AnnieThe previous post got garbled due to the < and > characters in the url.
Trying again :-
portal30.wwctx_api.get_server_protocol ||'://' ||portal30.wwctx_api.get_host ||portal30.wwctx_api.get_script_prefix ||'/' ||portal30.wwctx_api.get_dad_name ||'/' ||'DEPT_RPT.show?p_arg_names=deptnumber&p_arg_values=' ||vdept
will generate
http://<your-host>/<usually-pls>/<dad-name>/DEPT_RPT.show?p_arg_names=deptnumber&p_arg_values=<dept-no>
where as it should have been
http://<your-host>/<usually-pls>/<dad-name>/<application-schema>.DEPT_RPT.show?p_arg_names=deptnumber&p_arg_values=<dept-no>
However, you can achieve this very simply as :-
portal30.wwa_app_module.set_target(
portal30.wwctx_api.get_proc_path(p_url => 'DEPT_RPT.show?p_arg_names=deptnumber&p_arg_values='||vdept,
p_schema => '<application-schema>'),
'CALL');
The function wwctx_api.get_proc_path() internally calls all that is required to form the url.
On second thoughts, why do you need to call a pl/sql procedure to display a confirm box ?
Infact you do not need <iframe> too.
I think the following will work too :-
1> For your button, put the following javascript for the onClick javascript event :-
if (!confirm('This is a test. Do you wish to continue?')) return false;
2> For the Custom PL/SQL Button Event Handler, use the following code :-
declare
vdept number :=null;
begin
vdept := p_session.get_value_as_NUMBER(
p_block_name =>'DEFAULT',
p_attribute_name => 'A_DEPTNO');
portal30.wwa_app_module.set_target(
portal30.wwctx_api.get_proc_path(p_url => 'DEPT_RPT.show?p_arg_names=deptnumber&p_arg_values='||vdept,
p_schema => '<application-schema>'),
'CALL');
end;
NOTE:-
======
1> replace <application-schema> with the name of the schema where you have created the DEPT_RPT report
2> make sure that deptnumber is the name of the bind variable used in the report -
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 -
Calling a function from another class - help!
I realize that this is probably a basic thing for people who have been working with JavaFX for a while, but it is eluding me, and I have been working on it for over a week.
I need to call a function that is in another class. Here's the deal. In EntryDisplayController.java, there are 2 possible passwords that can be accepted - one will give full access to the car, the second will limit functions on the car. So when a password is entered and verified as to which one it is, I need to call a function in MainDisplayController.java to set a variable that will let the system know which password is being used - full or restricted.
So in MainDisplayController.java I have this snippet to see
public class MainDisplayController implements Initializable, ControlledScreen {
ScreensController myController;
public static char restrict;
* Initializes the controller class.
@Override
public void initialize(URL url, ResourceBundle rb) {
// TODO
public void setRestriction(){
restrict = 0;
restrictLabel.setText("RESTRICTED");
public void clearRestriction(){
restrict = 1;
restrictLabel.setText("");
And in EntryScreenDisplay.java I have this snippet:
public class EntryDisplayController implements Initializable, ControlledScreen {
@FXML
private Label passwordLabel ;
static String password = new String();
static String pwd = new String("");
ScreensController myController;
private MainDisplayController controller2;
* Initializes the controller class.
@Override
public void initialize(URL url, ResourceBundle rb) {
setPW(pwd); // TODO
@FXML
private void goToMainDisplay(ActionEvent event){
if(password.equals ("123456")){
controller2.clearRestriction();
myController.setScreen(ScreensFramework.MainDisplayID);
pwd = "";
password = "";
setPW(pwd);
else if(password.equals ("123457")){
controller2.setRestriction();
myController.setScreen(ScreensFramework.MainDisplayID);
pwd = "";
password = "";
setPW(pwd);
else{
password = "";
pwd = "";
setPW(pwd);
When I enter the restricted (or full) password, I get a long list of errors, ending with
Caused by: java.lang.NullPointerException
at velocesdisplay.EntryDisplayController.goToMainDisplay(EntryDisplayController.java:60)
Line 60 is where "controller2.setRestriction(); is.
As always, thanks for any help.
Kind regards,
DavidYou never set the controller2 variable to anything, which is why you get a null pointer exception when you try to reference it.
public static variables (and even singletons) are rarely a good idea as they introduce global state (sometimes they can be, but usually not).
If a static recorder like this can only have a binary value, use a boolean, if it can have multiple values, use an enum.
Some of the data sharing solutions in dependency injection - Passing Parameters JavaFX FXML - Stack Overflow might be more appropriate.
I also created a small framework for roll based solutions in JavaFX which perhaps might be useful:
http://stackoverflow.com/questions/19666982/is-there-a-way-to-implement-a-property-like-rendered-on-javafx
https://gist.github.com/jewelsea/7229260
It was just something I hacked together, so it's not a fully polished solution and you probably don't need something quite so complex.
What you need is a model class shared between the components of your application. Dependency injection frameworks such as afterburner.fx can help achieve this in a fairly simple to use way.
If you don't want to go with a dependency injection framework, then you could use either a static singleton model class for your settings or pass the model class using the mechanism in defined in the passing parameters link I provided. For a model class example, see the ClickCounter class from this example. That example doesn't use FXML, but to put it together with the passing parameters solution, for your restriction model, you would have something like the following:
private class Restricted {
private final ReadOnlyBooleanWrapper restricted;
public Restricted(boolen isRestricted) {
restricted = new ReadOnlyBooleanWrapper(isRestricted);
public boolean isRestricted() {
return restricted.get();
public ReadOnlyBooleanProperty restrictedProperty() {
return restricted.getReadOnlyProperty();
Then in your EntryDisplayController you have:
@FXML
public void goToMainDisplay(ActionEvent event) {
// determine the restriction model as per your original code...
RestictionModel restrictionModel = new RestrictionModel(<appropriate value>);
FXMLLoader loader = new FXMLLoader(
getClass().getResource(
"mainDisplay.fxml"
Stage stage = new Stage(StageStyle.DECORATED);
stage.setScene(
new Scene(
(Pane) loader.load()
MainDisplayController controller =
loader.<MainDisplayController>getController();
controller.initRestrictionModel(restrictionModel);
stage.show();
class MainDisplayController() {
@FXML private RestrictionModel restrictionModel;
@FXML private RestrictLabel restrictLabel;
public void initialize() {}
// naming convention (if the restriction model should only be set once per controller, call the method init, otherwise call it set).
public void initRestrictionModel(RestrictionModel restrictionModel) {
this.restrictionModel = restrictionModel;
// take some action based on the new restriction model, for example
restrictLabel.textProperty.bind(
restrictionModel.restrictedProperty().asString()
If you have a centralized controller for your navigation and instantiation of your FXML (like in this small FXML navigation framework), then you can handle the setting of restrictions on new screens centrally within the framework at the point where it loads up FXML or navigates to a screen (it seems like you might already have something like this with your ScreensController class).
If you do this kind of stuff a lot, then you would probably benefit from a move to a framework like afterburner. If it is just a few times within your application, then perhaps something like the above outline will give you enough guidance to implement a custom solution. -
I working on .net MVC Entity Framework (Code First).
I am not able to get Datacontext in repository classes functions when i call these functions from a static function in controller . I am getting the Exception
"An exception of type 'System.NullReferenceException'
occurred in YYYYYY.Web.dll(Default
project dll) but was not handled in user code
Additional information: Object reference not set to an instance of an object."
i need to call static functions since i had to call some functions asynchronously.Like Report generation
This works perfectly fine when called from a non static function in controller.
Thanks in advance
PunnooseBut when i call a function in repository class, With dependency Injection(NInject).
eg:-
public Batch GetBatchDetail(string batchID)
return this.db.Batches.Where(x => x.ID=batchID).FirstOrDefault();
Db is Datacontext
I am getting the Exception "An exception of type 'System.NullReferenceException'
occurred in YYYYYY.Web.dll(Default
project dll) but was not handled in user code
Please do help me
regards
punnoose -
How to register database plsql function in obiee
Hi,
I've a database plsql function which accepts two date arguments - StartDate and EndDate and return Integer.
I discoverer like we've Plsql function registration tool, where we import function and pass parameter values as arguments in report- how same can be done in Oracle BI Administration tool and BI Answers?
I tried to create logical column as
EVALUATE('YOUR_FUNCTION(%1, %2, %3, %4)' as varchar(20),@{p_1},@{p_2},@{p_3},@{p_4})
it is giving syntax error.
url: How to store OBIEE presentation level variable values in DB
Please help. It is really urgent.
Kind Regards.Hi,
I created 2 session variables p_startym and p_endym of char datatype and called in function(name: RepInitDates). It looks like:
EVALUATE('INIT_DATES_MONID(%1, %2)' AS INTEGER , VALUEOF(NQ_SESSION."p_startym"), VALUEOF(NQ_SESSION."p_endym")).
Now I've presentation variables StartMonth and EndMonth in bi answers report, whose value i want to pass to p_startym and p_endym. What should be the syntax of Bi answers column? Please reply.
Thanks -
How to call java function from PL/sql in oracle applications
I am trying to call a java function from plsql procedure. Can any one explain how to call java function, and in which directory I have to store my java function in oracle applications. Do I need to register that java function from Application developer.
Thanks
Kranthihttp://www.oracle.com/technology/tech/java/jsp/index.html
Good Luck,
Avi. -
Calling PLSQL Procedure with CLOB input parameter from JDBC
Hi..
I've got a PLSQL procedure with a CLOB object as input parameter:
function saveProject (xmldoc CLOB) RETURN varchar IS
I want to call that procedure from my JDBC Application as...
String data = "..."
CallableStatement proc = conn.prepareCall
("begin ? := saveProject (?); end;");
neither
proc.setCharacterStream(2, new StringReader(data, data.length());
nor
proc.setString(2, data);
will work.
The Application throws java.sql.Exception: ... PLS-00306 wrong
number or types of arguments in call 'SAVEPROJECT'
How can I use set setClob method?
The Problem is: with Oracles CLOB implementation I can't create
an Instance, and from the CallableStatement a can't get a
Locator for a CLOB-Object.
This CLOB stuff makes me really nuts!
please somebody help me.. thanks
AlexHi All,
You can not make it like that.
You can not make clob as input parameter.
Do you want an easy way?
This is the easy way.
sample:
function myFunction(S varchar2(40))
return integer as
begin
insert into TableAAA values(S)
--TableAAA only contains 1 column of clob type
end;
This will work the problem with this is the parameter is in
varchar2 right? so there will be limited length for it.
You can do this to call that function:
nyFunction('My String that will be input into clob field');
There's another slight difficult way, I understand that you have
installed Oracle client/server in your system, try to look at
jdbc folder and try to find demo.zip in that folder, you can
find several ways of doing thing with jdbc.
Have a nice day,
Evan
Maybe you are looking for
-
"Unknown Error Occurred" (13014), when trying to open iTunes.
On my iMac 2Ghz Intel Core Duo, I'm getting a "The iTunes application could not be opened. An unknown error occurred. (13014) ". Does anybody know what that error code means? I would like some idea of what I need to do to get back to using my iTunes
-
IBook Shuts Down When Try To Wake From Sleep
I have an iBook 300 that will work perfectly fine while you use it. When you put it to sleep, it sleeps normally, but when I try to wake it the sleep light goes out, nothing shows on screen, I can hear the hard drive spinning and then it shuts down.
-
Af:selectManyChoice and value separator
Hi, I am using JDeveloper 11.1.1.4 and ADF-BC in my project. I am using af:selectManyChoice in one of my pages. By default af:selectManyChoice displays selected values are semi colon separated(;). can this value separator semicolon be customized by a
-
DynPages , buttons problem
hi all, 1.I have copied one exitsing code which has the creation of RoadMap component which has 4 items, only first one is getting highlighted. though i am able to traverse the other items are not gettting highlighted. 2.i have a button row whi
-
Where is x2x, I can't find it in the repositories.
Hi, I preformed a new system installation (systemd) and I can't find x2x. How can I install it? Sorry if I'm missing something. Thanks great community!