How do I get cumulative value
hi,
I have table with columns as Employee_id,Salary,Commission.
I need query which will show total sal of each Employee_id and cumulative value of total.
Thanks
Ram
select empno,
sal,
sum(sal) over (partition by null order by rownum rows unbounded preceding) running_total
from emp;
ordering by rownum in the partition clause is also another way thereby allowing one to order in any other way for reporting.
--Samson
Similar Messages
-
How to use a cumulative value in a formula
hi, experts
I have a question about how to use a cumulative value in a formula. Below is the example:
wk1 wk2 wk3 wk4 wk5....wk n
sales order 5 10 15 10 5
build plan 8 8 10 15 10
result 3 1 -4 1 6
result row is what I want to get, the formula is:
wk1 result = wk1 build plan - wk1 sales order
wk2 result = wk1 build plan + wk2 build plan - (wk1 sales order + wk2 sales order)
wk3 result = wk1 build plan + wk2 build plan + wk3 build plan - (wk1 sales order + wk2 sales order + wk3 sales order)
I've already ticked the cumulative in properity of the key figures. It seems like that the cumulative results only can display, but can't be used in formula. Could you please help me? Many many thanks !!Hi
In properties of that formula, there is option called 'formula collision' there you select 'formula from compiting result'. I think this will solve the problem. -
How can i get all values from jtable with out selecting?
i have one input table and two output tables (name it as output1, output2). Selected rows from input table are displayed in output1 table. The data in output1 table is temporary(means the dat wont store in database just for display purpose).
Actually what i want is how can i get all values from output1 table to output2 table with out selecting the data in output1 table?
thanks in advance.
rajaYou could set the table's data model to be the same:
output2.setModel( output1.getModel() ); -
How can I get command values from a VI executed by reference ? NEWBIE
Hi,
I'm running a sub-vi in a "Secondary Front Face" (excuse for the
translation if not correct, I'm working on a French version). In order
to run this VI, I pass a reference. All is working fine but I don't
know how can I get the values entered by the user in this VI ?
Actually I run a main VI wich contains a "Secondary Front Face" (this
SFF is contained in a tabbed pane). In my diagramm, I pass a reference
to another VI (by the name of the file *.vi). If my user enter a word
in a text field, I would like to be able to get it in my main app.
Thanks for your help.Hello,
You might take a look at the following tutorial for more information about calling a VI by reference. It's got some great visuals and examples.
Tutorial: Calling a VI by Reference
You might also consider just calling the secondary VI as a simple subVI, if you can spare the memory space when loading the main application, as this is the easiest way to input and output VI values.
I hope this helps! Please let me know if I can be of any further assistance.
Liz F
National Instruments -
Please, How do i get the values from a h:selectManyCheckbox ?
How do i get the values (selected or not) of a <h:selectManyCheckbox> tag and show them .For instance
i have the folowing options :
<h:selectManyCheckbox
id="cartas"
layout="pageDirection"
value="#{store.cartas}">
<f:selectItems
value="#{cartas}"/>
</h:selectManyCheckbox>
<h:message styleClass="validationMessage" for="newsletters"/>with my faces-config.xml:
<managed-bean>
<description></description>
<managed-bean-name>cartas</managed-bean-name>
<managed-bean-class>java.util.ArrayList</managed-bean-class>
<managed-bean-scope>application</managed-bean-scope>
<list-entries>
<value-class>javax.faces.model.SelectItem</value-class>
<value>#{cartas0}</value>
<value>#{cartas1}</value>
<value>#{cartas2}</value>
<value>#{cartas3}</value>
</list-entries>
</managed-bean>
<managed-bean>
<managed-bean-name>cartas0</managed-bean-name>
<managed-bean-class>javax.faces.model.SelectItem</managed-bean-class>
<managed-bean-scope>none</managed-bean-scope>
<managed-property>
<property-name>label</property-name>
<value>Semanal</value>
</managed-property>
<managed-property>
<property-name>value</property-name>
<value>200</value>
</managed-property>
</managed-bean>
<managed-bean>
<managed-bean-name>cartas1</managed-bean-name>
<managed-bean-class>javax.faces.model.SelectItem</managed-bean-class>
<managed-bean-scope>none</managed-bean-scope>
<managed-property>
<property-name>label</property-name>
<value>As bruxas</value>
</managed-property>
<managed-property>
<property-name>value</property-name>
<value>201</value>
</managed-property>
</managed-bean>
<managed-bean>
<managed-bean-name>cartas2</managed-bean-name>
<managed-bean-class>javax.faces.model.SelectItem</managed-bean-class>
<managed-bean-scope>none</managed-bean-scope>
<managed-property>
<property-name>label</property-name>
<value>Exercise</value>
</managed-property>
<managed-property>
<property-name>value</property-name>
<value>202</value>
</managed-property>
</managed-bean>
<managed-bean>
<managed-bean-name>cartas3</managed-bean-name>
<managed-bean-class>javax.faces.model.SelectItem</managed-bean-class>
<managed-bean-scope>none</managed-bean-scope>
<managed-property>
<property-name>label</property-name>
<value>Gusman Park</value>
</managed-property>
<managed-property>
<property-name>value</property-name>
<value>203</value>
</managed-property>
</managed-bean>Thanks for the atention!! All the best!!Hi,
In your backing bean you will need to add a new variable to bind your control to, I think this variable needs to be of teh "HtmlSelectManyCheckbox" type. The on your jsp page you can add binding="#{myBean.myVariable}".
When you want to get the values of the selectMany in your backing bean, you can call the getSelectedValues() function on your HtmlSelectManyCheckbox variable.
in backing bean:
private HtmlSelectManyCheckbox hsmc;
public HtmlSelectManyCheckbox getHsmc(){
return hsmc;
public void setHsmc(HtmlSelectManyCheckbox hsmc){
this.hsmc = hsmc;
public void someFunction(){
Object[] obs = hsmc.getSelectedValues();
}On jsp page:
<h:selectManyCheckbox
id="cartas"
layout="pageDirection"
value="#{store.cartas}"
binding="#(myBean.hsmc}">
<f:selectItems
value="#{cartas}"/>
</h:selectManyCheckbox> -
How we can get the values from one screen to another screen?
hi guru's.
how we can get the values from one screen to another screen?
we get values where cusor is placed but in my requirement i want to get to field values from one screen to another screen.
regards.
satheesh.Just think of dynpros as windows into the global memory of your program... so if you want the value of a field on dynpro 1234 to appear on dynpro 2345, then just pop the value into a global variable (i.e. one defined in your top include), and you will be able to see it in your second dynpro (assuming you make the field formats etc the same on both screens!).
-
How do I get the values from a form?
How do I get the values from a form?
You can try using request method..
request.getParameter("yourFormInputName");
Try this. -
How do i get the value in a variable that I don't know the name of til run
I have a record type( pr_team) defined in a package - anchored to a table.
I want to be able to go through each of the fields in it one at a time. I get the list of fields from the table definition from cursor as follows
CURSOR c_fields IS
SELECT column_name
FROM all_tab_cols
WHERE owner = 'CDS'
AND table_name = 'TEAM';
r_fields c_fields%ROWTYPE;
So first returned value is team_id
how can I get this value when all I know the field name is 'pr_team.' || r_fields.column_name
cheers
SimonOracle Database 10g Express Edition Release 10.2.0.1.0 - Production
SQL> CREATE OR REPLACE PACKAGE package_name
2 AS
3 r_emp emp%ROWTYPE;
4 END package_name;
5 /
Package created.
SQL> SET SERVEROUTPUT ON SIZE UNLIMITED;
SQL> DECLARE
2 v_empno emp.empno%TYPE;
3 v_ename emp.ename%TYPE;
4 BEGIN
5 SELECT *
6 INTO package_name.r_emp
7 FROM emp
8 WHERE ROWNUM = 1;
9
10 EXECUTE IMMEDIATE
11 'BEGIN ' ||
12 ' :v_empno := package_name.r_emp.empno; ' ||
13 ' :v_ename := package_name.r_emp.ename; ' ||
14 'END;'
15 USING OUT v_empno, OUT v_ename;
16
17 DBMS_OUTPUT.PUT_LINE ('v_empno => ' || v_empno);
18 DBMS_OUTPUT.PUT_LINE ('v_ename => ' || v_ename);
19 END;
20 /
v_empno => 7369
v_ename => SMITH
PL/SQL procedure successfully completed.
SQL> -
How can I get the value of "Warehose" column in a form
How can I get the value of "Warehouse" column in the form below (I mean what table that contain this value):
Production Supervisor >> Batches >> (Button) Material Details >> (Button) Line Allocations
Well, for more clearly! My problem is I must have the Unit Cost of Items, so I've got it in the cm_cmpt_dtl (table), but if I want to, I must create a relation that require 2 filed, they're Item_ID and Whse_Code.
There's no problem with Item_ID, but Whse_Code seem to be the Mission Impossible (hix, I hate that film!!!!)
I wonder if It was right to post this topic here. But anyway I just post my question here, hope I could get some help.wow, many, many, many.... and many thanks!
Just add a tiny modify to check out the Batch_type
doc_id = (select batch_id from gme_batch_header where batch_no='&batch_number' and batch_type = 0)
Because the batch_no can be duplicated as we also create Batch and Filrm Planned Order.
Many thanks for your support!
P/S: Sorry for my terrible English :P -
How to add get Day value in a Date object?
Hi,
I am writing a sql statement that has two date values. One I am getting it from the database. The format in the database is MM/DD/YYYY. My first question is how do I convert the format into the java date format, YYYY-MM-DD. The second question is I need to find out what the day is and add 1 to it. How do I get Day value in a Date object?
Thanks.Look at "SimpleDateFormat" and "parse" in the archives.
-
How do you get the value of a selected list item?
I have a drop-down list that the user can choose from. How do I get the value of what they selected? I thought I could do this by using the NAME_IN function, but I'm getting FRM-40105 Unable to resolve reference to item X. I don't know what I'm doing wrong.
Thanks!Hi,
You can use an WHEN-LIST-CHANGED trigger, attached to the list-item itself. And, in this trigger, you can use the name of the item to refer its value.
For example:
:block_name.list_item_name
John -
How can we get the value of the key field in a custom data model using governance API?
Dear Team,
How can we get the value of the key field in a custom data model, to be used for manipulation of the change request fields using governance API?
Any kind of help would be sincerely appreciated.
Thanks & Regards,
Tushar.Hi Michael,
Thanks for direction. Let me give more context on this as I'm interested to get more details..One of the issue was to read cross entity field values on UI based on user action and set other entity field behaviour...It is similar to what is being posted here.
For ex: Reading MTART from Basic Data UIBB in MM MDG UI and set the field properties in some other custom entities say ZZETEST. This cannot be done using UI BADI as it only supports single entity at a time and not cross entity. So alternatively we found a solution where we can enhance existing PLMB feederclass cl_mdg_bs_mat_feeder_form by reading the model and the entity as needed as it it proved that it supports cross entity UI field behaviours and so business requirements.
This is a workaround for now.
So the question is How do we achive it using governance API for cross entity field behiaviours.?or what is the right way doing this.
Can we do that using governance API and its' methods?
In the Governance API doc you provided below has referring to below external model as part of gevernance API.
The active or inactive data (before or during the derivation or the check) can be read
with the external data model interface IF_USMD_MODEL_EXT with the method READ_CHAR_VALUE and
the corresponding READ_MODE parameter. To avoid unnecessary flushes (derivations), the NO_FLUSH
parameter should b
e set to ‘X’.
Thanks
Praveen -
How can i get the value stored in the session object using its sessionid
how can i get the value stored in the session object using its sessionid by running stand alone java application
myforum wrote:
how can i get the value stored in the session object using its sessionid by running stand alone java applicationThis does not seem to make sense! You need at least to give a lot more detail of what you are doing. -
How do i get probative-value off my laptop
How do i get probative-value.sydneyflooring.info off my laptop?
Try this?
* http://www.alot.com/faq
*http://www.alot.com/toolbar
* http://www.pchell.com/support/alot.shtml
Firefox v
* getfirefox.com -
How do i get the value of that field
in JSP i have a field like below..
<input type="hidden" id="grpId<%=Index%>" value="<bean:write name='GrpList' property='groupId'/>"/>
In Action class , how do i get the value of that field (i.e id) ?
String value =reques.getparameter (//what ??);i dont want to change the jsp.
concern is , as the name of the id is dynamic .....so can i get the value in the Action class ?
is there any trick exists ?
I will try not to change any jsp code but will do changes in Action class
Message was edited by:
Unknown_Citizen
Maybe you are looking for
-
Serial number not working on cs3 download for mac
I downloaded cs3 through prodesign tools but my serial number is not working does that mean I installed it on too many computers. I only have it on my old desktop now which I'm using to print from my epson 3800 and I'm a little scared to uninstall th
-
Web Service to transmit a file (a very large file)
Greetings, Is is possible to use a web service to transmit a file, sometimes a very large file? If so, what are the security implications of doing such a thing? Thanks, Charles
-
Satellite P870-335 - Function key actions not visible
Hi I have a P870-335 in which I placed a SSD disk and installed Windows 8 Pro (now 8.1) and was able to get most devices working with the drivers that I found by the Toshiba autodetect program. However one of the items still missing is that I can not
-
When I run anything CPU intensive (eg, Skype, Matlab etc), my T410s (integrated graphics) appears to be overheating and crashing. It gets very hot and then the screen goes black and it turns off. See the attached chart of heat, 90C seems far too hig
-
Keep getting pop up "Password Incorrect"
I keep getting a pop up with the following message: "Password Incorrect", Enter the password for the Exchange "Hanover Activesync" account. However I already have the correct password permanently set in my Activesync profile. Seems to happen when ph