How to set variable value in an XML array
Hi,
Please let me know how to set the value for a xml array element using assign activity inside a for-each block in BPEL 11g
I tried to set the variable value for result element using the below condition but i encountered selection failure message
$outputVariable.payload/ns1:Student['i']/ns1:result or
$outputVariable.payload/ns1:Student[$i]/ns1:result
And the xsd used is as below
<xsd:complexType name="StudentCollection">
<xsd:sequence>
<xsd:element name="Student" type="Student" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="Student">
<xsd:sequence>
<xsd:element name="Name" type="xsd:string"/>
<xsd:element name="location" type="xsd:string"/>
<xsd:element name="mark" type="xsd:string"/>
<xsd:element name="result" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
Thanks,
Dhana
Hi,
At the back of button specify the following parameter:-
CMD 1 Execute_planning_function
Planning_function_name 1 xyz
Var_name 1 variable_name
var_value 1 blank
Can also refer to link below:-
http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/b0a89464-f697-2910-2ba6-9877e3088954?quicklink=index&overridelayout=true(can refer to page 20)
http://www.sdn.sap.com/ddc5564a-337d-4cf9-a34e-2dab64df09be/finaldownload/downloadid-a61a6724ba8e7b7fbd9c5df9590ab50d/ddc5564a-337d-4cf9-a34e-2dab64df09be/irj/scn/go/portal/prtroot/docs/library/uuid/f0881371-78a1-2910-f0b8-af3e184929be?quicklink=index&overridelayout=true
Hope it may help
Similar Messages
-
How to set variables values via VBA.
Anybody please help.
How to set variables values via VBA in workbook. SAP Netweaver 2004s.Pass variable values with VBA and BI 7.0 funtions to Query
At first a remark u2013 Iu2019ve read a lot of threads saying that passing values to a query can be done by using VBA code only. Iu2019ve tested it but Iu2019m not sufficient with the new BEX 7.0 API and therefore I use a mixture of BEX 7.0 funtionality and VBA. I create a BEX 7.0 design item button passing the values to a query u2013 I hide this button somewhere on the sheet or on a hidden sheet and I then raise the event to click the button from VBA code. Works fine and the maintenance is easier if something changes in the API in the future again.
How to start:
Switch to design mode in BEX Analyzer:
Implement a BEX 7.0 design item u201Cbuttonu201D
Click on the button to implement the properties
Make the input for the commands
data_provider = dataprovider_1
cmd = process_variables
subcmd = var_submit
No comes the part with the variables u2013 Letu2019s assume a query has 4 variables but you only want to change 1 with the button u2013 an organizational unit for instance.
Make a range somewhere in the excel with the following structure:
Name Index Value
VAR_NAME_1 1 Variablename
VAR_VALUE_EXT_1 1 variablevalue
Value should contain the name of your variable of course and u201Cvalueu201D the value of your variable
Set a name for this range with EXCEL functionality but without the header:
Back to the properties of the button: Insert the name of the range with the variables in the field Command Range:
If you have more variables to process you can of course enhance your Filterrange!
In the left upper Corner you have a name for your button:
Now you can raise the button-click in vba like this:
Application.Run "'" & ThisWorkbook.Name & "'!Sheet2.BUTTON_35_Click"
regards, Lars -
How to set the value in the xml node.
Hi
I am having the application PDF which can be submitted by user using the button. while submitting
i am using below code to set the value in the xml node.
xfa.data.assignnode("employee.id","123",0):
So its generating the xml like below.
<employee>.
<id>123</id>.
</name>
</employee>
Now i need to generate the xml like below.
<employee id= "123" >
</Name>
</employee>
So how to set/create the id node like above?
Advance Thanks.
Regards,
DhiyaneHi Dhiyane,
You will have to set the contains property if the id node to "metaData", that is;
xfa.data.assignNode("employee.id","123",0);
xfa.data.employee.id.contains = "metaData";
Very clumsy if you have a number of them, in which case you might want to look at using E4X.
Good luck
Bruce -
How to set variable values in Stored Procs
Hi all,
please excuse my newbie questions - I've spent too long using SQL Server......
Anyway,
I'm playing with SP basics and was wondering how I can set a variable value in a stored proc, ideally getting a value from a table or some select .
for instance...........
CREATE OR REPLACE PROCEDURE RPT_SP_ANT_TESTING
P1 IN NUMBER,
P2 IN VARCHAR2
IS
TmpNum NUMBER;
TmpStr VARCHAR2(255);
BEGIN
--How do set these?
SET TMPNUM := SELECT Count( * ) FROM ALL_TABLES;
SET TMPSTR := P2 + '_APPENDED';
INSERT INTO TEST_TABLE
( STRINGFIELD, NUMBERFIELD )
VALUES
( TmpStr, TMPNUM )
END;
Regards
DCSome ways are...
setting directly
x := 1;
setting from a select use INTO clause
select 1 into x from dual
setting from a select into a collection type use BULK COLLECT INTO
select name bulk collect into lName from your_table.
It would be better if you read the document.
Thanks,
Karthick. -
How to set variable value in BEX analyzer for IP Layout
Hi All,
I have created a simple planning function to copy data from one account to another and I have used mandatory selection variable for Fiscal year /period. When I execute the planning function through Planning modeler I get the prompt for the variable and the planning functions execute without errors and return the values. But now when I design the Bex workbook using my Input ready query that have button to execute the planning function,I don't get the prompt for the mandatory selection variable. I need to set the variable vaule in design mode then the function return the values. Is there way to get the prompt for the variable when I choose to execute the planning function. Also is there a option in Web application designer too?
Please let me know what I'm missing.
Appreciate you help.
regards,
BalajiHi,
At the back of button specify the following parameter:-
CMD 1 Execute_planning_function
Planning_function_name 1 xyz
Var_name 1 variable_name
var_value 1 blank
Can also refer to link below:-
http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/b0a89464-f697-2910-2ba6-9877e3088954?quicklink=index&overridelayout=true(can refer to page 20)
http://www.sdn.sap.com/ddc5564a-337d-4cf9-a34e-2dab64df09be/finaldownload/downloadid-a61a6724ba8e7b7fbd9c5df9590ab50d/ddc5564a-337d-4cf9-a34e-2dab64df09be/irj/scn/go/portal/prtroot/docs/library/uuid/f0881371-78a1-2910-f0b8-af3e184929be?quicklink=index&overridelayout=true
Hope it may help -
How to set the value of process variables/payload using a managed bean?
Hello,
Someone can give me an example about how to set the values of a process payload in a managed bean?
thank you!Try this:
jsf page:
<af:selectOneChoice label="Select Suburb"
requiredMessageDetail="Select a suburb"
valueChangeListener="#{selectOneChoiceBean.onValueChanged}"
validator="#{selectOneChoiceBean.validate}"
unselectedLabel="None" autoSubmit="true"
binding="#{selectOneChoiceBean.selectOneChoice}"
value="#{selectOneChoiceBean.value}">
<f:selectItems value="#{selectOneChoiceBean.selectionList}"/>
</af:selectOneChoice>
backing bean:
public class SelectChoiceBean {
private List<SelectItem> selectionList;
private String value = "B";
private RichSelectOneChoice selectOneChoice;
public SelectChoiceBean() {
initSelectionList();
public void setSelectionList(List<SelectItem> selectionList) {
this.selectionList = selectionList;
public List<SelectItem> getSelectionList() {
return selectionList;
public void onValueChanged(ValueChangeEvent valueChangeEvent) {
System.out.println(valueChangeEvent.getNewValue());
// Add event code here...
public void validate(FacesContext facesContext, UIComponent uIComponent,
Object object) {
// Add event code here...
private void initSelectionList() {
selectionList = new ArrayList<SelectItem>();
selectionList.add(new SelectItem("A", "A label"));
selectionList.add(new SelectItem("B", "B label"));
selectionList.add(new SelectItem("C", "C label"));
public void setValue(String value) {
this.value = value;
public String getValue() {
return value;
public void setSelectOneChoice(RichSelectOneChoice selectOneChoice) {
this.selectOneChoice = selectOneChoice;
public RichSelectOneChoice getSelectOneChoice() {
return selectOneChoice;
} -
How to Read Variable Values in WAD 7.0 Using JavaScript
I found a how to: How to Read Variable Values in WAD 7.0 Using JavaScript on SDN.
I get a Javascript error:
bics.getElementsByTagName is not a function
vars = bics.getElementsByTagName("VARIABLES")[0]; // <VARIABLES>
Thats my script:
function currency()
var varnm = "SFS_CP_CURR"; // Name of the variable to be read
root = document.childNodes[0]; // <HTML>
body = root.getElementsByTagName("BODY")[0]; // <BODY>
xml = body.getElementsByTagName("XML")[0]; // <XML>
bics = xml.childNodes[0]; // <BICS_VIEW>
vars = bics.getElementsByTagName("VARIABLES")[0]; // <VARIABLES>
varl = vars.getElementsByTagName("VARIABLE"); // gives no. of variable in DP
for ( i = 0; i <= varl.length; i++ ) // Loop one by one
vari = vars.getElementsByTagName("VARIABLE")<i>;
varnam = vari.attributes[0].text; // get variable name
mem = vari.getElementsByTagName("MEMBER")[0];
varval = mem.attributes.getNamedItem("name").value; // read variable value
if (varnam == varnm) //check varname in loop needs to be read
if (varval == "ZMON") // check for value1 and fire command1
SFS_CP_M();
if (varval == "ZKON") // check for value2 and fire command2
SFS_CP_K();
break;
Where's the mistake?I'm afraid I haven't made my question understood clearly.
What I am looking for is a method to get the value of variable inside excel (e.g. put it into a cell / range of a worksheet, so that we can reference it and use it as an input for planning function execution).
Please advice.
Thanks in advance,
Shady -
In flex, How to set a value to one parameter, the parameter
defined in a cffunction in a cfc file, In the cffunction there are
much cfargument, I want set a value to one of them, such as the
cfc:
<cffunction access="remote" name="myShow" output="false"
returntype="struct">
<cfargument name="ID" type="numeric" default=0>
<cfargument name="GoodsID" type="string" default="">
<cfargument name="DestTime" type="string" default="">
<cfargument name="DestCount" type="numeric" default=1>
How I set a value to only parameter one of them , such as set
GoodsID when use mx:remoteObject.
Thanks for your helpGot maybe a solution for you, I have just tested it.
So, the idea is to use intermediate variables. Imagine Var1 and Var2 variables that you refresh with your more or less complicated queries. Then what you can do is to refresh your final variable Var3 with a query using your intermediate variables. Here is an example for Oracle:
select #Var1+#Var2 from dual
This way you can make a chain of dependent variables: Var3 is using Var2 and Var2 is using Var1.
Hope it helps.
Shamil -
Variable values in composite.xml property
Hi, i've got the similar proble to: variable values in composite.xml property
Static value for property
<property name="oracle.webservices.auth.password" type="xs:string"
many="false" override="may">admin</property>
<property name="oracle.webservices.auth.username" type="xs:string"
many="false" override="may">admin</property>
Expect result:
<property name="oracle.webservices.auth.password" type="xs:string"
many="false" override="may">$variable</property>
<property name="oracle.webservices.auth.username" type="xs:string"
many="false" override="may">$variable</property>
i've probe the suggestion but cant get the specific solution.... may soneon can't help me!!Hi
Thank you for the reply, I also would like to use the DVM solution to get the dynamic values, but the problem is how should I use this variable after this variable get the value from DVM?
Does it have a property to override "oracle.webservices.auth.username" property or how could I use "oracle.webservices.auth.username" to get the variable value?
I'm not sure if you understand my question, feel free to let me know.
Thanks again for your reply. -
How to set dynamic color , based on xml element
Hi,
We have a requirement, where based on certain conditions, a cell will be shown in a specific color. We would like the coloir to be based on an XML element. The xml element will have values like '#FF00FF' etc..
We tried using xsl attribute with the following syntax ,
<xsl:attribute xdofo:ctx="block"name="color"><?stdcolor?></xsl:attribute><?end if?>
where stdcolor is the xml element, but when we use this , this is giving a syntax error.
Let us know, if this is possible or is there any other alternate way to do this.
Regards,
- Vasu -Hi Vasu,
http://winrichman.blogspot.com/2008/09/how-to-set-dynamic-color-based-on-xml.html
use the following :)
<xsl:attribute xdofo:ctx="block" name="color" ><xsl:value-of select="stdcolor" /></xsl:attribute>
TO get the colors you wanted , you can refer to
http://www.w3schools.com/Html/html_colors.asp -
How to set default values for boolean columns
I'm trying to deploy some content types and columns into a site with a feature. All it's ok, except that I'm trying to set a default value for boolean columns with no success.
I've tried to set default value at column level:
<Field ID="{EFE23A1D-494E-45cf-832E-45E41B17F0CF}" Name="ScopeSpanish" DisplayName="Se publican noticias en español"
Type="Boolean" Hidden="FALSE" Group="Columnas ShaCon" >
<Default>TRUE</Default>
</Field>
and at content type level:
<FieldRef ID="{EFE23A1D-494E-45cf-832E-45E41B17F0CF}" Name="ScopeSpanish" DefaultValue="TRUE" Required="TRUE" />
But in any case, when i create a new item with this content type, default value is applied.
Can anyone tell how to set default values for boolean columns?
Thanks in advance,
Regards,
SergioIn the field definition you can set
<Default>1</Default>
or
<Default>0</Default>
How to set the default value Null? -
How to set cookie value in one page and retrieve in another page using setA
How to set cookie value in one page and retrieve in another page using setActionListener?
I have tried with following code srcpage.jspx->destpage.jspx
srcpage.jspx
<af:table value="#{bindings.DepartmentsView1.collectionModel}"
var="emp" rows="#{bindings.EMPView1.rangeSize}"
first="#{bindings.EMPView1.rangeStart}"
emptyText="#{bindings.DepartmentsView1.viewable ? 'No rows yet.' : 'Access Denied.'}">
<af:column sortProperty="EmployeeName" sortable="false"
headerText="Cookie Testing">
<af:commandLink text="#{emp.EmployeeName}" action="success">
<af:setActionListener from="#{emp.EmployeeName}"
to="#{cookie}"/>
</af:commandLink>
</af:column>
</af:table>
espage.jspx
<af:outputText value="Test Cookie Value: #{cookie}"/>
,Here Test Cookie Value prints the following instead of its original String value
{JSESSIONID=javax.servlet.http.Cookie@7da288, oracle.uix=javax.servlet.http.Cookie@399f62}
I have passed employee name "Robert" to cookie in srcpage.jspx,but it prints "JSESSIONID....." instead of "Robert" in destpage.jspx
Thanks in advance
KaleeHi,
"cookie" is a reserved name. If you want to write to a session scope attribute called "cookie" then you have to call #{sessionScope.cookie}. If you want to use EL to set and read from cookies then you will have to use
#{cookie.cookieName}
Note that #{cookie} writes to and returns a map
check this: http://www.informit.com/articles/article.aspx?p=30946&seqNum=7
Frank -
How to set the root path of XML document when calling Inserting procedure
Hi,
I was create a procedure to insert XML Document in to DBMS Tables, but i am not able to set the Start root element in calling procedure.
My calling procedure is
exec insXmldoc('pmc_sample.xml', 'pmc')
When i am calling this procedure i got this error
11:23:54 Error: ORA-29532: Java call terminated by uncaught Java exception: oracle.xml.sql.OracleXMLSQLException: Start of root element expected.
ORA-06512: at "SYS.DBMS_XMLSAVE", line 65
ORA-06512: at "SCOTT.INSPROC", line 8
ORA-06512: at line 2
I am checking my XML file using XML Validator. My XML file was parsed with out errors.
Please give the solution,and tell me where i did wrong in my calling procedure.
suppose i have this XML file in local E drive ,how to set the path for that XML file in my calling procedure.Hi, I am doing the code likthis,please give the solution.
SQL> create or replace procedure insProc(xmlDoc IN CLOB, tableName IN VARCHAR2) is
2 insCtx DBMS_XMLSave.ctxType;
3 l_ctx dbms_xmlsave.ctxtype;
4 rows number;
5 begin
6 insCtx := DBMS_XMLSave.newContext(tableName); -- get the context handle
7 rows := DBMS_XMLSave.insertXML(insCtx,xmlDoc); -- this inserts the document
8 DBMS_XMLSave.closeContext(insCtx); -- this closes the handle
9 end;
10 /
Procedure created.
SQL> begin
2 insProc('/usr/tmp/ROWSET.xml', 'emp');
3 end;
4 /
begin
ERROR at line 1:
ORA-29532: Java call terminated by uncaught Java exception: oracle.xml.sql.OracleXMLSQLException:
Start of root element expected.
ORA-06512: at "SYS.DBMS_XMLSAVE", line 65
ORA-06512: at "SCOTT.INSPROC", line 7
ORA-06512: at line 2
Kishore B -
How to set the value of something in a component from the main application?
Hi,
Maybe I've been working on this too long, but I can't figure
out how to set the value of the text property of a text input field
in a component from my main application in an mx:Script block. I
have a component called Login in the components folder, and I need
to set the text value of empNum. In my mxml declaration at that the
top, I've declared these components as xmlns:c="components.*" So
logically, the property I'm trying to set is c.Login.empNum.text. I
can't figure out the correct syntax to get this to work, and I've
tried everything I can think of. Does anyone have any suggestions?
I'm thinking this should be an easy one, and I'm just missing
something.
Thanks!
HolliDid you try giving it an id ?
<c:MyLogin id="loginScreen" /c>
So later you can do loginScreen .empNum.text = "my text"
Laurent, -
How to set the Value in Dropdownbyindex
Hi Experts,
I am New to Webdynpro-ABAP.
I have one Dropdownbyindex field. I need to set the value from BAPI. how to set that values in Dropdown..
I need Basic step-by-step procedure.
Regards,
P.ManivannanHi,
1. First import the BAPI in to WD component using create->service call.
2.The BAPI import, export and Table parameters will be set in to the Component Controller context.Then drag this BAPI node to your view.
3.In the 'texts' property of DDbyindex bind the BAPI output node which will be the Table parameter of the BAPI.It could be under CHANGING node.
4.In WDDOINIT method just click the code wizard and enter the method name which you will give when importing the BAPI.Automatically the values from the BAPI will be loaded into your Dropdown when you run the application.
Regards,
Dinesh
Maybe you are looking for
-
IPod Nano directory does not show loaded tracks
I have a 7th Gen iPod Nano that was formatted by iTunes for Windows 7 that does not show the tracks loaded on it once it is ejected. Apple has replaced the Nano twice with no change. Working with AppleCare Support I have removed iTunes and everything
-
itunes will not open due to dep security
-
Does Mac OS 10.6.2 disable Flash Player?
I cannot play a .swf file under OS 10.6.2 using the Flash Player.plugin ver. 10.0.32.18 but can play the same file under OS 10.5.6 using Flash Player.plugin ver. 9.0.151. I can also play it under OS 10.6.1 and under 10.4.11. Is this an OS issue or an
-
CS5 image files don't open normally
every time I open up an image file in CS5 all I get is a file box containing a couple of large pixel looking shapes. When I hover the mouse over the file my image appears but disappears again when the cursor moves out of the file. I cannot work on an
-
Is there a way to create digitally signed PDFs by using the options at the "Print" menu to "Save as PDF" that is available at certain apps ? If there is no built-in solution by Apple, which applications do you use to digitally sign PDFs ? I searched