Get the returned OUT value from Pl/Sql Procedure in AppMod
Hi,
I am using jdeveloper 10.
In the database i have a procedure like this :
procedure test (v1 in out number,
v2 in number);
And am calling this procedure from application module in this way :
Object[] procArgs = new Object[]{v_1,
v_2
try {
callStoredProcedure("test (?,?)",procArgs);
I want to read the value of the v1 parameter after procedure is executed. Can anyone tell me how can i do it from application module ?
Thanks in advance,
After the call of the proc the value should be in procArgs[0]
Timo
Similar Messages
-
Hi,
How do I return two values from a
stored procedure into an "Execute SQL Task" please? Each of these two values need to be populated into an SSIS variable for later processing, e.g. StartDate and EndDate.
Thinking about stored procedure output parameters for example. Is there anything special I need to bear in mind to ensure that the SSIS variables are populated with the updated stored procedure output parameter values?
Something like ?
CREATE PROCEDURE [etl].[ConvertPeriodToStartAndEndDate]
@intPeriod INT,
@strPeriod_Length NVARCHAR(1),
@dtStart NVARCHAR(8) OUTPUT,
@dtEnd NVARCHAR(8) OUTPUT
AS
then within the SSIS component; -
Kind Regards,
Kieran.
Kieran Patrick Wood http://www.innovativebusinessintelligence.com http://uk.linkedin.com/in/kieranpatrickwood http://kieranwood.wordpress.com/Below execute statement should work along the parameter mapping which you have provided. Also try specifying the parameter size property as default.
Exec [etl].[ConvertPeriodToStartAndEndDate] ?,?,? output, ? output
Add a script task to check ssis variables values using,
Msgbox(Dts.Variables("User::strExtractStartDate").Value)
Do not forget to add the property "readOnlyVariables" as strExtractStartDate variable to check for only one variable.
Regards, RSingh -
Need help to get the user entered value from a input field in Table in OA
I have a table in my OA page.
Here one column is there which should take in put from user.
i.e an item quantity field text input is there which should take the updated value when the add to cart link which is next column in the table. On clicking of the link I am trying to get the updated value entered by user. for the respected row for which addto cart link get clicked.
For that link I have defined some parameter through SPEL,( like this parameter name: item_quantity value : ${oa.MisibeItemSearchVO.ItemQuantity} ) which has fireaction. But when i am clicking the addto cart link I am not getting the current value entered by the user.
Can any body guide me how to get that related value for which the add to cart link got clicked.
for this when i am doing pageContext.getParameter("item_quantity"));
I am not getting the value entered by user.
please suggest me
Thanks!
SmarajeetThe below is my Vo query for item quanity i am using a dummy query "(select null from dual) as ITEM_QUANTITY"
in the below query and item type is number. and this is a messageTextINput in OA page and is maped to ItemQuantity vo attribute.
SELECT idsi.section_item_id
,idsi.inventory_item_id
,(select concatenated_segments from mtl_system_items_kfv mstk
where mstk.inventory_item_id = idsi.inventory_item_id
and mstk.organization_id =idsi.organization_id) ITEM_NAME
,(select description from mtl_system_items_tl mtll
where mtll.inventory_item_id = idsi.inventory_item_id
and mtll.organization_id =idsi.organization_id
and language = USERENV('LANG') ) ITEM_Description
,(SELECT CASE
WHEN instr(msib.segment6,'NAMED USER') > 0 THEN 'NAMED_USER'
WHEN instr(msib.segment6,'PROCESSOR')>0 THEN 'PROCESSOR'
ELSE msib.segment6
END
FROM MTL_SYSTEM_ITEMS_B msib
WHERE msib.INVENTORY_ITEM_ID = idsi.inventory_item_id
AND msib.ORGANIZATION_ID = idsi.organization_id) LICENSE_TYPE
,(SELECT CASE
WHEN instr(msib.segment6,'1 YR') > 0 THEN '1YR'
WHEN instr(msib.segment6,'2 YR') > 0 THEN '2YR'
WHEN instr(msib.segment6,'3 YR') > 0 THEN '3YR'
WHEN instr(msib.segment6,'4 YR') > 0 THEN '4YR'
WHEN instr(msib.segment6,'5 YR') > 0 THEN '5YR'
WHEN instr(msib.DESCRIPTION,'Perpetual') > 0 THEN 'PERPETUAL'
END TERM FROM MTL_SYSTEM_ITEMS_B msib
WHERE msib.INVENTORY_ITEM_ID = idsi.inventory_item_id
AND msib.ORGANIZATION_ID = idsi.organization_id) TERM
,(select qll.operand
FROM qp_list_lines qll
,qp_pricing_attributes qpa
WHERE qll.list_line_id = qpa.list_line_id
AND qpa.product_attr_value = to_char(idsi.inventory_item_id)
AND qll.list_header_id = 439381
AND sysdate between NVL(qll.start_date_active, sysdate) and NVL(qll.end_date_active, sysdate+1)
AND qpa.list_header_id = qll.list_header_id
AND qpa.product_attribute = 'PRICING_ATTRIBUTE1'
AND qpa.product_attribute_context = 'ITEM'
AND NVL(qpa.pricing_attribute_context,'MIXED') = 'MIXED') ITEM_PRICE
,(select null from dual) as ITEM_QUANTITY
,(select currency_code from qp_list_headers_b where list_header_id =439381) currency_code
,(select segment1 from mtl_system_items_b msib
where msib.inventory_item_id = idsi.inventory_item_id
and msib.organization_id =idsi.organization_id) PART_NUMBER
FROM ibe_dsp_section_items idsi
,ibe_dsp_msite_sct_items idmsi
,( select distinct child_section_id
from IBE_DSP_MSITE_SCT_SECTS b
connect by PRIOR child_section_id = parent_section_id
start with parent_section_id =:1
and mini_site_id =1
UNION
select distinct child_section_id
from IBE_DSP_MSITE_SCT_SECTS b
where child_section_id =:1
and mini_site_id =1
) csi
WHERE idsi.organization_id = 101
AND idmsi.section_item_id = idsi.section_item_id
AND idsi.section_id = csi.child_section_id
AND idmsi.mini_site_id = 14409 -
Pcr To Get The Wage Type Value From Previous Years Master Data Records
Hi
I have an issue related to pcr. I want to get the value of a wage type from previous year and it has to be added to another wage type. Tried to write pcr by using the operation TABLE. But i am not able to get the previous years data. Request to help in writing the PCR for the issue.
Thanks
EKP Yadav1 - Create an "Information WT" that will be saved into RT but that has no impact on net pay.
2 - Create a PCR that will be activated on the last pay of the year to read the WT you want and transfer it's information into your Information WT.
3 - Create a PCR that will read the last payroll results (activated with function PLRT) and transfer into the Input Table (IT) the Information WT. -
I can not get the pop out menu from the tools to work. It looks like they are not loaded
Can someone help me know how to get the tool pop out menu to work. It looks like they are not loaded.
You do have to click and hold down on any tool icon with a small triangle in the lower right.
The second method is to right-click on the tool.
Gene -
Returning result sets from PL/SQL procedure to client app.
I was wondering if its possible in Oracle PL/SQL to DECLARE, OPEN a cursor and exit
the procedure without closing the cursor
and then retrieve the resultset from
the client.
Pl let me know..
nullYes, you need to use one OUT parameter in your PL/SQL procedure
to pass the cursor variable to
Java code. You can also return that as a return variable of
PL/SQL function. Get the cursor variable from the resultset using
Types.CURSOR data type and then proceed as usual.
Enrique (guest) wrote:
: Thank you Rajib for your prompt reply. I have been programming
a
: lot in Transact SQL( MSSQL ), but I am new to Oracle and I need
: to migrate MSSQL procedures to Oracle. I will try to use the
: refCursors. One more question, how do I pass the cursors back?
: With OUT parameters? In MSSQL you do not need to specify OUT
: parameters if you are returning a result set.
: Once Again,
: Thank you
: Rajib (guest) wrote:
: : You can return a variable of refcursor type from your PL/SQL
: : procedure (PL/SQL 2.3 or higher) to Java code. Oracle JDBC
has
: a
: : refcursor data type. Now you can use this cursor as a
: resultset.
: : Enrique (guest) wrote:
: : : Hi All,
: : : I am trying to write some store procedures( PL/SQL )
: : that
: : : will select rows from my tables, and then pass then back to
: my
: : : JDBC application as result sets....Does anyone know how can
I
: : do
: : : that? Do I need to use output parameters? Or Return
: functions?
: : : Any help or hint wourl be be gladly appreciate it.
: : : Enrique
: : : Thank you.
null -
Get the report list in a PL/SQL procedure
Hi to all,
I need to get the list of the personal report of a specified user in a PL/SQL procedure, is this possible?
My procedure should delete not "standard" report of a specified portal user.
Then i must have the list of all user's reports and after do my delete logic.
Jhon DhonJhon -
It sounds to me that what you want to do is have a list that is generated based upon the identification of an individual. You can do this a number of ways, but I think you would want to write a straight query to accomplish this rather than a PL/SQL procedure. A query to accomplish what you're looking to do would look something like this:
SELECT
person_name,
person_id_number,
other info you need to see in the output
FROM
table_name (that contains the info you need to see)
WHERE
conditional clauses to obtain only data you wish to see
AND :p_person_id = table_name.person_id_number
The AND clause line will return the employee the user wishes to see based upon that person's ID number. This information is asked for in a parameter form before the report is run. The :p_person_id is referred to as a bind variable. You can read more about this on Metalink or OTN.
HTH,
Steve -
Get value from PL/SQL procedure to shell variable
Hello,
I have one little problem. I want to run plsql procedure from shell program and then I want to fill a shell variable with return value of plsql procedure or function. But I don't want to pass this value to some file and then read it.
Thank'suser9357436 wrote:
Hello,
I have one little problem. I want to run plsql procedure from shell program and then I want to fill a shell variable with return value of plsql procedure or function. But I don't want to pass this value to some file and then read it.
Thank'sLike below?
bcm@bcm-laptop:~$ cat day.sh
set X
var1=$1
SQLPLUS="sqlplus -s"
LOGON="user1/user1 "
day=`$SQLPLUS $LOGON <<EOF
set heading off
set feedback off
set verify off
select 'Have a nice day!' from dual where dummy ='$var1';
exit;
EOF`
echo $day
bcm@bcm-laptop:~$ ./day.sh
Have a nice day!
bcm@bcm-laptop:~$ -
How to get the short text values from F4 SEARCH HELP
Hi Friends,
My requirement is in Module -pool Screen Programming, i have Designed one field in a custom screen and provided a F4 search help to that field..
For eg the F4 help is displayed as below.
Value short text
1 A
2 B
3 C
4 D
5 E
6 F
7 G
When i select the first option (1) then value 1 appears in the field.
now i want the text relevant to the value 1 to appear by the side of the field.
Eg : 1 A (A should appear by the side of the value 1)
How do i achieve it?
Kindly help me.
Regards,
K.S.Kannan.
Edited by: kannan ks on Dec 8, 2008 4:05 PMhi
1) place a field adjacent to your value field on which F4 is operated
so now you will have 2 fields.
iam considering it as for ex: field1 & field2
2)
BOLD one is import in FM call
CLEAR: t_dynpfld_mapping,
e_dynpfld_mapping.
e_dynpfld_mapping-fldname = 'F0001'.
e_dynpfld_mapping-dyfldname = -
> name of field1 (for ex: your 1 value field name)
APPEND e_dynpfld_mapping TO t_dynpfld_mapping.
e_dynpfld_mapping-fldname = 'F0002'.
e_dynpfld_mapping-dyfldname = -
> name of field2 (for ex: your short text field name)
APPEND e_dynpfld_mapping TO t_dynpfld_mapping.
3))))))))
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield =
dynpprog = sy-repid
dynpnr = sy-dynnr
dynprofield = -
> name of field1 (for ex: your 1 value field name)
value_org = 'S'
TABLES
value_tab = itab
dynpfld_mapping = t_dynpfld_mapping
EXCEPTIONS
PARAMETER_ERROR = 1
NO_VALUES_FOUND = 2
OTHERS = 3 -
Not able to get the taxonomy field value of meta data field type
Hi Everyone,
Not able to get the taxonomy filed value from the metadata filed type.
Any one can help me on this.
Label, TermGuid, ValidatedString are showing empty when i debug the code.
Below is the code which i used to get the taxonomy filed valueHi,
Can you please try getting this way?
var taxonomyField = listItem.Fields.GetFieldByInternalName(fieldName) as TaxonomyField;
if (taxonomyField.AllowMultipleValues)
var fieldValuesCollection = listItem[taxonomyField.Title] as TaxonomyFieldValueCollection;
return fieldValuesCollection.Select(x => new Guid(x.TermGuid)).ToList();
else
var fieldValue = listItem[taxonomyField.Title] as TaxonomyFieldValue;
return new List<Guid>() { new Guid(fieldValue.TermGuid) };
Hope it helps!
Thanks,
Avni Bhatt
If this helped you resolve your issue, please mark it Answered -
JDeveloper + WebServices, RETURN multiple rows from pl/sql
I need to return multiple rows from pl/sql procedure or function and publish it as a Web Service through JDeveloper.
I try to use ref cursor, but then found that it is impossible to use ref cursor as a return value in Web Services.
Please, help me to achieve result.Hello. I tried to make commands from article, but got errors
"C:\Program Files\Java\jdk1.6.0_18\bin\java" -jar D:\oracle\Middleware\oracle_common\modules\oracle.webservices_11.1.1\wsa.jar -plsqlAssemble -appName Echo -sql wo -dataSource jdbc/OracleManagedDS -dbConnection jdbc:oracle:thin:@192.168.246.2:1521:data -dbUser syd/manager -style rpc -use encoded
Error: Interface oracle.generated.wo: The class could not be loaded from the class path. -
On my panel i have a jcombobox in upper half(which displays say the address type.) and few text fields on the lower half(which displays the add details). when the user selects a value in the combo box the text fields are populated based on the selection. The user can change the values displayed in the text fields. So before setting the new values in the text fields the last displayed values need to be saved.
I have an ActionListener for my combo which gives me the currently selected value by calling getSelecetdItem()
How can i get the last selcted value of the combobox without using any variable of my own.To update the last displayed details(the address details say) i need to check what type of address the combo had previousely.....
when i display the panel first time the home address is set by default and i have a variable to hold this value..as the user changes the selection i update the variable...I don't want to use this variable..instead if i can get the last selcted value from the event that would be great...
thanks -
Remote Object - not able to get the returned value from java method
Hi ,
I am developing one sample flex aplication that connects to the java code and displays the returned value from the
java method in flex client. Here I am able to invoke the java method but not able to collect the returned value.
lastResult is giving null . I am able to see the sysout messages in server console.
I am using flex 3.2 and blazeds server and java 1.5
Here is the code what I have written.
<?xml version="1.0" encoding="utf-8"?><mx:WindowedApplication xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" backgroundColor="#FFFFFF" initialize="initApp()">
<mx:Script><![CDATA[
import mx.controls.Alert;
import mx.binding.utils.ChangeWatcher;
import mx.rpc.events.ResultEvent;
import mx.messaging.*;
import mx.messaging.channels.*
public function initApp():void {
var cs:ChannelSet = new ChannelSet();
var customChannel:Channel = new AMFChannel("my-amf", "http://localhost:8400/blazeds/messagebroker/amf"); cs.addChannel(customChannel);
remoteObj.channelSet = cs;
public function writeToConsole():void { remoteObj.writeToConsole(
"hello from Flash client");
var returnedVal:String = remoteObj.setName().lastResult; Alert.show(returnedVal);
//[Bindable]
// private var returnedVal:String;
]]>
</mx:Script>
<mx:RemoteObject id="remoteObj" destination="sro" />
<mx:Form width="437" height="281">
<mx:FormItem>
</mx:FormItem>
<mx:Button label="Write To Server Console" click="writeToConsole()"/>
</mx:Form>
</mx:WindowedApplication>
Java code
public
public SimpleRemoteObject(){
super(); }
class SimpleRemoteObject {
public void writeToConsole(String msg) { System.out.println("SimpleRemoteObject.write: " + msg); }
public String setName(){ System.
out.println("Name changed in Java");
return "Name changed in Java";
And I have configured destination in remote-config.xml
<destination id="sro">
<properties>
<source>SimpleRemoteObject</source>
<scope>application</scope>
</properties>
</destination>
Please help me .You are not able to get the returned value because if you see the Remote object help you will realise you have to use result="resultfn()" and fault = "faultfn()"
In this you define what you wish to do.
More importantly in the remote object you need to define which method you wish to call using the method class like this
<mx:RemoteObject id="remoteObj" destination="sro" result="r1" fault="f1" >
<Method name="javaMethodName" result="r2" fault="f2"/>
<mx:RemoteObject>
r2 is the function where you get the result back from java and can use it to send the alert. -
LiveCycle DS , can't get the return value of fill( arg) from Assembler class
Hi all!
I'm a have small problem , can any one help me? Please
I make a project which very similar to Product project(in
example).
1) Have Assembler class: I work correctly
package flex.samples.stock;
import java.util.List;
import java.util.Collection;
import java.util.Map;
import flex.data.DataSyncException;
import flex.data.assemblers.AbstractAssembler;
public class StockAssembler extends AbstractAssembler {
public Collection fill(List fillArgs) {
StockService service = new StockService();
System.out.print(fillArgs.size());
return service.getStocks();
public Object getItem(Map identity) {
StockService service = new StockService();
return service.getStock(((Integer)
identity.get("StockId")).intValue());
public void createItem(Object item) {
StockService service = new StockService();
service.create((Stock) item);
public void updateItem(Object newVersion, Object
prevVersion, List changes) {
StockService service = new StockService();
boolean success = service.update((Stock) newVersion);
if (!success) {
int stockId = ((Stock) newVersion).getStockId();
throw new DataSyncException(service.getStock(stockId),
changes);
public void deleteItem(Object item) {
StockService service = new StockService();
boolean success = service.delete((Stock) item);
if (!success) {
int stockId = ((Stock) item).getStockId();
throw new DataSyncException(service.getStock(stockId),
null);
some require class is ok.
2) I configure in data-management-config.xml
<destination id="stockinventory">
<adapter ref="java-dao" />
<properties>
<source>flex.samples.stock.StockAssembler</source>
<scope>application</scope>
<metadata>
<identity property="StockId"/>
</metadata>
<network>
<session-timeout>20</session-timeout>
<paging enabled="false" pageSize="10" />
<throttle-inbound policy="ERROR" max-frequency="500"/>
<throttle-outbound policy="REPLACE"
max-frequency="500"/>
</network>
</properties>
</destination>
3) My client app:
I use :
<mx:ArrayCollection id="stocks"/>
<mx:DataService id="ds" destination="stockinventory"/>
ds.fill(stocks); --> Problem here
When I run this app, The StockAssembler on the server work
correctly (i use printout to debug) . But variable stocks can't get
the return value,it is a empty list.
Please help me!Hi,
The executeQueryAsync method is “asynchronous, which means that the code will continue to be executed without waiting for the server to
respond”.
From the error message “The collection has not been initialized”, which suggests that the object in use hadn’t been initialized after the execution of the executeQueryAsync method.
I suggest you debug the code in browser to see which line of code will throw this error, then you can reorganize the logic of the code to avoid using the uninitialized object.
A documentation from MSDN about Using the F12 Developer Tools to Debug JavaScript Errors
for your reference:
http://msdn.microsoft.com/en-us/library/ie/gg699336(v=vs.85).aspx
Best regards
Patrick Liang
TechNet Community Support -
How to get the return values from a web page
Hi all :
how to get the return values from a web page ? I mean how pass values betwen webflow and web page ?
thank you very much
Edited by: jingying Sony on Apr 15, 2010 6:15 AM
Edited by: jingying Sony on Apr 15, 2010 6:18 AMHi,
What kind of web page do you have? Do you have possibility to for example make RFCs? Then you could trigger events (with parameters that could "return" the values) and the workflow could react to those events. For example your task can have terminating events.
Regards,
Karri
Maybe you are looking for
-
Macbook pro monitor not working
prior my macbook was working flawlessly, no issues. but now its screen is not turning on, not even being picked up. the camera on the laptop works, everything else works perfectly, but the screen does not respond. im out of apple warranty so i apple
-
Photoshop it wont open. I click on it and nothing
photoshop it wont open. I click on it and nothing
-
I am using the CVI plug-in for MSVC. My application requires that I toggle a set of digital lines based on a user's input. For a variety of reasons I would like to initialize my DAQ task handles at the start of the program so that when I need to to
-
I create a scrollable text that is in a text frame using the Folio Overlay with the settings of Vertical Scroll and Use the Document Setting for its position. When I click on the Preview icon on the Folio Overlay panel, it comes up with the with a p
-
What are payment options for the upgrade?
I was wondering if I can buy the 2.0 upgrade for the $9.95 on the iTunes store with a iTunes gift card? Or will I need to use a credit card for it?