ALV OO: How can I set totals and subtotals in program
Hello together,
I have a report using cl_gui_alv_grid. I would like to have button that leads to a predefined total-/subtotal configuration.
1. How can I switch on/off a sortation for a column dynamically?
2. How can I switch on/of the criteria for subtotals dynamically?
Thanks for your help!
Hi,
On click on the button
1) change the field catalog adding DO_SUM e.g.fcat-DO_SUM = 'X'
2) Change the sort and add subtotal e.g.wa_sort-SUBTOT = 'X'
Reload the ALV.
Regards,
Jovito
Similar Messages
-
How can I set PCTUSED and PCTFREE in Warehouse databases?
Hi,
There are many Schemas in our database and some are used for OLTP and some others are used for Warehouse. Also our tablespaces are Local Managed.
Could you help me please how can I set PCTUSED and PCTFREE for Warehouses and OLTP.
What are your suggestions? What should be optimum?
DB version is 9.2.0.8.
thanks & regardsIf you are using locally managed tablespaces with ASSM then the pctused parameter would no longer apply. In all cases dictionary vs locally managed with or without ASSM you should set pctfree based on how much of the data row column values are present at initial row insertion and how likely any column is upated to a larger size after initial row insertion.
In a warehouse I would expect most of the tables to have 100% of the row data present at initial insert and for the data to never be updated. For tables meeting this requirement a pctfree of 3 - 5% would likely be a good choice. I never like to use 0% since the day may come when you add another column to the table.
With OLTP tables the ideal pctfree value varies more from table to table. Most table so seem to work well enought with the default 10% but I have seen tables that need 50% pctfree to prevent row migration since only the key column values existed at initial insert and most all the other column data was added later.
Where ASSM is not in use I like to set pctused to 95 - pctfree. Over the last 15 years I am not sure I ever found a need to change the pctused from this once set. I have set a lot of tables up over the years from the old default of 40% to use 60% and 80% before resetting everything during a server platform migration as I mentioned above.
HTH -- Mark D Powell -- -
I have an old airportextrem how can i set up and this massge on my iphone a70ebe
an old airportextrem how can i set up and this massge on my iphone a70ebe
What exact model of the AirPort Extreme do you have? If it is an 802.11g version, you will NOT be able to administer it from your iPhone as its version of the AirPort Utility is not compatible.
-
How can I set up and access separate gmail accounts on one shared computer?
My wife and I share one computer. She has one gmail account and I have a separate gmail account. After logging on, how can I establish different icons that will take one of us directly to our own gmail account? What should be used as a homepage or can one go directly to each gmail account directly from an identification icon on the desktop or on a taskbar?
I suggest setting your wife up with her own login on the PC. There are other ways, but this would be the cleanest, in my opinion.
If you do this, she can use her own iTunes, her own Apple ID, etc. -
How can I set iPad and iPhone with IOS6 to do not remember wifi and proxy credential
My company want to implement the Password Policy to limit the failure logon count.
Such as Lock users if they try logon with invalid password for 3 times.
The problem occur on iPad and iPhone my iPad using IOS6. and user had change their password.
iPad and iPhone remember the Wifi and proxy credential. and try to connect with the saved credential.
I monitor on my system and found Wifi connection try 2 times with saved credential and prompt for new password
When I enter the corrected new password . So I the proxy server detected the invalid login 3 times or more and lock those account.
So could anyone told me on how to set iPad and iPhone to do not save the user credential... ?
Thanks very much
WeerayutEnable Airplane mode, then turn on WiFi
-
How can i add total in Module Pool Programming
Hai abapers,
My problem is I have 15 fields in a tablecontrol.The 15th field is total field...
When ever user enter a values in remaing fields,the 15 the field must be updated...
how can i achieve in module pool programming..................
i have one more problem.That is when user pressing any key.my content in table control r clearing..i need to restrict clearing values..how can i achieve it ...
Waiting for y r favourable replies
Regards
Maruthimaruthi,
1. when user pressing any key.my content in table control r clearing..i need to
restrict clearing values..how can i achieve it ...
Ans. When ever you press button it will go first to PAI event and will go back to
PBO.So in PBO event you might have wriiten some coding that will get
process and updated in Table control.That time your updated data will get
removed.
For this take all your function codes of your buttons on screen and write
condition
if sy-ucom ne 'ADD' or
sy-ucom ne 'Delete'.
********Here you keep your PBO code
endif.
Now it will work fine.
2.When ever user enter a values in remaing fields,the 15 the field must be updated
Ans)After you entered the data in 14 fields some event has to get trigger then
only you can achieve your goal.
In PBO write
If SY-UCOM is eq 'ADD'.
collect all fields records and add here
move total value to 15th record .
Endif.
when you press ADD button you will achieve .
Pls. reward if useful -
The area is set for San Juan, PR, but it doesn't recognize the date and time.
This indicates a network issue. Ensure DNS settings are set to Automatic and the regional settings are correct.
-
My grandson's school needs him to have his own email address. For some reason, his is not able to use my address. I do not want him to have general access to the internet. His older brother caused my computer to be infected with a virus in a very short time. It took three weeks and one hundred dollars to get the use of my computer back.
I do not want him to have access to the internet, but his school wants him to have an email address to communicate with him about school work. I am concerned that once he has an email address, someone (not the school) will send him a web site address in a message and he will be able to just click on it to get into the internet.You can use an email program (e.g. Outlook Express or Windows Live or Thunderbird) and disable HTML for that email (text only mode) to access the email account. You can create a new email account if your your ISP supports it or use a online service that allows POP3 access with an email program (most popular services allow that).
-
It´s a on/off illuminating ssystem control. Shure the user will need a calendar programing tool to program weekdays, holidays, etc. on of functions.
Hi Galileo,
See the following for Lookout side of things:
http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&RPAGEID=135&HOID=506500000008000000DBE90000&USEARCHCONTEXT_CATEGORY_0=_9_&USEARCHCONTEXT_CATEGORY_S=0&UCATEGORY_0=_9_&UCATEGORY_S=0
As for FieldPoint, you can talk to it from Lookout in couple of ways -- either directly using the native FieldPoint object, or via OPC using the OPCFieldPoint object.
Based on the timers from above, you would turn On/Off the relays (on the RLY-420 module of your FieldPoint).
That's in a nutshell. Write back if you have specific questions.
Good luck!
Khalid -
How can i set action on UITaBar and get event from that
Hi All,
I m doing one apps in which i have to add three UITabBarItem and this is UITabBarSystemItem.
Now i cannot understand that how can i set action and get event from the?
And how can i set various views on three tab bar item.
I have to use UITabBar means i have to use UINavigationController+UITabBar
My code id
tabBar =[[UITabBar alloc] initWithFrame:CGRectMake(0,370,320,50)];
tabBar.backgroundColor =[UIColor blackColor];
UITabBarItem *search =[[UITabBarItem alloc] initWithTabBarSystemItem:UITabBarSystemItemSearch tag:0];
UITabBarItem *recents =[[UITabBarItem alloc] initWithTabBarSystemItem:UITabBarSystemItemRecents tag:1];
UITabBarItem *favorites =[[UITabBarItem alloc] initWithTabBarSystemItem:UITabBarSystemItemFavorit es tag:2];
tabBar.items =[[NSArray arrayWithObjects:search,recents,favorites, nil] retain];
tabBar.selectedItem = search;
[myView addSubview:tabBar];
[tabBar release];
I add a action:
UITabBarItem *search =[[UITabBarItem alloc] InitWithTabBarSystemItem:UITabBarSystemItemSearch tag:0 action:@selector(select:)];
So it error: Warning -no'InitWithTabBarSystemItem:tag:action:' method fount
So any can help me regarding it?Thanks RickMaddy very much.
I read and do with sample at the View Controller Programming Guide . But when run it only view TabBar with title but haven't got any TabBarItem on it. I searched a few example about TabBar and i did, but i want do a form with a button then press on button it view a form with 2 TabBarItem on TabBar and press each TabBarItem will show correlative form page 1, page 2.
UITabBarController *tabBarControl = [[[UITabBarController alloc] initWithNibName:nil bundle:nil] autorelease];
tabBarControl.title = @"Tab bar";
ViewControl1 *view1 = [[[ViewControl1 alloc] initWithNibName:@"ViewControl1" bundle:nil] autorelease];
ViewControl1 *view2 = [[[ViewControl1 alloc] initWithNibName:@"ViewControl2" bundle:nil] autorelease];
tabBarControl.viewControllers = [NSArray arrayWithObjects:view1,view2,nil];
[self.navigationController pushViewController:tabBarControl animated:YES]; -
How can i set a password when i open mozilla firefox homepage
how can i set username and password to the homepage of mozilla firefox
hello saranghaekijenia, can i ask what you are trying to achieve by setting a password? maybe there is a better way...
-
IN ALV HOW WE CAN TOTALS AND SUBTOTALS?
HI EXPERTS?
IN ALV HOW WE CAN TOTALS AND SUBTOTALS?Hi
FOR DISPLAYING TOTALA AND SUBTOTALS IN ALV USE THIS:
data: wa_fieldcat type slis_fieldcat_alv,
it_fieldcat type slis_t_fieldcat_alv.
data: wa_sort type slis_sortinfo_alv,
it_sort type slis_t_sortinfo_alv.
wa_fieldcat-do_sum = 'X'.
append wa_fieldcat to it_fieldcat.
wa_sort-fieldname = 'KUNNR'.
wa_sort-tabname = 'IT_FINAL'.
wa_sort-subtot = 'X'.
append wa_sort to it_sort.
AN EXAMPLE RELATED TO IT:
This ALV program have all the basic report requirements such as page heading, page no, sub-total and a grand total.
This is a basic ALV with the followings:-
- Page Heading
- Page No
- Sub-Total
- Grand Total
REPORT ZALV.
TYPE-POOLS: SLIS.
DATA: G_REPID LIKE SY-REPID,
GS_PRINT TYPE SLIS_PRINT_ALV,
GT_LIST_TOP_OF_PAGE TYPE SLIS_T_LISTHEADER,
GT_EVENTS TYPE SLIS_T_EVENT,
GT_SORT TYPE SLIS_T_SORTINFO_ALV,
GS_LAYOUT TYPE SLIS_LAYOUT_ALV,
GT_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV,
FIELDCAT_LN LIKE LINE OF GT_FIELDCAT,
COL_POS TYPE I.
DATA: BEGIN OF ITAB,
FIELD1(5) TYPE C,
FIELD2(5) TYPE C,
FIELD3(5) TYPE P DECIMALS 2,
END OF ITAB.
DATA: BEGIN OF ITAB1 OCCURS 0.
INCLUDE STRUCTURE ITAB.
DATA: END OF ITAB1.
DATA: BEGIN OF ITAB_FIELDCAT OCCURS 0.
INCLUDE STRUCTURE ITAB.
DATA: END OF ITAB_FIELDCAT.
Print Parameters
PARAMETERS:
P_PRINT AS CHECKBOX DEFAULT ' ', "PRINT IMMEDIATE
P_NOSINF AS CHECKBOX DEFAULT 'X', "NO SELECTION INFO
P_NOCOVE AS CHECKBOX DEFAULT ' ', "NO COVER PAGE
P_NONEWP AS CHECKBOX DEFAULT ' ', "NO NEW PAGE
P_NOLINF AS CHECKBOX DEFAULT 'X', "NO PRINT LIST INFO
P_RESERV TYPE I. "NO OF FOOTER LINE
INITIALIZATION.
G_REPID = SY-REPID.
PERFORM PRINT_BUILD USING GS_PRINT. "Print PARAMETERS
START-OF-SELECTION.
TEST DATA
MOVE 'TEST1' TO ITAB1-FIELD1.
MOVE 'TEST1' TO ITAB1-FIELD2.
MOVE '10.00' TO ITAB1-FIELD3.
APPEND ITAB1.
MOVE 'TEST2' TO ITAB1-FIELD1.
MOVE 'TEST2' TO ITAB1-FIELD2.
MOVE '20.00' TO ITAB1-FIELD3.
APPEND ITAB1.
DO 50 TIMES.
APPEND ITAB1.
ENDDO.
END-OF-SELECTION.
PERFORM BUILD.
PERFORM EVENTTAB_BUILD CHANGING GT_EVENTS.
PERFORM COMMENT_BUILD CHANGING GT_LIST_TOP_OF_PAGE.
PERFORM CALL_ALV.
FORM BUILD.
DATA FIELD CATALOG
Explain Field Description to ALV
DATA: FIELDCAT_IN TYPE SLIS_FIELDCAT_ALV.
CLEAR FIELDCAT_IN.
FIELDCAT_LN-FIELDNAME = 'FIELD1'.
FIELDCAT_LN-TABNAME = 'ITAB1'.
*FIELDCAT_LN-NO_OUT = 'X'. "FIELD NOT DISPLAY, CHOOSE FROM LAYOUT
FIELDCAT_LN-KEY = ' '. "SUBTOTAL KEY
FIELDCAT_LN-NO_OUT = ' '.
FIELDCAT_LN-SELTEXT_L = 'HEAD1'.
APPEND FIELDCAT_LN TO GT_FIELDCAT.
CLEAR FIELDCAT_IN.
FIELDCAT_LN-FIELDNAME = 'FIELD2'.
FIELDCAT_LN-TABNAME = 'ITAB1'.
FIELDCAT_LN-NO_OUT = 'X'.
FIELDCAT_LN-SELTEXT_L = 'HEAD2'.
APPEND FIELDCAT_LN TO GT_FIELDCAT.
CLEAR FIELDCAT_IN.
FIELDCAT_LN-FIELDNAME = 'FIELD3'.
FIELDCAT_LN-TABNAME = 'ITAB1'.
FIELDCAT_LN-REF_FIELDNAME = 'MENGE'. "<- REF FIELD IN THE DICTIONNARY
FIELDCAT_LN-REF_TABNAME = 'MSEG'. "<- REF TABLE IN THE DICTIONNARY
FIELDCAT_LN-NO_OUT = ' '.
FIELDCAT_LN-DO_SUM = 'X'. "SUM UPON DISPLAY
APPEND FIELDCAT_LN TO GT_FIELDCAT.
DATA SORTING AND SUBTOTAL
DATA: GS_SORT TYPE SLIS_SORTINFO_ALV.
CLEAR GS_SORT.
GS_SORT-FIELDNAME = 'FIELD1'.
GS_SORT-SPOS = 1.
GS_SORT-UP = 'X'.
GS_SORT-SUBTOT = 'X'.
APPEND GS_SORT TO GT_SORT.
CLEAR GS_SORT.
GS_SORT-FIELDNAME = 'FIELD2'.
GS_SORT-SPOS = 2.
GS_SORT-UP = 'X'.
*GS_SORT-SUBTOT = 'X'.
APPEND GS_SORT TO GT_SORT.
ENDFORM.
FORM CALL_ALV.
ABAP List Viewer
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
I_INTERFACE_CHECK = ' '
I_BYPASSING_BUFFER =
I_BUFFER_ACTIVE = ' '
I_CALLBACK_PROGRAM = G_REPID
I_CALLBACK_PF_STATUS_SET = ' '
I_CALLBACK_USER_COMMAND = ' '
I_STRUCTURE_NAME = 'ITAB1'
IS_LAYOUT = GS_LAYOUT
IT_FIELDCAT = GT_FIELDCAT[]
IT_EXCLUDING =
IT_SPECIAL_GROUPS =
IT_SORT = GT_SORT[]
IT_FILTER =
IS_SEL_HIDE =
I_DEFAULT = 'X'
I_SAVE = ' '
IS_VARIANT =
IT_EVENTS = GT_EVENTS[]
IT_EVENT_EXIT =
IS_PRINT = GS_PRINT
IS_REPREP_ID =
I_SCREEN_START_COLUMN = 0
I_SCREEN_START_LINE = 0
I_SCREEN_END_COLUMN = 0
I_SCREEN_END_LINE = 0
IMPORTING
E_EXIT_CAUSED_BY_CALLER =
ES_EXIT_CAUSED_BY_USER =
TABLES
T_OUTTAB = ITAB1
EXCEPTIONS
PROGRAM_ERROR = 1
OTHERS = 2.
ENDFORM.
HEADER FORM
FORM EVENTTAB_BUILD CHANGING LT_EVENTS TYPE SLIS_T_EVENT.
CONSTANTS:
GC_FORMNAME_TOP_OF_PAGE TYPE SLIS_FORMNAME VALUE 'TOP_OF_PAGE'.
*GC_FORMNAME_END_OF_PAGE TYPE SLIS_FORMNAME VALUE 'END_OF_PAGE'.
DATA: LS_EVENT TYPE SLIS_ALV_EVENT.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
I_LIST_TYPE = 0
IMPORTING
ET_EVENTS = LT_EVENTS.
READ TABLE LT_EVENTS WITH KEY NAME = SLIS_EV_TOP_OF_PAGE
INTO LS_EVENT.
IF SY-SUBRC = 0.
MOVE GC_FORMNAME_TOP_OF_PAGE TO LS_EVENT-FORM.
APPEND LS_EVENT TO LT_EVENTS.
ENDIF.
define END_OF_PAGE event
READ TABLE LT_EVENTS WITH KEY NAME = SLIS_EV_END_OF_PAGE
INTO LS_EVENT.
IF SY-SUBRC = 0.
MOVE GC_FORMNAME_END_OF_PAGE TO LS_EVENT-FORM.
APPEND LS_EVENT TO LT_EVENTS.
ENDIF.
ENDFORM.
FORM COMMENT_BUILD CHANGING GT_TOP_OF_PAGE TYPE SLIS_T_LISTHEADER.
DATA: GS_LINE TYPE SLIS_LISTHEADER.
CLEAR GS_LINE.
GS_LINE-TYP = 'H'.
GS_LINE-INFO = 'HEADER 1'.
APPEND GS_LINE TO GT_TOP_OF_PAGE.
CLEAR GS_LINE.
GS_LINE-TYP = 'S'.
GS_LINE-KEY = 'STATUS 1'.
GS_LINE-INFO = 'INFO 1'.
APPEND GS_LINE TO GT_TOP_OF_PAGE.
GS_LINE-KEY = 'STATUS 2'.
GS_LINE-INFO = 'INFO 2'.
APPEND GS_LINE TO GT_TOP_OF_PAGE.
CLEAR GS_LINE.
GS_LINE-TYP = 'A'.
GS_LINE-INFO = 'ACTION'.
APPEND GS_LINE TO GT_TOP_OF_PAGE.
ENDFORM.
FORM TOP_OF_PAGE.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
IT_LIST_COMMENTARY = GT_LIST_TOP_OF_PAGE.
WRITE: SY-DATUM, 'Page No', SY-PAGNO LEFT-JUSTIFIED.
ENDFORM.
FORM END_OF_PAGE.
WRITE at (sy-linsz) sy-pagno CENTERED.
ENDFORM.
PRINT SETTINGS
FORM PRINT_BUILD USING LS_PRINT TYPE SLIS_PRINT_ALV.
LS_PRINT-PRINT = P_PRINT. "PRINT IMMEDIATE
LS_PRINT-NO_PRINT_SELINFOS = P_NOSINF. "NO SELECTION INFO
LS_PRINT-NO_COVERPAGE = P_NOCOVE. "NO COVER PAGE
LS_PRINT-NO_NEW_PAGE = P_NONEWP.
LS_PRINT-NO_PRINT_LISTINFOS = P_NOLINF. "NO PRINT LIST INFO
LS_PRINT-RESERVE_LINES = P_RESERV.
ENDFORM.
thnx
Sravani
Plz reward if useful -
What is the default identity store - and how can I set it?
Hi,
I'm running Webcenter on WLS, and using WLS and JPS for the authentication of users. On the WLS Console, if I go to Security Realms -> myrealm -> Providers, I have a list of four different providers.
If I understand correctly, these four providers are my identity stores. How can I set one as the 'default' identity store? Or see which one is currently the default?
The reason I'm asking is I have the following code in Webcenter to create a new user in the Active Directory:
// Get the default identity store
IdentityStore idStore = WCSecurityUtility.getDefaultIdentityStore();
// Get the user manager object
UserManager usermgr = idStore.getUserManager();
usermgr.createUser(loginName, password.toCharArray(), propertySet);So I have a utility Java class which gives me the "default identity store". Now I want to change the WLS configuration so that the Active Directory in which I want to create new users is the "default" identity store.
Thanks in advance for any help,
LudovicHi,
Thanks a lot for your help and providing this link. I'd actually already looked at that before, but I don't understand how it clarifies what the default identity store is. The relevant part is this, if I understand correctly:
OPSS initializes the identity store service with the LDAP authenticator chosen from the list of configured LDAP authenticators according to the following algorithm:
1. Consider the subset of LDAP authenticators configured. Note that, since the context is assumed to contain at least one LDAP authenticator, this subset is not empty.
2. Within that subset, consider those that have set the maximum flag. The flag ordering used to compute this subset is the following:
REQUIRED > REQUISITE > SUFFICIENT > OPTIONAL
Again, this subset (of LDAPs realizing the maximum flag) is not empty.
3. Within that subset, consider the first configured in the context.Step (1) will match 2 external AD's and the built-in WLS LDAP, so 3 in total.
Step (2) will still match 3 in total, as they are all 'sufficient'. In my setup, I need them all to be 'sufficient'.
Step (3) is a step I don't understand. What is "the first configured in the context"? What context? Do they mean the one that was first created? In that case I can't change the default, right?
Or do they mean "the first in the list on the WLS Console"?
Best regards,
Ludovic -
i forgot the administrator password for my mac and cant set a new one without it how can i set a new one
Reset Password 10.7, 10.8...
http://reviews.cnet.com/8301-13727_7-20087723-263/how-to-run-the-password-reset- utility-in-os-x-10.7-lion/ -
How can I set my WebI filters to Null and not Null
Folks,
I have created a report in WebI and now I am to set up some filters as Null and some Not Null.
How can I set my WebI filters to Null and not Null?
Regards,
Bashir AwanHi,
As you said you could do it at the report level and also at the universe level.
One more way is to create the filters in the universe levele and add them in thequery filter.
Ex: in the filter you need to write :
Column1 is null and and column 2 is not null etc.
Hope this will help.
If this did't solve your problem then please explain it in detail.
Cheers,
Ravichandra K
Maybe you are looking for
-
Can any one explain me the very clear picture between client level,plant level and material level with one suitable example. What will happen if i do the goods receipt for STO within the same company code how the batch will be generated depending on
-
Can someone tell me what I'm doing wrong? The filtering works in FireFox but not IE. http://www.victorcorey.com/spry/wh_unobtrusivegrid.htm [code] <select onchange="filterRegion(this.options[this.selectedIndex].value);"> <option>All Regions</option>
-
HT204053 My I tune I'd is not getting changed as the old e mail is out service.
My old e mail I'd is not provided by service provider at present.therefore I have changed my e mail I'd and entered it to Apple services. The iTunes doesnot accept the same and on downloading it comes out with the old e mail I'd and doesnot accept
-
How to get rid of port number when you want use SJSAS as your production we
Hi my question is rather simple. If I want use my computer as the web server backed by Sun Java System Application Server suite installed on the same machine, how can other internet users access my set domain without knowing my host port # (not typin
-
Hello, is it possible to resolve any technical name in a table??