Replacing detail field in GL report
Hi All,
I am still learning SAP B1 and currently I am facing a problem relates to general
ledger report. is it possible to replace detail field in the report with customer
name ? I really need it since it wastes time for user to browse BP. TIA
Rgds,
Mark
Hello,
I am not sure that you could replace it because it is standard SAP B1. I suggest to develop another report but contains same fields / data but the detail column/field consist customer name. There are reporting services, crystal report or maybe XL reporter.
Rgds,
Similar Messages
-
Hello. When I right click a cube in the solution explorer and click browse, I am presented with a Details field area which doesn't have "Drop Row Fields" area like in BIDS 2008, and doesn't have "Drop Column Fields" area like in BIDS. It just has one details
area with the message "Drag levels or measures here to add to the query".
How do I include the "Drop Row Fields" area and the "Drop Column Fields" area in this Details area so it can be like 2008?I am using MDX query to build SSRS report.
How do i get MDX query from Excel ?
Hi Vishal,
We can use "OLAP PivotTable Extension" to get MDX query in Excel, please download it from:
http://olappivottableextend.codeplex.com/
In addition, I would suggest you open a new case if you have any more questiosn.
Regards,
Elvis Long
TechNet Community Support -
one of the Field in my Report is F_Payment_date1 the source column its referring is payment_date which is in the table ..
The Query for this Group is
select
empl.action_context_id
, empl.full_name
, ppf.last_name
, ppf.first_name
, empl.national_identifier
,hou.INTERNAL_ADDRESS_LINE
, empl.employee_number
, empl.organization_name
, substr(empl.employee_address1,1,40) emp_add_ln1
, substr(empl.employee_address2,1,40) emp_add_ln2
, substr(empl.employee_address3,1,40) emp_add_ln3
, rtrim(substr(empl.employee_city,1,26))||' '
||empl.employee_state||' '
||empl.employee_zip_code emp_add_ln4
, empl.beginning_date period_start_date
, empl.ending_date period_end_date
, empl.payment_date
, LTRIM(RTRIM(TO_CHAR(empl.pay_rate,'99999999.00'))) base_salary
, empl.pay_basis salary_basis
, empl.employee_state resident_state
, empl.location_name
, paf.work_At_home
, empl.assignment_id
, :org_payment_method_id org_payment_id
, substr(empl.employer_address1,1,40) emplr_add_ln1
, substr(empl.employer_address2,1,40) emplr_add_ln2
, rtrim(substr(empl.employer_city,1,26))||' '
||empl.employer_state||' '
||empl.employer_zip_code emplr_add_ln3
from PAY_EMPLOYEE_ACTION_INFO_V empl
,pay_assignment_actions paa
,per_assignments_f paf
,per_people_f ppf
,hr_all_organization_units hou
where paa.assignment_action_id = empl.action_context_id
and empl.assignment_id = paa.assignment_id
and paf.assignment_id = paa.assignment_id
and empl.effective_date between hou.DATE_FROM and nvl(hou.date_to,empl.effective_date)
and paf.ORGANIZATION_ID = hou.ORGANIZATION_ID
and empl.employee_number = ppf.employee_number
and empl.effective_date between paf.effective_start_date
and paf.effective_end_date
and empl.effective_date between ppf.effective_start_date
and ppf.effective_end_date
even if the payment date expires in the report it is still showing payment_date
i want to include the logic like this
if overrideing then
v_date:=: PPA_OVERRIDING_DD_DATE ( Ihope this does not work as they are in dfferent group i need to write sql )
else
v_date:=:PAYMENT_DATE;
return(v_date);
PPA_OVERRIDING is in the table pay_assignment_actions
The Query for the other group where the PPA_OVERRIDING_DD_DATE
is
SELECT decode(ppa.action_type,'H',to_number(paa.serial_number)
,paa.action_sequence) orderby
, paa.assignment_action_id asg_actid, to_number(paa.serial_number) xfr_action
, ppa.action_type
, ppa.org_payment_method_id
, paa.assignment_id paa_assignment_id
, ppa.effective_date ppa_effective_date
, ppa.business_group_id business_group_id
, ppa.payroll_action_id ppa_payroll_action_id
, ppa.payroll_id ppa_payroll_id
, ppa.consolidation_set_id ppa_consolidation_set_id
, ppa.date_earned ppa_date_earned
, ppa.overriding_dd_date ppa_overriding_dd_date
FROM pay_assignment_actions paa
,pay_payroll_actions ppa
WHERE paa.payroll_action_id = :pactid
AND paa.chunk_number = :chnkno
AND ppa.payroll_action_id = paa.payroll_action_id
ORDER BY 1
can anyone gimme sugestion how to approach this ..i want to display
PPA_OVERRIDING_DD_DATE column values where ever
payment date is expired .
Thanks in Advance,
Dev Kishore.TIf i understand your question well, you could try this:
In the querygroup (datamodel) of your first query you create a formula column : CF_payment_or_overriding_date
In the PL/SQL Formula of your formula column you add code like this:
function CF_payment_or_overriding_dateF return DATE
is
ld_return DATE;
begin
IF 'overriding'
THEN
use your criteria to retrieve the overriding_dd_date from paa via select into or a cursor construction
ld_return := ppa_overriding_dd_date;
ELSE
-- empl.payment_date is fine do not replace
ld_return := :payment_date;
END IF;
RETURN (ld_return);
end;
And in your layout section,
for your field F_Payment_date1 set your source column to
your formula column CF_payment_or_overriding_date
Hope this helps,
Greetings,
Emiel -
How to insert a new field in the Report Designer
Hi all.
I have a query and a report, but the query evolve.
We have a new key figure (inside rows).
In the report designer, I check the data provider.
The new key figure is added in the catalog field.
Now, I would like to insert the new field in the report.
I add a new row in the report structure but it isnt what I want.
In this case, I add a second row inside an another keys figures block.
I want to create a new block for my new key figure
Thanks for your help
CélineYes, key figures is in the field catalog.
But When I do that " Insert a row ", Report designer create a " row 2 " below another key figures.
And it isn't what I want. I want a new block .
For exemple in the tab report structure (My new key figure is "Margin")
I do that
Group Level 1 : key figures
Detail Area
Sales Amount
row1
cell1
cell2
Cost
row1
cell1
cell2
row2 ( the new row added)
cell1
cell2
But I want that:
Group Level 1 : key figures
Detail Area
Sales Amount
row1
cell1
cell2
Cost
row1
cell1
cell2
Margin
row1
cell1
cell2
Thanks for your help -
How to Add a new Selection Field in COPA Report
Hi Gurus
I'm new on SAP COPA reporting and I don't know how to solve this problem.
I need add a new Selection-screen field (char1), not connected with any characteristic.
This is necessary becuase if the user flag this field, when teh report is running I'll replace some key-figure values using the EXIT
ZXYEXF05. I don't find any instruction how to define this simple kinfd of variable, and use it into a Report.
Thank-you in advance for your help.
ClaudioHi
I'll try to explain better my need.
I've 10 CO-PA Key-Figures used to Split in the Cost of a material in different Cost Items.
Using the customizing I fill these key-figures using some rules.
The new requirement is use SOMETIME the same KF, by displaying different Costs overwritting the original values using the exit ZXYEXF05. But I need to know when the user wants consider the original value of KF, and when he wants overwrite these values (when I have to run teh exit). So I thought to create a new Selection-screen field (Char1), to permit to the user to pass to some report this user request. I thought to define a global variable, and add it to several reports when this feature is required.
Can you suggest a better solution ???
I could create some empty KF and fill them using teh exit, but I would prefer not expand the CO-PA structure.
Thanks for help.
Claudio -
Mix overview and detail records in same report
Hello, in substance I need to mix results from overview table and records from details table in same report.
For creating the scenario:
CREATE TABLE ALPHA
ALPHA_ID NUMBER,
ALPHA_NR NUMBER,
ALPHA_TOTCT NUMBER,
ALPHA_FUND NUMBER
ALTER TABLE ALPHA ADD (
CONSTRAINT ALPHA_PK PRIMARY KEY (ALPHA_ID));
ALTER TABLE ALPHA ADD (
CONSTRAINT ALPHA_NR_UNI UNIQUE (ALPHA_NR));
INSERT INTO ALPHA(ALPHA_ID, ALPHA_NR)
VALUES( 1, 7 );
INSERT INTO ALPHA(ALPHA_ID, ALPHA_NR)
VALUES( 2, 11 );
INSERT INTO ALPHA(ALPHA_ID, ALPHA_NR)
VALUES( 3, 15 );
INSERT INTO ALPHA(ALPHA_ID, ALPHA_NR)
VALUES( 4, 17 );
CREATE TABLE HIST
HIST_ID NUMBER,
HIST_NR NUMBER,
HIST_ALPHA_NR NUMBER,
HIST_CT NUMBER,
HIST_VAL NUMBER,
HIST_DATE DATE
ALTER TABLE HIST ADD (
CONSTRAINT HIST_PK PRIMARY KEY (HIST_ID));
ALTER TABLE HIST ADD (
CONSTRAINT HIST_NR_UNI UNIQUE (HIST_NR));
ALTER TABLE HIST ADD (
CONSTRAINT HIST_ALPHA_NR_FK FOREIGN KEY (HIST_ALPHA_NR) REFERENCES ALPHA ( ALPHA_NR ) );
TRUNCATE TABLE HIST;
INSERT INTO HIST( HIST_ID ,HIST_NR ,HIST_ALPHA_NR ,HIST_CT ,HIST_VAL ,HIST_DATE )
VALUES ( 1 ,1 ,7 ,1 ,10 , TO_DATE('01.02.2009' , 'dd.mm.yyyy' ) );
INSERT INTO HIST( HIST_ID ,HIST_NR ,HIST_ALPHA_NR ,HIST_CT ,HIST_VAL ,HIST_DATE )
VALUES ( 2 ,6 ,7 ,1 ,10 , TO_DATE('01.05.2009' , 'dd.mm.yyyy' ) );
INSERT INTO HIST( HIST_ID ,HIST_NR ,HIST_ALPHA_NR ,HIST_CT ,HIST_VAL ,HIST_DATE )
VALUES ( 3 ,3 ,7 ,3 ,30 , TO_DATE('01.02.2010' , 'dd.mm.yyyy' ) );
INSERT INTO HIST( HIST_ID ,HIST_NR ,HIST_ALPHA_NR ,HIST_CT ,HIST_VAL ,HIST_DATE )
VALUES ( 4 ,4 ,11 ,1 ,10 , TO_DATE('01.03.2009' , 'dd.mm.yyyy' ) );
INSERT INTO HIST( HIST_ID ,HIST_NR ,HIST_ALPHA_NR ,HIST_CT ,HIST_VAL ,HIST_DATE )
VALUES ( 5 ,5 ,11 ,-2 ,-20 , TO_DATE('01.06.2010' , 'dd.mm.yyyy' ) );
INSERT INTO HIST( HIST_ID ,HIST_NR ,HIST_ALPHA_NR ,HIST_CT ,HIST_VAL ,HIST_DATE )
VALUES ( 6 ,8 ,11 ,1 ,10 , TO_DATE('01.02.2011' , 'dd.mm.yyyy' ) );
INSERT INTO HIST( HIST_ID ,HIST_NR ,HIST_ALPHA_NR ,HIST_CT ,HIST_VAL ,HIST_DATE )
VALUES ( 7 ,2 ,15 ,2 ,20 , TO_DATE('01.03.2009' , 'dd.mm.yyyy' ) );
INSERT INTO HIST( HIST_ID ,HIST_NR ,HIST_ALPHA_NR ,HIST_CT ,HIST_VAL ,HIST_DATE )
VALUES ( 8 ,7 ,15 ,5 ,50 , TO_DATE('01.06.2010' , 'dd.mm.yyyy' ) );
INSERT INTO HIST( HIST_ID ,HIST_NR ,HIST_ALPHA_NR ,HIST_CT ,HIST_VAL ,HIST_DATE )
VALUES ( 9 ,9 ,15 ,-4 ,-40 , TO_DATE('01.02.2011' , 'dd.mm.yyyy' ) );
INSERT INTO HIST( HIST_ID ,HIST_NR ,HIST_ALPHA_NR ,HIST_CT ,HIST_VAL ,HIST_DATE )
VALUES ( 10 ,10 ,17 ,1 ,10 , TO_DATE('01.03.2011' , 'dd.mm.yyyy' ) );For updating the overview table, I used a view
CREATE OR REPLACE VIEW HIST_AGG ( HIST_ALPHA_NR, TOT_CT , TOT_VAL )
AS
SELECT HIST_ALPHA_NR
,SUM ( NVL(HIST_CT, 0 ) ) TOT_CT
,SUM( NVL(HIST_VAL, 0) ) TOT_VAL
FROM HIST
GROUP BY HIST_ALPHA_NR;
DECLARE
CURSOR cur
IS
SELECT
HIST_ALPHA_NR
,TOT_CT
,TOT_VAL
FROM HIST_AGG
BEGIN
FOR rec IN cur
LOOP
UPDATE ALPHA
SET ALPHA_TOTCT = rec.TOT_CT
, ALPHA_FUND = rec.TOT_VAL
WHERE ALPHA_NR = rec.HIST_ALPHA_NR;
END LOOP;
END;First report should the overview line from table alpha followed by all detail records from
table HIST, and this for each alpha_nr. At the end of the report a total from the overview
table alpha.
"SUMMARY";"ALPHA_NR";"ALPHA_TOTCT";"ALPHA_FUND";
;7;5;50;
;7;1;10;01.02.2009
;7;1;10;01.05.2009
;7;3;30;
;11;0;0;
;11;1;10;01.03.2009
;11;-2;-20;01.06.2010
;11;1;10;01.02.2011
;15;3;30;
;15;2;20;01.03.2009
;15;5;50;01.06.2010
;15;-4;-40;01.02.2011
;17;1;10;
;17;1;10;01.03.2011
"TOTAL_ALPHA_NR";4;9;90;Second report should display the overview per time period (year), but the records from
e.g. year 2009 start counting in year 2010. At the end of each year again a summary for
the actual status.
"YEAR";"ALPHA_NR";"ALPHA_TOTCT";"ALPHA_FUND"
2009;7;0;0
;11;0;0
;15;0;0
;17;0;0
"Total 2009";4;0;0
2010;7;2;20
;11;1;10
;15;2;20
;17;0;0
"Total 2010";4;5;50
2011;7;5;50
;11;-1;-10
;15;7;70
;17;0;0
"Total 2011";4;11;110
2012;7;5;50
;11;0;0
;15;3;30
;17;1;10
"Total 2012";4;9;90Hi,
This is quite a different problem from what you first posted.
wucis wrote:
This is what I want to get
ALPHA_DATE ALPHA_NAME ALPHA_NR ALPHA_TOTCT ALPHA_FUND TRANS_DATE
01.01.2009 seven 7 5 50
7 1 10 01.02.2009
7 1 10 01.05.2009
7 3 30 01.02.2010
01.03.2009 eleven 11 0 0
11 1 10 01.03.2009
11 -2 -20 01.06.2010
11 1 10 01.02.2011
03.05.2010 twelve 12 0 0
02.02.2009 fifteen 15 3 30
15 2 20 01.03.2009
15 5 50 01.06.2010
15 -4 -40 01.02.2011
10.10.2010 seventeen 17 1 10
17 1 10 01.03.2011
TOTAL_ALPHA_NR 5 9 90
Do you really want to include alphr_nr=12? If so, what do you mean when you say
I have an approach but there are "unnecessary" rows ( the line with just alpha_nr = 12 ) and why don't you want alpha_nr=13?
so my join is buggyExactly! The join
... from hist, alpha b
WHERE b.alpha_nr = hist.hist_alpha_nr (+) ...means "include all rows from alpha, whether of not they have any corresponding rows in hist or not". If you want to exclude alpha_nrs 12 and 13, you probably want to do an inner join there.
You don't need any sub-queries to do that:
SELECT CASE
WHEN GROUPING (h.hist_alpha_nr) = 0
AND GROUPING (h.hist_date) = 1
THEN MAX (a.alpha_date)
END AS alpha_date
, CASE
WHEN GROUPING (h.hist_alpha_nr) = 1
THEN 'TOTAL_ALPHA_NR'
WHEN GROUPING (h.hist_date) = 1
THEN MAX (a.alpha_name)
END AS alpha_name
, CASE
WHEN GROUPING (h.hist_alpha_nr) = 0
THEN h.hist_alpha_nr
ELSE COUNT (DISTINCT (alpha_nr))
END AS alpha_nr
, SUM (h.hist_ct) AS alpha_totct
, SUM (h.hist_val) AS alpha_fund
, h.hist_date AS trans_date
FROM hist h
, alpha a
WHERE h.hist_alpha_nr = a.alpha_nr
AND a.active = 'Y'
GROUP BY ROLLUP ( hist_alpha_nr
, hist_date
ORDER BY GROUPING (h.hist_alpha_nr)
, h.hist_alpha_nr
, GROUPING (h.hist_date) DESC
, h.hist_date
;Output:
ALPHA ALPHA ALPHA
ALPHA_DATE ALPHA_NAME _NR _TOTCT _FUND TRANS_DATE
01.01.2009 seven 7 5 50
7 1 10 01.02.2009
7 1 10 01.05.2009
7 3 30 01.02.2010
01.03.2009 eleven 11 0 0
11 1 10 01.03.2009
11 -2 -20 01.06.2010
11 1 10 01.02.2011
02.02.2009 fifteen 15 3 30
15 2 20 01.03.2009
15 5 50 01.06.2010
15 -4 -40 01.02.2011
10.10.2010 seventeen 17 1 10
17 1 10 01.03.2011
TOTAL_ALPHA_NR 4 9 90If this is not what you want (e.g., if you want alpha_nr=12 in the results) then point out where these results are wrong, post the correct results, and explain how you get the correct results in those places. -
Classification of line items into the Detailed Profit and Loss report
Hi,
Given a line item in a profit and loss ledger, what field determines that the line item will appear under Fixed Manufacturing Costs, Sales and Distribution or General Admin Expenses when we generate the Detailed Profit and Loss report?
Thank youHi all,
Thank you so much for everyone's quick reply. I really appreciate it.
Please allow me to clarify my question.
I have a balance of 3,712,126.60 in my GL 30000000. In my detailed Profit and Loss (ZPL-002), 705,712.90 is shown under Gen. Operating Exp. while 3,006,413.70 is shown under Fixed Manufacturing Costs.
So, what field does SAP use to allocate those line items between Gen. Operating Exp. and Fixed Manufacturing Costs? Is it Functional Area only?
Thank you. -
Use different Layouts for Summary and Details in Drill down report
Hi All,
I have a 2 level drill down report in ALV.
The summary report has certain fields and the Detail report has different fields. Now my problem is that when i use a default layout (with all fields of summary report) for the summary report, and drill down to the detail report i'm missing the fields on detail that are not in Summary. And if i save the default layout as default (with all fields of Detail) and go back to sumary, I'm missing the some other fields on summary (which are not on detail report).
Is there a way to make different default layouts for each of those summary and detail reports:
Also as the layouts are choosen by the user, i cannot hardcode any particular layout;
So if the user chooses a layout for detail; it has to stay the same layout for the detail report if he goes to summary and then back to detail; unless the user changes the layout again.
I'm using two different Layout types for each report. but i still cannot get the desired effect.
Data:
gt_layout_s type slis_layout_alv,
gt_layout_d type slis_layout_alv,
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
i_callback_program = g_repid
is_layout = <b>gt_layout_s</b>
i_callback_top_of_page = g_top_of_page
i_callback_user_command = g_user_command
i_callback_pf_status_set = g_status
i_save = g_save
is_variant = gs_variant
it_fieldcat = gt_fieldcat[]
it_events = gt_events[]
importing
es_exit_caused_by_user = gs_exit_caused_by_user
tables
t_outtab = it_summary.
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
i_callback_program = g_repid
is_layout = <b>gt_layout_d</b>
i_callback_top_of_page = g_top_of_page
i_callback_user_command = g_user_command
i_callback_pf_status_set = g_status
i_save = g_save
is_variant = gs_variant
it_fieldcat = gt_fieldcat[]
it_events = gt_events[]
importing
es_exit_caused_by_user = gs_exit_caused_by_user
tables
t_outtab = it_detail_disp.Here is how you differentiate between the layout of two different grids. There is the parameter, IS_VARIANT in the function. You usually leave it empty or pass only the report name and username. <b>What you need to do is to pass unique string for each grids to the HANDLE field of the parameter IS_VARIANT.</b> You can probably hard code it as HEADER and DETAILS in your case. Once that is done, system identified that these two different layout for different grids.
Regards,
Ravi
Note : Please mark all the helpful answers<u></u> -
Pull more than one field into the same field in a report.
I am attempting to put together a report in Visual Studio 2008. It seemed a simple report at first, but as I am creating the SQL, I am having a little trouble conceptualizing how to get it to work exactly as needed. Here is the issue...
In this case, the report should show two rows for each department. One is the count of who within an audience (that will be set up as a parameter) completed a certain course (the course may also be a parameter). The next row should be
a count, within that same department, of all users within the audience. Both counts should be within the same field on the report, but on different rows.
My thought was to create two CTE's. One would contain the counts, by department, of everybody in the audience. The other would contain the counts, by department, of those within the audience who completed the given course.
The problem is, though, I need to then have these two counts by department on two separate lines, and they should be within the same field. Basically, the idea is they are the numerator and denominator. There would also be a field before the count that would
need to identify which one it is. For the sake of the example, call it "Measure_ID" and it would say "CourseCert" for the count of who completed the course and "CourseAvail" for the count of those who are part of the audience.
Let me know if that makes sense, or if I can provide any further clarification to help you better understand what I am trying to achieve. Does anybody have thoughts on how to do this?Unfortunately, the counts need to be in separate rows. If they could be in the same row, it would have probably been a lot easier. I think I could have just done a couple "Case When" type formulas within the list of things under "Select."
As it is, I need the two counts to show up under the same heading in separate rows. Unfortunately, the table structure of this database is very complicated. I think it would likely just further confuse things if I tried to share all of that detail here.
That is why I was trying to be generic.
Unless there is another easier way I am missing, I was thinking the easiest way to achieve what I needed was to use two CTE's. One would list all users by department who belong to a specific audience (the audiences are what we use to then assign them
to certain courses, so the audience would be the people who are required to complete a certain course). The other would list all user by department who are in that audience and have completed a particular course. I think I am fine to complete that part.
It is just getting them to then display as in my example that I am not sure how to do.
The desired result, as you see in my example, has two lines per department, the first being a count of those who completed the course ("Certified"). The second line being a count of those who are required to complete it ("Available").
Does that help? I was basically hoping somebody had an example they could use, just with fake table names so I could adapt it to my data. If it helps, though, let's pretend the two CTE's are like this:
Table Name: Certified
Table's purpose: This table would list all people who had completed the course.
Fields:
CourseName
CourseCode
AudienceName
AudienceCode
CompletionResult
EmpCode
DepartmentCode
Table Name: Available
Table's purpose: This table would list all people who are assigned to the audience.
Fields:
AudienceName
AudienceCode
EmpCode
DepartmentCode
The desired result would then count the EmpCodes, by department, from each table in that Measure_Amount field so it could display as I showed above. Does that make sense? I apologize if that does not help to clarify. I was trying to be as simple
as possible so you could just use it as a generic example. -
I want to add some fields in the report of FBL5N, Can anybody tell me how ?
I want to add some fields in the report of FBL5N, Can anybody tell me how to do it?
The fields are sales order, delivery, order quantity, net value and others.
I can only find the shipment number in FI document.
Thank you very much.Dear Jie,
Billing document number can be displayed in customer line item display
(FBL5N) and not in G/L line item display (FBL3N).
The value of VBELN is saved in table BSEG. So, this means, you
have to define the field BSEG-VBELN as a special field in table
T021S. Then you can use it in FBL3N, because then the report looks
directly in BSEG-VBELN.
For further information,please read the SAP note 207436. You don't have to
implement the coding corrections, if they are already in your system
with the hotpackage. But it explains very detailed the system
behaviour. The example in the note with field EBELN could be
replicated on your field VBELN.
About the MEINS field, please refer to 1-U_MEINS (bseg-meins field).
The SAP note 215798 may also be helpful.
Mauri -
Pulling more than one field into the same field within a report.
I posted this in the T-SQL forum, but it was suggested it may be better to post it here. This is somewhat complicated, so I hope I am explaining this well. I will post here what I posted there. I will also include two replies I gave in offering further information
in case that may help to further clarify my question. See below:
I am attempting to put together a report in Visual Studio 2008. It seemed a simple report at first, but as I am creating the SQL, I am having a little trouble conceptualizing how to get it to work exactly as needed. Here is the issue...
In this case, the report should show two rows for each department. One is the count of who within an audience (that will be set up as a parameter) completed a certain course (the course may also be a parameter). The next row should be a count, within that
same department, of all users within the audience. Both counts should be within the same field on the report, but on different rows.
My thought was to create two CTE's. One would contain the counts, by department, of everybody in the audience. The other would contain the counts, by department, of those within the audience who completed the given course.
The problem is, though, I need to then have these two counts by department on two separate lines, and they should be within the same field. Basically, the idea is they are the numerator and denominator. There would also be a field before the count that would
need to identify which one it is. For the sake of the example, call it "Measure_ID" and it would say "CourseCert" for the count of who completed the course and "CourseAvail" for the count of those who are part of the audience.
Let me know if that makes sense, or if I can provide any further clarification to help you better understand what I am trying to achieve. Does anybody have thoughts on how to do this?Unfortunately, the counts need to be in separate rows. If they could be in the same row, it would have probably been a lot easier. I think I could have just done a couple "Case When" type formulas within the list of things under "Select."
As it is, I need the two counts to show up under the same heading in separate rows. Unfortunately, the table structure of this database is very complicated. I think it would likely just further confuse things if I tried to share all of that detail here.
That is why I was trying to be generic.
Unless there is another easier way I am missing, I was thinking the easiest way to achieve what I needed was to use two CTE's. One would list all users by department who belong to a specific audience (the audiences are what we use to then assign them to
certain courses, so the audience would be the people who are required to complete a certain course). The other would list all user by department who are in that audience and have completed a particular course. I think I am fine to complete that part. It is
just getting them to then display as in my example that I am not sure how to do.
The desired result, as you see in my example, has two lines per department, the first being a count of those who completed the course ("Certified"). The second line being a count of those who are required to complete it ("Available").
Does that help? I was basically hoping somebody had an example they could use, just with fake table names so I could adapt it to my data. If it helps, though, let's pretend the two CTE's are like this:
Table Name: Certified
Table's purpose: This table would list all people who had completed the course.
Fields:
CourseName
CourseCode
AudienceName
AudienceCode
CompletionResult
EmpCode
DepartmentCode
Table Name: Available
Table's purpose: This table would list all people who are assigned to the audience.
Fields:
AudienceName
AudienceCode
EmpCode
DepartmentCode
The desired result would then count the EmpCodes, by department, from each table in that Measure_Amount field so it could display as I showed above. Does that make sense? I apologize if that does not help to clarify. I was trying to be as simple as possible
so you could just use it as a generic example. -
Regd: Calculation of TOTAL field in ALV report
Hi All,
We have a scenario that we are not getting the total value for numeric fields in ALV report.
Below i have given the code used for it.
G_KEY = 'X'.
G_NOKEY = SPACE.
G_SUM = 'X'.
G_NOSUM = SPACE.
PERFORM BUILD_FIELDCAT USING 'VBELN' G_KEY G_NOSUM.
PERFORM BUILD_FIELDCAT USING 'BLDAT' G_NOKEY G_NOSUM.
PERFORM BUILD_FIELDCAT USING 'VGBEL' G_KEY G_NOSUM.
PERFORM BUILD_FIELDCAT USING 'POSNR' G_KEY G_NOSUM.
PERFORM BUILD_FIELDCAT USING 'MATNR' G_KEY G_NOSUM..
PERFORM BUILD_FIELDCAT USING 'LFIMG' G_NOKEY G_NOSUM.
PERFORM BUILD_FIELDCAT USING 'VRKME' G_NOKEY G_NOSUM.
PERFORM BUILD_FIELDCAT USING 'NETPR' G_NOKEY G_NOSUM.
PERFORM BUILD_FIELDCAT USING 'BRTWR' G_NOKEY G_NOSUM.
PERFORM BUILD_FIELDCAT USING 'VALUE_INR' G_NOKEY G_SUM.
PERFORM BUILD_FIELDCAT USING 'B_DUTY' G_NOKEY G_SUM.
PERFORM BUILD_FIELDCAT USING 'S_TOTAL1' G_NOKEY G_SUM.
PERFORM BUILD_FIELDCAT USING 'CV_DUTY' G_NOKEY G_SUM.
PERFORM BUILD_FIELDCAT USING 'C_CVD' G_NOKEY G_SUM.
PERFORM BUILD_FIELDCAT USING 'S_TOTAL2' G_NOKEY G_SUM.
PERFORM BUILD_FIELDCAT USING 'C_DUTY' G_NOKEY G_SUM.
PERFORM BUILD_FIELDCAT USING 'S_TOTAL3' G_NOKEY G_SUM.
PERFORM BUILD_FIELDCAT USING 'A_DUTY' G_NOKEY G_SUM.
PERFORM BUILD_FIELDCAT USING 'T_DUTY' G_NOKEY G_SUM.
PERFORM BUILD_LAYOUT.
PERFORM BUILD_DISPLAY.
*& Form DISPLAY
text
FORM BUILD_DISPLAY.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_INTERFACE_CHECK = ' '
I_BYPASSING_BUFFER = ' '
I_BUFFER_ACTIVE = ' '
I_CALLBACK_PROGRAM = ' '
I_CALLBACK_PF_STATUS_SET = ' '
I_CALLBACK_USER_COMMAND = ' '
I_CALLBACK_TOP_OF_PAGE = ' '
I_CALLBACK_HTML_TOP_OF_PAGE = ' '
I_CALLBACK_HTML_END_OF_LIST = ' '
I_STRUCTURE_NAME =
I_BACKGROUND_ID = ' '
I_GRID_TITLE = TEXT-000
I_GRID_SETTINGS =
IS_LAYOUT = IG_LAYOUT
IT_FIELDCAT = IG_FIELDCAT
IT_EXCLUDING =
IT_SPECIAL_GROUPS =
IT_SORT =
IT_FILTER =
IS_SEL_HIDE =
I_DEFAULT = 'X'
I_SAVE = 'A'
IS_VARIANT =
IT_EVENTS =
IT_EVENT_EXIT =
IS_PRINT =
IS_REPREP_ID =
I_SCREEN_START_COLUMN = 0
I_SCREEN_START_LINE = 0
I_SCREEN_END_COLUMN = 0
I_SCREEN_END_LINE = 0
I_HTML_HEIGHT_TOP = 0
I_HTML_HEIGHT_END = 0
IT_ALV_GRAPHICS =
IT_HYPERLINK =
IT_ADD_FIELDCAT =
IT_EXCEPT_QINFO =
IR_SALV_FULLSCREEN_ADAPTER =
IMPORTING
E_EXIT_CAUSED_BY_CALLER =
ES_EXIT_CAUSED_BY_USER =
TABLES
T_OUTTAB = IG_INBOUND
EXCEPTIONS
PROGRAM_ERROR = 1
OTHERS = 2
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM. "DISPLAY
*& Form BUILD_FIELDCAT
text
-->G_FIELDNAME text
-->L_KEY text
-->L_SUM text
FORM BUILD_FIELDCAT USING L_FIELDNAME LIKE DD03L-FIELDNAME L_KEY TYPE C L_SUM TYPE C.
CLEAR WG_FIELDCAT_LN.
ADD 1 TO G_COL_POS.
WG_FIELDCAT_LN-REF_TABNAME = 'IG_INBOUND'.
WG_FIELDCAT_LN-FIELDNAME = L_FIELDNAME.
WG_FIELDCAT_LN-KEY = L_KEY.
WG_FIELDCAT_LN-DO_SUM = L_SUM.
WG_FIELDCAT_LN-COL_POS = G_COL_POS.
WG_FIELDCAT_LN-NO_OUT = SPACE.
WG_FIELDCAT_LN-QFIELDNAME = SPACE.
WG_FIELDCAT_LN-HOTSPOT = SPACE.
APPEND WG_FIELDCAT_LN TO IG_FIELDCAT.
ENDFORM. "BUILD_FIELDCAT
*& Form BUILD_LAYOUT
text
FORM BUILD_LAYOUT.
IG_LAYOUT-TOTALS_TEXT = 'Total Amount'.
*IG_LAYOUT-SUBTOTALS_TEXT = 'A'.
IG_LAYOUT-ZEBRA = 'X'.
ENDFORM.
Help and Sugesstions will be much appreciated.
Thanks & Regds.
Ramesh.This is sample program for the same
REPORT Z_50657_ALV_EX2
NO STANDARD PAGE HEADING
LINE-COUNT 65(3)
LINE-SIZE 220
MESSAGE-ID ZZ.
* Type Pools *
TYPE-POOLS: SLIS, ICON.
* Tables *
TABLES: VBAK. "Sales Document Data
* Internal Tables *
* TABLE TO HOLD DATA OF SALES DOCUMENT
DATA: BEGIN OF IT_VBAK OCCURS 0,
VBELN LIKE VBAK-VBELN, "Sales Document
VBTYP LIKE VBAK-VBTYP, "SD document category
AUDAT LIKE VBAK-AUDAT, "Document date (date received/sent)
AUGRU LIKE VBAK-AUGRU, "Order reason (reason for the business)
AUART LIKE VBAK-AUART, "Sales Document Type
NETWR LIKE VBAK-NETWR, "Net Sales Order in Doc. Currency
WAERK LIKE VBAK-WAERK, "SD document currency
ICON TYPE ICON-ID, "traffic lights
END OF IT_VBAK.
* Work Areas *
*WORK AREAS DEFINED FOR ALV'S
DATA: WA_FIELDCAT TYPE SLIS_FIELDCAT_ALV, "field catalog
IT_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV, "field catalog ITAB
WA_SORT TYPE SLIS_SORTINFO_ALV, "SORT work area
IT_SORT TYPE SLIS_T_SORTINFO_ALV, "SORT ITAB
LAYOUT TYPE SLIS_LAYOUT_ALV, "LAYOUT
WA_FCODE TYPE SLIS_EXTAB, "FUN CODE
I_FCODE_EXTAB TYPE SLIS_T_EXTAB,
WA_EVENTS TYPE SLIS_ALV_EVENT,
IT_EVENTS TYPE SLIS_T_EVENT.
* Selection-Screen *
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME.
SELECT-OPTIONS: S_VBELN FOR VBAK-VBELN.
PARAMETERS: P_VBTYP LIKE VBAK-VBTYP DEFAULT 'C'.
SELECTION-SCREEN END OF BLOCK B1.
SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME.
PARAMETERS: LIST RADIOBUTTON GROUP G1,
GRID RADIOBUTTON GROUP G1.
SELECTION-SCREEN END OF BLOCK B2.
* At Selection-Screen *
*VALIDATION
* Start of Selection *
START-OF-SELECTION.
*POPULATION OF DATA INTO INTERNAL TABLE ITAB
PERFORM GET_DATA.
*DEFINE USER DEFINED FIELDCATALOG
PERFORM DEFINE_FIELDCATALOG.
*SUBTOTALS AND TOTALS DISPLAY USING SORT
PERFORM SORT_LIST.
*CHANGE FCODE OF STATUS
PERFORM CHANGE_FCODE.
*CHECK RADIOBUTTON OPTION AND ACCORDINGLY FINAL DISPLAY
PERFORM CHECK_OPTION.
*& Form GET_DATA
* text
FORM GET_DATA.
SELECT VBELN
VBTYP
AUDAT
AUGRU
AUART
NETWR
WAERK FROM VBAK INTO TABLE IT_VBAK
WHERE VBELN IN S_VBELN AND VBTYP = P_VBTYP
AND ERDAT > '01.01.2004' AND NETWR > 0.
LOOP AT IT_VBAK.
IF IT_VBAK-NETWR < 10000.
IT_VBAK-ICON = '@08@'.
ELSEIF IT_VBAK-NETWR > 100000.
IT_VBAK-ICON = '@0A@'.
ELSE.
IT_VBAK-ICON = '@09@'.
ENDIF.
MODIFY IT_VBAK INDEX SY-TABIX.
ENDLOOP.
ENDFORM. "GET_DATA
*& Form CHECK_OPTION
* text
FORM CHECK_OPTION.
WA_EVENTS-NAME = 'TOP_OF_PAGE'.
WA_EVENTS-FORM = 'TOP'.
APPEND WA_EVENTS TO IT_EVENTS.
CLEAR WA_EVENTS.
WA_EVENTS-NAME = 'END_OF_LIST'.
WA_EVENTS-FORM = 'END_LIST'.
APPEND WA_EVENTS TO IT_EVENTS.
CLEAR WA_EVENTS.
IF LIST = 'X'.
PERFORM LIST_DISP.
ENDIF.
IF GRID = 'X'.
PERFORM GRID_DISP.
ENDIF.
ENDFORM. "CHECK_OPTION
*& Form DEFINE_FIELDCATALOG
* text
FORM DEFINE_FIELDCATALOG.
WA_FIELDCAT-COL_POS = 1.
WA_FIELDCAT-FIELDNAME = 'ICON'.
WA_FIELDCAT-SELTEXT_L = 'ICON'.
WA_FIELDCAT-ICON = 'X'.
WA_FIELDCAT-OUTPUTLEN = 8.
WA_FIELDCAT-TABNAME = 'IT_VBAK'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-COL_POS = 2.
WA_FIELDCAT-FIELDNAME = 'VBELN'.
WA_FIELDCAT-SELTEXT_L = 'SALES DOC NO.'.
WA_FIELDCAT-OUTPUTLEN = 10.
WA_FIELDCAT-TABNAME = 'IT_VBAK'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-COL_POS = 3.
WA_FIELDCAT-FIELDNAME = 'AUDAT'.
WA_FIELDCAT-SELTEXT_L = 'CREATED ON'.
WA_FIELDCAT-OUTPUTLEN = 10.
WA_FIELDCAT-TABNAME = 'IT_VBAK'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-COL_POS = 4.
WA_FIELDCAT-FIELDNAME = 'VBTYP'.
WA_FIELDCAT-SELTEXT_L = 'CATEGORY'.
WA_FIELDCAT-OUTPUTLEN = 1.
WA_FIELDCAT-TABNAME = 'IT_VBAK'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-COL_POS = 6.
WA_FIELDCAT-FIELDNAME = 'AUGRU'.
WA_FIELDCAT-SELTEXT_L = 'REASON'.
WA_FIELDCAT-OUTPUTLEN = 3.
WA_FIELDCAT-TABNAME = 'IT_VBAK'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-COL_POS = 5.
WA_FIELDCAT-FIELDNAME = 'AUART'.
WA_FIELDCAT-SELTEXT_L = 'DOC TYPE'.
WA_FIELDCAT-OUTPUTLEN = 4.
WA_FIELDCAT-TABNAME = 'IT_VBAK'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-COL_POS = 7.
WA_FIELDCAT-FIELDNAME = 'NETWR'.
WA_FIELDCAT-SELTEXT_L = 'NET VALUE'.
WA_FIELDCAT-OUTPUTLEN = 17.
WA_FIELDCAT-DECIMALS_OUT = 2.
* WA_FIELDCAT-DO_SUM = 'X'.
WA_FIELDCAT-TABNAME = 'IT_VBAK'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-COL_POS = 8.
WA_FIELDCAT-FIELDNAME = 'WAERK'.
WA_FIELDCAT-SELTEXT_L = 'UNIT'.
WA_FIELDCAT-OUTPUTLEN = 50.
WA_FIELDCAT-TABNAME = 'IT_VBAK'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
CLEAR WA_FIELDCAT.
ENDFORM. "DEFINE_FIELDCATALOG
*& Form DEFINE_LAYOUT
* text
FORM DEFINE_LAYOUT.
LAYOUT-ZEBRA = 'X'.
LAYOUT-SUBTOTALS_TEXT = 'SUBTOTAL SUM'.
LAYOUT-WINDOW_TITLEBAR = 'EXERCISE 2'.
LAYOUT-TOTALS_TEXT = 'TOTAL'.
ENDFORM. "DEFINE_LAYOUT
*& Form SORT_LIST
* text
FORM SORT_LIST.
WA_SORT-FIELDNAME = 'VBELN'.
WA_SORT-TABNAME = 'IT_VBAK'.
WA_SORT-SPOS = 1.
WA_SORT-UP = 'X'.
WA_SORT-SUBTOT = 'X'.
APPEND WA_SORT TO IT_SORT.
CLEAR WA_SORT.
WA_SORT-FIELDNAME = 'NETWR'.
WA_SORT-TABNAME = 'IT_VBAK'.
WA_SORT-UP = 'X'.
WA_SORT-SPOS = 2.
WA_SORT-SUBTOT = 'X'.
APPEND WA_SORT TO IT_SORT.
CLEAR WA_SORT.
ENDFORM. "SORT_LIST
*& Form LIST_DISP
* text
FORM LIST_DISP.
PERFORM DEFINE_LAYOUT.
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
I_CALLBACK_PROGRAM = SY-REPID
IT_FIELDCAT = IT_FIELDCAT
IS_LAYOUT = LAYOUT
IT_SORT = IT_SORT
I_CALLBACK_PF_STATUS_SET = 'STATUS'
IT_EXCLUDING = I_FCODE_EXTAB
I_CALLBACK_USER_COMMAND = 'USER_COMMAND'
IT_EVENTS = IT_EVENTS[]
* IMPORTING
* E_EXIT_CAUSED_BY_CALLER =
* ES_EXIT_CAUSED_BY_USER =
TABLES
T_OUTTAB = IT_VBAK
* EXCEPTIONS
* PROGRAM_ERROR = 1
* OTHERS = 2
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM. "LIST_DISP
*& Form GRID_DISP
* text
FORM GRID_DISP.
PERFORM DEFINE_LAYOUT.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_CALLBACK_PROGRAM = SY-REPID
IS_LAYOUT = LAYOUT
IT_FIELDCAT = IT_FIELDCAT
IT_SORT = IT_SORT
I_CALLBACK_PF_STATUS_SET = 'STATUS'
IT_EXCLUDING = I_FCODE_EXTAB
I_CALLBACK_USER_COMMAND = 'USER_COMMAND'
IT_EVENTS = IT_EVENTS[]
TABLES
T_OUTTAB = IT_VBAK.
* EXCEPTIONS
* PROGRAM_ERROR = 1
* OTHERS = 2
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM. "GRID_DISP
*& Form STATUS
* text
* -->P_EXTAB text
FORM STATUS USING P_EXTAB TYPE SLIS_T_EXTAB.
SET PF-STATUS 'STATUS' EXCLUDING P_EXTAB.
ENDFORM. "STATUS
*& Form USER_COMMAND
* text
* -->R_UCOMM text
* -->RS_SELFIELD text
FORM USER_COMMAND USING R_UCOMM LIKE SY-UCOMM
RS_SELFIELD TYPE SLIS_SELFIELD.
CASE R_UCOMM.
WHEN 'BACK' OR 'CANC' OR 'EXIT'.
LEAVE TO SCREEN 0.
WHEN '&IC1'.
SET PARAMETER ID 'AUN' FIELD RS_SELFIELD-VALUE.
CALL TRANSACTION 'VA03' AND SKIP FIRST SCREEN.
ENDCASE.
ENDFORM. "USER_COMMAND
*& Form CHANGE_FCODE
* text
FORM CHANGE_FCODE.
WA_FCODE = 'PRNT'.
APPEND WA_FCODE TO I_FCODE_EXTAB.
WA_FCODE = '&OAD'.
APPEND WA_FCODE TO I_FCODE_EXTAB.
WA_FCODE = '&AVE'.
APPEND WA_FCODE TO I_FCODE_EXTAB.
WA_FCODE = '&EB9'.
APPEND WA_FCODE TO I_FCODE_EXTAB.
WA_FCODE = '&SUM'.
APPEND WA_FCODE TO I_FCODE_EXTAB.
WA_FCODE = '&UMC'.
APPEND WA_FCODE TO I_FCODE_EXTAB.
WA_FCODE = '&XPA'.
APPEND WA_FCODE TO I_FCODE_EXTAB.
WA_FCODE = '&OMP'.
APPEND WA_FCODE TO I_FCODE_EXTAB.
ENDFORM. "CHANGE_FCODE
*& Form TOP
* text
FORM TOP.
IF LIST = 'X'.
WRITE:/ SY-ULINE.
WRITE:/ 'DATE:', SY-DATUM,55 'INTELLIGROUP ASIA PVT LTD'.
WRITE:/ 'TIME:', SY-UZEIT.
WRITE:/ 'USER NAME:', SY-UNAME,60 SY-TITLE.
WRITE:/ 'PAGE', SY-PAGNO.
WRITE:/ SY-ULINE.
ENDIF.
IF GRID = 'X'.
DATA: LS_LINE TYPE SLIS_LISTHEADER,
E04_LT_TOP_OF_PAGE TYPE SLIS_T_LISTHEADER.
* Listenüberschrift: Typ H
CLEAR LS_LINE.
LS_LINE-TYP = 'H'.
* LS_LINE-KEY: not used for this type
LS_LINE-INFO = 'Summary'.
APPEND LS_LINE TO E04_LT_TOP_OF_PAGE.
* Kopfinfo: Typ S
CLEAR LS_LINE.
LS_LINE-TYP = 'S'.
LS_LINE-KEY = 'Intelligroup'.
LS_LINE-INFO = ''.
APPEND LS_LINE TO E04_LT_TOP_OF_PAGE.
LS_LINE-KEY = 'ASIA'.
LS_LINE-INFO = 'PVT LTD'.
APPEND LS_LINE TO E04_LT_TOP_OF_PAGE.
* Aktionsinfo: Typ A
CLEAR LS_LINE.
LS_LINE-TYP = 'A'.
* LS_LINE-KEY: not used for this type
LS_LINE-INFO = 'truman'.
APPEND LS_LINE TO E04_LT_TOP_OF_PAGE.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
IT_LIST_COMMENTARY = E04_LT_TOP_OF_PAGE
I_LOGO = 'ENJOY_SAP_LOGO'.
ENDIF.
ENDFORM. "TOP
*& Form END_LIST
* text
FORM END_LIST.
IF LIST = 'X'.
SKIP 2.
WRITE:/60 'END OF PAGE'.
ENDIF.
IF GRID = 'X'.
DATA: LS_LINE TYPE SLIS_LISTHEADER,
E04_LT_END_OF_LIST TYPE SLIS_T_LISTHEADER.
* Listenüberschrift: Typ H
CLEAR LS_LINE.
LS_LINE-TYP = 'H'.
* LS_LINE-KEY: not used for this type
LS_LINE-INFO = 'Summary'.
APPEND LS_LINE TO E04_LT_END_OF_LIST.
* Kopfinfo: Typ S
CLEAR LS_LINE.
LS_LINE-TYP = 'S'.
LS_LINE-KEY = 'Intelligroup'.
LS_LINE-INFO = ''.
APPEND LS_LINE TO E04_LT_END_OF_LIST.
LS_LINE-KEY = 'ASIA'.
LS_LINE-INFO = 'PVT LTD'.
APPEND LS_LINE TO E04_LT_END_OF_LIST.
* Aktionsinfo: Typ A
CLEAR LS_LINE.
LS_LINE-TYP = 'A'.
* LS_LINE-KEY: not used for this type
LS_LINE-INFO = TEXT-105.
APPEND LS_LINE TO E04_LT_END_OF_LIST.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
IT_LIST_COMMENTARY = E04_LT_END_OF_LIST.
ENDIF.
ENDFORM. "END_LIST -
Master-detail: detail field not displayed after changed by master field
I want to use the Depends on item with Clear/refresh value functionality in a master detail situation. Within the same group it is no problem to use the setter method of a field to change a second field and then displaying this new value. But in the detail group, I can not select items from the master group as a depends on item.
In the setter of the master field, the value in a field for each row in the detail (table layout) is updated. The only problem is that this updated value is not displayed, the old value doesn't change. When saving the changes, the displayed value is committed to the database. When de updated field is not displayed at all, the correct value is saved, so I know the detail field is updated.
How can I make sure the displayed value in the detail is displayed after changeing a master field? I already gave the detail field the correct partial trigger.Wouter,
I guese you don;t see the changed value when you display the detail item because after the depends on item update changed the detail item, JSF procesing continues and the detail table changes are sent to the server which will override again the detail item attriibute, resetting it to the old, still displayed value.
So, the trick is to get PPR working. Make sure the partialTYriggers property of the detail item is set to the value of the id property of the master item. If it still doesn't work, try setting the partial triggers property on the table, instead of the individual item.
Steven Davelaar,
JHeadstart team -
How to add new fields to standard reports
hi friends,
im into ABAP and working across all modules..the basic thing is users and functional people are not satisfied with the standard reports..they need some logic change or to add some more fieldsinb the standard reports.For logic change we have to copy the standard to zprogram and can do or create a new program itself..but in many cases they ask for extra fields.how to achive it ..
for example my requirement now is adding vendor name field to the report FAGGL03 ....i found a badi and have make changes to it ...now the vendor name will be coming in sgtxt over writing the text ...but they need text also...now what shall i do???
append structure vendor name field in faglposx table ....???how to find out the final internal table from where the output is coming ????
?when we check the standard rewport codes...there are lot of include statements perform statements etc ...how to find out the final structure or internal table which has the output values..???hi
it would be better if u giv full name of the report
if ur displaying the data in alv then search for the
word REUSE_ALV_LIST_DISPLAY REUSE_ALV_GRID_DISPLAY from which u can get the final table name
then check the data that is comming into
try using implicit enhancement or any other exit in the declaration and declare a new structure with the field and append it to the field catalog
if ur displaying the data using write statement
then create a zprogram and add a write statement
fi ur unable to find here the final table then after displayign the report start the debugging and double click on any row to find out more easily
shiva -
User Comment field available for reporting?
User Comment field available for reporting?
When doing custom reporting against requests with reportable dictionaries we have a user request to also include the user comments. How do I reference / point to the comments field for a request?If you are referring to the comments which are added in the Comments and History section of a requisition, this information is not migrated to the datamart and is not reportable.
If, on the other hand, you are referring to a comments field that you have included in a dictionary on the service form, that information will be available in the datamart so long as that dictionary has been made reportable.
Maybe you are looking for
-
Problem in posting the goods receipt with reference to the inbound delivery
Hi All, Below is the explanation of the scenario: 1. Materials are purchased (PO created in CAS as order unit) and inbound delivery document is created in cases as well. 2. When the TO is created for put away (we are performing put away using the han
-
IDvd won't display thumbnails of slideshow photos
Hi, I'm having trouble with my iDvd. All works fine, music, themes, and the like, but when I want to make a slideshow, with selected photos, idvd does not display the photos in the thumbnail view. All it does is try to load it. I've waited and waited
-
Problems defining the datasource with coldfusion 9
I just upgraded Macromedia MX7 with coldfusion 9. The local host was http://localhost:8500/ows. I am not sure if this address is the same for coldfusion 9. When I try to define the datasource, I still see Macromedia MX7 instead of coldfusion 9 in adm
-
All of a sudden, I can no longer add a Bookmark by selecting 'Bookmark This Page', then select its destination file. Now it's a lot more work to move the new Bookmark to the file I've chosen for its destination. Was this option eliminated, or is some
-
Hi We are getting the next erros with the jobs: 13:13:51 PRDAUNE2_PRD_02 BTC 22 000 SAPSYS F6H Database error: TemSe->XRTAB(2)->1 for table TST01 key 13:13:51 PRDAUNE2_PRD_02 BTC 22 000 SAPSYS