How to aggregate the measue when click '∑' ?
Hi Experts,
How to aggregate the measue when click '∑' ?
For example:
In table view.
A-----------A1-----------2
A-----------A2-----------3
ATotal-------------------5
B-----------B1-----------2
B-----------B2-----------3
BTotal-------------------5
GrTotal------------------10(It is not my expected result.)
However, GrTotal is not my expect result, the correct result is 5 , not 10. How to implement my requrement? Thanks.
Hi,
If you want the result to be the average of your sub-totals (?) then I think the only way you can do is is by using a union query to give the 'illusion' of a grand-total.
Using this mechanism you can create a grand-total using whatever logic you wish, you then just combine the result and with cunning use of headings / formatting make it look exactly like a standard functionality total.
Helpful?
regards,
Robert.
Similar Messages
-
How to Get the value when clicking on the link
I had a problem with when clicking on the link.
I need get the link value to the controller when clicking on the link.
I am displaying the database columns in jsp using repeater in links.
I am displaying the data like this:
RED
BLUE
GREEN
these are three links.when clicking on the link RED. RED should go to the controller.
After getting RED to the controller i will get the RED value from the database.my requirement is like that only
I have just given the example of emp and dept
emp(empno,zone_group_id,zone_id,deptno,ename,emp_p_ind,last_update_datetime);
dept_emp(empno,dept_no,loc,dname,sal_emp,grade,last_update_datetime);
CREATE OR REPLACE VIEW emp_zone AS
SELECT e.empno,
(select zone_group_id from price_zone_group where rownum = 1) zone_group_id,
d.loc zone_id,
d.grade,
d.last_update_datetime,
FROM dept_emp d
emp e
WHERE d.empno=e.empno
AND e.emp_p_ind = 'Y'
WITH READ ONLY;
Now
my requirement is to get the data of emp_zone view and needs to store those data into some other temp table
if any of the above base table got updated deleted or inserted then the view last_updatetime also will get updated but problem is why im not using base table
direct because it is having huge data and it performance issue .i have to get the value on the basis of view only and using some logic -
How to make my "notepad-program" clean the textarea when clicking on "ny"
Hi!
I'm having a problem cleaning the textarea when clicking on "ny" (new) in the menubar. What am I doing wrong? Could someone help me solve this problem?
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
import java.io.*;
public class AnteckningsProgram
implements ActionListener{
static JFrame frame;
static JTextArea textArea;
public void skapaVisaGUI () {
frame = new JFrame ("Anteckningsprogram");
frame.setSize (340, 240);
frame.setVisible (true);
frame.setTitle ("Ra Anteckningsprogram");
Toolkit tk = Toolkit.getDefaultToolkit ();
Image bild = tk.getImage("r.png");
frame.setIconImage(bild);
JTextArea textArea = new JTextArea ();
frame.add (textArea, "Center");
JMenuBar cm = createMenuBar();
//frame.add(cm, BorderLayout.NORTH);
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
public JMenuBar createMenuBar () {
JMenuBar menyBar;
JMenu meny;
JMenuItem oppna;
JMenuItem quit;
JMenuItem ny;
menyBar = new JMenuBar ();
JMenu arkiv = new JMenu("Arkiv");
oppna = new JMenuItem ("Oppna");
quit = new JMenuItem("Quit");
ny = new JMenuItem("Ny");
ny.setActionCommand("Ny");
ny.addActionListener(this);
quit.setActionCommand("Quit");
quit.addActionListener(this);
//arkiv.setMnemonic(KeyEvent.VK_U);
arkiv.add(oppna);
arkiv.addSeparator();
arkiv.add(quit);
arkiv.addSeparator();
arkiv.add(ny);
menyBar.add(arkiv);
frame.setJMenuBar(menyBar);
return menyBar;
public void actionPerformed(ActionEvent e) {
if ("Ny".equals(e.getActionCommand())) {
createTextArea();
//annars går vi vidare till metoden quit
else {
quit();
protected void quit() {
System.exit(0);
protected void createTextArea() {
JTextArea textArea = new JTextArea ();
textArea.setText("fdfdsfdfsdf");
public static void main(String[] args) {
//anroppar metoden createandshowGUI
AnteckningsProgram ap = new AnteckningsProgram();
ap.skapaVisaGUI();
}The basic problem here is 'scope'. The scope of an attribute is 'Java 101' by the way. I recommend you start on the basics *(<- link)* and leave GUIs aside for a while.
-
How to deselect the text when I start the program?
how to deselect the text when I start the program?
photo:wants the blue background could not be seen:
Code Form:
Public Class Form2
Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If ComboBox1.SelectedItem = "The Sims 4" Then
Form3.Show()
Else
End If
If ComboBox1.SelectedItem = "The Sims 3" Then
Form4.Show()
Else
End If
End Sub
End Class
There's a lot wrong with all of that.
I'm sorry that I won't be able to help...
Still lost in code, just at a little higher level. -
How to make it selected when clicked and open popup
Hi,
I 've a form in the parent page with many form elements.
I've 2 radio buttons with values "Yes" and "No". I am opening a modal popup when clicked on "Yes" radio button. The modal popup is opening fine.
But when I click "Yes", it' s not selected. After modal popup is closed, when I return to parent page, the option "Yes" is still not selected.
How to make it selected when clicked and open popup?Perhaps try moving the application to your preferred desktop and then right-click it's dock icon > options > Assign to This Desktop.
-
What to do if we can t remember the answers to the secrets questions and we do not receive the reset when clicking send reset to rescue email ( can t remember what is the rescue email we gave ) ?
The Three Best Alternatives for Security Questions and Rescue Mail
1. Send Apple an email request at: Apple - Support - iTunes Store - Contact Us.
2. Call Apple Support in your country: Customer Service: Contact Apple support.
3. Rescue email address and how to reset Apple ID security questions.
A substitute for using the security questions is to use 2-step verification:
Two-step verification FAQ Get answers to frequently asked questions about two-step verification for Apple ID. -
How to register the recipient when create job by function
I am now use JOB_OPEN , JOB_SUBMIT and JOB_CLOSE to create a job in the program. And need to post the result of the report to the person by email.
Can you tell me how to register the recipient when create the job.
( in sm36, it is easily to do but how to do in coding? )
regards,
slamHi
I think in Back ground using the above fun modules you can't send a mail to the receipient.
see the use of the above fun modules;
IF p_bjob = 'X'.
CONCATENATE sy-cprog sy-datum sy-uzeit
INTO jobname SEPARATED BY '_'.
CALL FUNCTION 'JOB_OPEN'
EXPORTING
jobname = jobname
IMPORTING
jobcount = jobcount
EXCEPTIONS
cant_create_job = 1
invalid_job_data = 2
jobname_missing = 3
OTHERS = 4.
CALL FUNCTION 'GET_PRINT_PARAMETERS'
IMPORTING
out_archive_parameters = arc_params
out_parameters = print_params
valid = valid
EXCEPTIONS
archive_info_not_found = 1
invalid_print_params = 2
invalid_archive_params = 3
OTHERS = 4.
IF valid = chk.
SUBMIT ybrep
WITH < sel Screen>
AND RETURN
USER sy-uname
VIA JOB jobname
NUMBER jobcount
TO SAP-SPOOL
SPOOL PARAMETERS print_params
ARCHIVE PARAMETERS arc_params
WITHOUT SPOOL DYNPRO.
CALL FUNCTION 'JOB_CLOSE'
EXPORTING
jobcount = jobcount
jobname = jobname
strtimmed = 'X'
EXCEPTIONS
cant_start_immediate = 1
invalid_startdate = 2
jobname_missing = 3
job_close_failed = 4
job_nosteps = 5
job_notex = 6
lock_failed = 7
invalid_target = 8
OTHERS = 9.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ELSE.
MESSAGE i029 WITH jobname.
ENDIF.
ELSE.
MESSAGE s000 WITH text-003.
STOP.
ENDIF.
ENDIF.
Reward points if useful
Regards
Anji -
How to reload the screen when changing languages in JavaFX 2?
I'm beginner with javaFX and i need to change language of the screen. but i have no idea how to reload the screen when the language was changed. The application have a button where have the language available. I want just refresh screen when the user change language.
Here is the start method to show the stage.
@Override
public void start(Stage stage) throws Exception
this.stage = stage;
Locale locale = Locale.getDefault();
ResourceBundle rb = ResourceBundle.getBundle("resources/Label",locale);
loader = new FXMLLoader(getClass().getResource("FXMLDocument.fxml"),rb);
root = (Parent)loader.load();
FXMLDocumentController controller = (FXMLDocumentController) loader.getController();
controller.setMain(this);
scene = new Scene(root);
stage.setScene(scene);
stage.show();
here is the function to change the language(in the same class with start function),the rb is the new ResourceBundle:
public void refresh(ResourceBundle rb)
//change the language here
1. I don't want to use the resourceBundle to get value in resource file and set label in scene one by one.like following:
this.btnLabel.setText(rb.getString(key.test));
2. I don't want to reload the scene,like following:
public void refresh(ResourceBundle rb)
try
loader = new FXMLLoader(getClass().getResource("FXMLDocument.fxml"),rb);
root = (Parent)loader.load();
scene.setRoot(root);
FXMLDocumentController controller = (FXMLDocumentController) loader.getController();
controller.setMain(this);
catch(Exception err)
err.printStackTrace();
So do we have a solution to just set the resourceBundle and reload the scene easier?
Thanks and best regards!Your option 2 (reload the FXML for the scene using the new resource bundle as a parameter), is the way this would normally be done and what I would recommend.
Failing that, you could use option 1 of individually resetting the label text of labeled items (I don't really recommend this).
Why don't you want to use option 2?
Perhaps it is because there is some internal state of the UI which differs from the initial state when the the UI is first loaded (e.g. user has typed text in a text field and you want to preserve that). If that's the case you will need to either go with your option 1 of individually resetting the label text of labeled items, or implement something which preserves the UI state and user data by saving it in memory or to disk, reloading the UI via the FXMLLoader (essentially your option 2), then restoring the UI state and user data to what it was before the language change. Preserving and restoring the modified state seems complicated to me if you have a lot of state, so I wouldn't really advise this approach unless you really needed it. -
How can I watch movies in germany with native tone, english? Any one knows how to switch the language when renting a movie?
I wonder the Format Tables macros on my site could be adapted?
http://www.grainge.org/pages/authoring/word/word_macros.htm
If not, I have used Macro Express to format tables in Rh. No reason it could not be used in Word.
See www.grainge.org for RoboHelp and Authoring tips
@petergrainge -
How to aggregate the PO history in batch
How to aggregate the PO history in batch? thanks !
I know this transaction,but it can't select all items to aggregate,i must select one item and aggregate, so it is not very convenient,so i write a program to batch process it
Thansk! -
PDF stored in database and to view the PDF when clicking on a link
Is it possible to save a PDF document in the database as a blob column and to retrieve the PDF when clicking on the link
Example
Above method is possible for images
See: http://www.oracle.com/technology/obe/apex/apex31nf/apex31blob.htm.
But can I reach the same for PDF documents?
Thanks in advance for your response.
Kind regards,
IloonHello Andy,
This Upload and Download Files is very useful feature in APEX.
However, is there a way of displaying PDF files first in the report by clicking the corresponding link
in the table?
I mean, is it possible to view PDF files first by clicking the link before deciding to download them?
As we see, this approach is used by most websites and after opening and viewing a PDF file, we can save them.
Thanks.
Shurick.
Edited by: Shurick on Sep 28, 2009 12:51 PM -
how to solve the problem when opening program illustrator cs6
ERROR: 16
It is WINDOWS 8.1 / 64 BIT
help pleaseThanks, Jeff! The file Adobe Setup Error.log contains the following information:
02/14/14 07:20:26:474 | [INFO] | | OOBE | DE | | | | 8860 | DEVersion: 5.0.0.0
02/14/14 07:20:26:475 | [INFO] | | OOBE | DE | | | | 8860 | Loading library from C:\Program Files (x86)\Common Files\Adobe\OOBE\PDApp\DECore\DE5\Setup.dll
[ 8860] Fri Feb 14 07:20:26 2014 INFO
::START TIMER:: [Total Timer]
CHECK: Single instance running
CHECK : Credentials
Load Deployment File
CHECK : Another Native OS installer already running
Create Required Folders
Assuming uninstall mode
Lookup for master payload
[ 8860] Fri Feb 14 07:20:26 2014 ERROR
DW040: The product "{893B3B44-0A1E-404B-8FE8-0A74509102A9}" is not installed. Cannot proceed with the uninstall
[ 8860] Fri Feb 14 07:20:26 2014 INFO
:: END TIMER :: [Total Timer] took 6.90443 milliseconds (0.00690443 seconds) DTR = 579.338 KBPS (0.56576 MBPS)
-------------------------------------- Summary --------------------------------------
- 0 fatal error(s), 1 error(s), 0 warning(s)
ERROR: DW040: The product "{893B3B44-0A1E-404B-8FE8-0A74509102A9}" is not installed. Cannot proceed with the uninstall
Please search the above error/warning string(s) to find when the error occurred.
These errors resulted in installer Exit Code mentioned below.
Exit Code: 33 - The product is not installed, cannot uninstall.
Please see specific errors and warnings for troubleshooting. For example, ERROR: DW040 ... -
How to get the path when i select a directory or a file in a JTree
How to get the path when i select a directory or a file in a JTree
import java.lang.*;
import java.io.*;
import javax.swing.*;
import javax.swing.tree.*;
import java.awt.HeadlessException;
import javax.swing.event.*;
import java.awt.*;
import java.awt.event.*;
import java.util.Iterator;
* @author Frederic FOURGEOT
* @version 1.0
public class JTreeFolder extends JPanel {
protected DefaultMutableTreeNode racine;
JTree tree;
protected JScrollPane scrollpane;
final static int MAX_LEVEL = 1; // niveau max de descente "direct" dans l'arborescence
* Sous-classe FSNode
* @author Frederic FOURGEOT
* @version 1.0
private class FSNode extends DefaultMutableTreeNode {
File file; // contient le fichier li� au noeud
* Constructeur non visible
private FSNode() {
super();
* Constructeur par initialisation
* @param userObject Object
FSNode(Object userObject) {
super(userObject);
* Constructeur par initialisation
* @param userObject Object
* @param newFile File
FSNode(Object userObject, File newFile) {
super(userObject);
file = newFile;
* Definit le fichier lie au noeud
* @param newFile File
public void setFile(File newFile) {
file = newFile;
* Renvoi le fichier lie au noeud
* @return File
public File getFile() {
return file;
public JTree getJTree(){
return tree ;
* Constructeur
* @throws HeadlessException
public JTreeFolder() throws HeadlessException {
File[] drive;
tree = new JTree();
// cr�ation du noeud sup�rieur
racine = new DefaultMutableTreeNode("Poste de travail");
// cr�ation d'un noeud pour chaque lecteur
drive = File.listRoots();
for (int i = 0 ; i < drive.length ; i++) {
FSNode node = new FSNode(drive, drive[i]);
addFolder(drive[i], node); // on descend dans l'arborescence du lecteur jusqu'� MAX_LEVEL
racine.add(node);
// Gestion d'evenement sur JTree (on �coute les evenements TreeExpansion)
tree.addTreeExpansionListener(new TreeExpansionListener() {
public void treeExpanded(TreeExpansionEvent e) {
// lorsqu'un noeud est ouvert
// on descend dans l'arborescence du noeud jusqu'� MAX_LEVEL
TreePath path = e.getPath();
FSNode node = (FSNode)path.getLastPathComponent();
addFolder(node);
((DefaultTreeModel)tree.getModel()).reload(node); // on recharche uniquement le noeud
public void treeCollapsed(TreeExpansionEvent e) {
// lorsqu'un noeud est referm�
//RIEN
// alimentation du JTree
DefaultTreeModel model = new DefaultTreeModel(racine);
tree.setModel(model);
setLayout(null);
// ajout du JTree au formulaire
tree.setBounds(0, 0, 240, 290);
scrollpane = new JScrollPane(tree);
add(scrollpane);
scrollpane.setBounds(0, 0, 240, 290);
* Recuperation des sous-elements d'un repertoire
* @param driveOrDir
* @param node
public void addFolder(File driveOrDir, DefaultMutableTreeNode node) {
setCursor(new Cursor(3)); // WAIT_CURSOR est DEPRECATED
addFolder(driveOrDir, node, 0);
setCursor(new Cursor(0)); // DEFAULT_CURSOR est DEPRECATED
* Recuperation des sous-elements d'un repertoire
* (avec niveau pour r�cursivit� et arr�t sur MAX_LEVEL)
* @param driveOrDir File
* @param node DefaultMutableTreeNode
* @param level int
private void addFolder(File driveOrDir, DefaultMutableTreeNode node, int level) {
File[] fileList;
fileList = driveOrDir.listFiles();
if (fileList != null) {
sortFiles(fileList); // on tri les elements
// on ne cherche pas plus loin que le niveau maximal d�finit
if (level > MAX_LEVEL - 1) {return;}
// pour chaque �l�ment
try {
for (int i = 0; i < fileList.length; i++) {
// en fonction du type d'�l�ment
if (fileList[i].isDirectory()) {
// si c'est un r�pertoire on cr�� un nouveau noeud
FSNode dir = new FSNode(fileList[i].getName(), fileList[i]);
node.add(dir);
// on recherche les �l�ments (r�cursivit�)
addFolder(fileList[i], dir, ++level);
if (fileList[i].isFile()) {
// si c'est un fichier on ajoute l'�l�ment au noeud
node.add(new FSNode(fileList[i].getName(), fileList[i]));
catch (NullPointerException e) {
// rien
* Recuperation des sous-elements d'un noeud
* @param node
public void addFolder(FSNode node) {
setCursor(new Cursor(3)); // WAIT_CURSOR est DEPRECATED
for (int i = 0 ; i < node.getChildCount() ; i++) {
addFolder(((FSNode)node.getChildAt(i)).getFile(), (FSNode)node.getChildAt(i));
setCursor(new Cursor(0)); // DEFAULT_CURSOR est DEPRECATED
* Tri une liste de fichier
* @param listFile
public void sortFiles(File[] listFile) {
triRapide(listFile, 0, listFile.length - 1);
* QuickSort : Partition
* @param listFile
* @param deb
* @param fin
* @return
private int partition(File[] listFile, int deb, int fin) {
int compt = deb;
File pivot = listFile[deb];
int i = deb - 1;
int j = fin + 1;
while (true) {
do {
j--;
} while (listFile[j].getName().compareToIgnoreCase(pivot.getName()) > 0);
do {
i++;
} while (listFile[i].getName().compareToIgnoreCase(pivot.getName()) < 0);
if (i < j) {
echanger(listFile, i, j);
} else {
return j;
* Tri rapide : quick sort
* @param listFile
* @param deb
* @param fin
private void triRapide(File[] listFile, int deb, int fin) {
if (deb < fin) {
int positionPivot = partition(listFile, deb, fin);
triRapide(listFile, deb, positionPivot);
triRapide(listFile, positionPivot + 1, fin);
* QuickSort : echanger
* @param listFile
* @param posa
* @param posb
private void echanger(File[] listFile, int posa, int posb) {
File tmpFile = listFile[posa];
listFile[posa] = listFile[posb];
listFile[posb] = tmpFile; -
How to determine the policy, when it is applied?
Hi!
Perform Group Policy.
When do I need to reboot when
to logoff, and when the policy is executed after
without further action?
How to determine the policy, when it is applied?Hi,
Group policy settings that affect computer settings section apply at reboot and refrresh every 90 min (default refresh interval for computers). Group policy settings that affect user settings section apply at user logon to the domain.
You can use RSOP.MSC or command-line gpresult /? to find out what/which GPO settings have been applied to the computer/user belonging to a domain.
More information can be found below:
http://msdn.microsoft.com/en-us/library/aa373481(v=vs.85).aspx
http://technet.microsoft.com/en-us/library/cc940895.aspx
Hope this help.
Regards,
Calin -
How to validate the field when i am populating the data cursor to block
Hi,
I am populating data cursor to multi record block.
Block contain 5 items. I am populating data cursor to block for 4 items. User will enter one item value that is quantity field.
If user enter negative values and decimal points in quantity filed i need to display message to user item level.
Please do the needful how to do it.902434 wrote:
Hi,
I am populating data cursor to multi record block.
Block contain 5 items. I am populating data cursor to block for 4 items. User will enter one item value that is quantity field.
If user enter negative values and decimal points in quantity filed i need to display message to user item level.
Please do the needful how to do it.If you want to validate at entry level then use When-Validate-Item trigger and check the input and show message. Like
If :quentity <0 then
message('do not enter negative value');
message('do not enter negative value');
raise form_trigger_failure;
end if;Why u open same thread again ? not closing one.. check this one
</a>
How to validate the field when i am populating the data cursor to block
Hopes this helps
If someone's response is helpful or correct, please mark it accordingly.
Maybe you are looking for
-
My time capsule is dead. When I plug it in, there is no power. The macbook just died yesterday before I could get another backup & wifi. It won't turn the power on any more. Is there a reset/reboot button hidden somewhere? Or do I have to bring i
-
Submitting Pdf form fields to a MySQL database via PhP
Hi there, I have recently created a Pdf in Adobe LiveCycle which looks great, and I have added a submit button which is set up to send all the form data in HTML to a PhP file on the server side. The PhP file then collects the form data and inserts it
-
Re: Is it possible to have two Skype To Go Access ...
I spend part of the year in USA and part of the year in UK, and would like a "Skype to Go" number in each country. I originally setup Skype in the UK, but my current "Skype to Go" number is in USA. I can't remember specifying where the exchange/numbe
-
Search for BAPI to access it throw Java pro gramme
dear all Iam search for a BAPI to be used in search for particular customer using one of its attribute wich is stored in kna1 table and also search in its details stored in ADRC taple if possible. and also BAPI for search for equipment using one of i
-
Xbox360 doesn't see iPhone as an mp3 player
My iPod nano used to work fine with the xbox360, with my iPhone, the xbox360 sees it as a camera and I can browse the pictures inside but it is not recognized as a "portable device". Does anyone else have this problem? I just upgraded the iPhone firm