Modify Report Header using an expression
Hi All,
I would like to know if we can modify the Report Header programmatically? I basically would like to append a couple of lines in the header.
I can think of two ways -
1. ModifyReportHeader callback - this is really not an option for me as we need to do the implementation in a custom step.
2. Override the default reportgen_txt.seq and reportgen_html.seq and edit them as necessary - this one seems a bit ugly to me.
Any other ideas?
thanks and regards,
aCe
Beginner? Try LabVIEW Basics
Sharing bits of code? Try Snippets or LAVA Code Capture Tool
Have you tried Quick Drop?, Visit QD Community.
Solved!
Go to Solution.
Ray,
Sorry, I if I was not clear earlier.
This custom step would be used by a test sequence developer who has very little understanding of TestStand.
The idea is that the person would drag and drop this step in to a sequence and add details of the Unit under test during edit-time which then should appear in the report header along with serial numbers etc. when the program is run.
For example, data such as:
Test Specification: X123-456-789 Issue x
Unit Part#: xxxxxxx
Interface Part# xxxxxxxxxxxx
Asking someone to add the callback would then require TestStand skills and would defeat our goal of trying to deskill this operation.
I hope I am making sense!
Thanks and regards,
aCe
Beginner? Try LabVIEW Basics
Sharing bits of code? Try Snippets or LAVA Code Capture Tool
Have you tried Quick Drop?, Visit QD Community.
Similar Messages
-
Insert fields in a report header using SortValue() function (PLD)
Hi...
I need to create a user report, based on a query, that shows the following fields.
CardCode | CardName | Phone1 | E_mail (header)
Adress | AddrType | Street | Streetno ...(repetitive area)
I have inserted only one filed sucessfully using the <Group 1> and adding the SortValue() function in the header with the cardcode field...
How can i insert the other fields in the header?
thanks...I just put a formula in the header with the Field name...and works fine...
Thanks.... -
SSRS Text box expression in Report Header
Hi Experts,
I'm trying below expression under Text box (Report Header)
= IIf( IsNothing(Parameters!vCp_ID.Value) OR Parameters!vCp_ID.Value = "", "All", Join(Parameters!vCp_ID.Value,", ") )
It gives me error message as:-
Warning 1 [rsRuntimeErrorInExpression] The Value expression for the textrun ‘Header_Cp_ID_Value.Paragraphs[0].TextRuns[0]’ contains an error: Overload resolution failed because no Public '=' can be called with these arguments: 'Public Shared Operator =(a As String, b As String) As Boolean': Argument matching parameter 'a' cannot convert from 'Object()' to 'String'. C:\Users\abc1\Documents\Visual Studio 2008\Projects\Report Project1\Report Project1\ClaimsLevel.rdl 0 0
Any help what I'm doing wrong? Because of this is it printing "#Error" while previewing the Report.
If I remove IIF condition and place only:-
Join(Parameters!vCp_ID.Value,", ")
than everything is working fine.
Thanks in advance
Kumar
KG, MCTSHi,
Since this parameter allows selection of multi values, the values of the parameter is returned as an array which cannot be used in comparing with = operator, as you have in the expression
Parameters!vCp_ID.Value = "".
You may pass the first value of the parameter (element with 0 index) instead like
Parameters!vCp_ID.Value(0) = "". Note the .Value(0). As such, you expression may be written as
= IIf( IsNothing(Parameters!vCp_ID.Value) OR Parameters!vCp_ID.Value(0) = "", "All", Join(Parameters!vCp_ID.Value,", ") )
Hope this helps. Please feel free to discuss if you have any other questions.
Regards
Please click "Mark as Answer" if this resolves your problem or "Vote as Helpful" if you find it helpful.
BH -
Need help to modify a report written using Field-Groups Concept. - Part1
Hello ABAP Experts,
I need your help to modify the following report with following requirement as I have least knowledge
about the field-group concept. Thats is the reason, I am pasting the whole code. As it is part of our
production requirement. I really appreciate your help, If its sent modifying the code required.
Modification required in the report.
To allow the sales representatives to see billed shipments and open orders for the current month.
1) Selection Screen Changes:
u2022 Add selection by Sales group and Customer group
u2022 Add sort by: 3. Ship-to / Material
u2022 Add another selection box
[ ] Open Orders and Shipments with the current month
2) For the new selection box, subtotal sales quantity and delivery quantity.
If delivered, make the sales quantity zero in the subtotal
Current report displays, in Selection Screen
Sales org:
Person Name:
Material:
Plant:
Sales Office:
Ship to Name:
Ship to Number:
Sorts Report by : 1. Person Name 2. Material
Check Boxes : 1. Open Orders 2. Delayed Orders.
report zorder LINE-SIZE 170
LINE-COUNT 58
MESSAGE-ID zv
NO STANDARD PAGE HEADING.
TABLES:
cdhdr, "Change Doc Header
cdpos, "Change Doc Item
kna1, "Customer master
likp, "Delivery Header
lips, "Delivery Item
*lips, "Delivery Item
zvbpa_lfa1, "Vendor Master
makt, "Material Desc
t001w, "Plant
tvkbt, "Sales Office
tvko, "Sales Organizations
vbak, "Sales Header
vbap, "Sales Item
zvvbak, "Sales Hdr - Time calc
vbup, "Item status
vbep, "Sales Schedule Line
vbfa, "Flow documents
vbpa, "Partners
vbrk, "Billing Header
vbrp. "Billing Item
SELECT-OPTIONS:
s_vkorg FOR vbak-vkorg OBLIGATORY,
s_ernam FOR vbak-ernam,
s_matnr FOR vbap-matnr,
s_werks FOR vbap-werks,
s_vkbur FOR vbak-vkbur,
s_name1 FOR kna1-name1,
s_kunnr FOR kna1-kunnr.
SELECTION-SCREEN ULINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(49) text-c20.
PARAMETERS: p_sort TYPE n DEFAULT '1'.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 19(40) text-022.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 19(40) text-023.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 19(40) text-024.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN COMMENT 19(40) text-070.
SELECTION-SCREEN ULINE.
SELECTION-SCREEN BEGIN OF BLOCK b20 WITH FRAME.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS:p_open AS CHECKBOX DEFAULT 'X'.
SELECTION-SCREEN COMMENT 5(48) text-072.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS:p_delay AS CHECKBOX DEFAULT 'X'.
SELECTION-SCREEN COMMENT 5(48) text-073.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF BLOCK b20.
DATA:
vbeln(11), "Document number
cancel_dt TYPE d, "Cancellation Date
BEGIN OF tabkey, "Tabkey
mandant LIKE sy-mandt,
vbeln LIKE vbap-vbeln,
posnr LIKE vbap-posnr,
END OF tabkey,
name1_sp1 LIKE lfa1-name1, "Sales Carrier Name
name1_sp2 LIKE lfa1-name1, "Delivery Carrier Name
datum-1 TYPE d, "Current Dt Less 1
datum-14 TYPE d, "Current Dt Less 14
datum-90 TYPE d, "Current Dt Less 90
rpt_hdr1(170), "Report Header 1
rpt_hdr2(170), "Report Header 2
rpt_hdr3(170), "Report Header 3
cb_hdr1(170), "Control Break Header 1
line_pos1 TYPE i, "Line Print Position HDR1
line_pos2 TYPE i, "Line Print Position HDR2
line_pos3 TYPE i, "Line Print Position DET2
status, "Order Status
open, "Open Order
delayed VALUE 'D', "Delayed Order
v_comp(30). "Company Text Field
DATA: v_flagh2. " Flag for header 2 & 3
DATA: ls_comwa LIKE vbco6. "Structure for flow information
DATA: t_vbfa_tab TYPE STANDARD TABLE OF vbfa WITH HEADER LINE."Itab
for flow information
data: g_trans_id type vttk-tdlnr. "get transport id from flow
information
data v_sales_org_cpimex type vkorg value '3300'.
FIELD-GROUPS:
header,
order.
INSERT
status "Status
vbak-vkbur "Sales Office
vbak-ernam "Created By
kna1-kunnr "Customer
kna1-name1 "Customer Name
vbap-matnr "Material
vbap-werks "Plant
vbep-lddat "Load Dt
vbap-vbeln "Sales Document
INTO header.
INSERT
kna1-ort01 "City
kna1-regio "Region
likp-traid "Transport ID
lips-vbeln "Delivery Document
lips-ntgew "Net Wt
lips-gewei "Unit of Weight
vbap-kwmeng "Order Qty
vbap-vrkme "Sales Unit
vbak-bstnk "Customer PO
vbak-erdat "Sales Create Dt
vbak-ihrez "PO Release
vbak-vdatu "Req Delivery Dt
vbak-vzeit "Req Delivery Time
vbfa-vbeln "Goods issue doc
vbrk-vbeln "Billing Document
name1_sp1 "Sales Carrier
name1_sp2 "Delivery Carrier
INTO order.
INITIALIZATION.
AT SELECTION-SCREEN.
IF NOT p_sort BETWEEN 1 AND 2.
MESSAGE e022 WITH p_sort.
ENDIF.
* Report 1 or more of cancelled, delayed or open
IF p_open IS INITIAL AND
p_delay IS INITIAL.
MESSAGE e023.
ENDIF.
START-OF-SELECTION.
* Load Company Name
WRITE 'XYZ INC'(000) TO v_comp.
* Calculate Date Range
datum-1 = sy-datum - 1.
datum-14 = sy-datum - 14.
datum-90 = sy-datum - 90.
* Compose Parameter Header
PERFORM parm_hdr.
** Compose Report Header
v_flagh2 = 1.
PERFORM data_selection.
END-OF-SELECTION.
* Determine Sort
CASE p_sort.
WHEN 1.
SORT BY status vbak-ernam kna1-name1 kna1-kunnr
vbep-lddat vbap-vbeln.
WHEN 2.
SORT BY status vbap-matnr vbap-werks vbep-lddat
vbap-vbeln.
ENDCASE.
LOOP.
AT NEW status.
CASE status.
WHEN delayed.
WRITE 'Delayed Orders'(061) TO rpt_hdr1.
WHEN OTHERS.
WRITE 'Open Orders'(062) TO rpt_hdr1.
ENDCASE.
NEW-PAGE.
ENDAT.
AT NEW vbak-ernam.
IF p_sort = 1.
CLEAR cb_hdr1.
WRITE 'CAA:'(064) TO cb_hdr1.
WRITE vbak-ernam TO cb_hdr1+5.
NEW-PAGE.
ENDIF.
ENDAT.
AT NEW vbap-matnr.
IF p_sort = 2.
CLEAR makt.
SELECT SINGLE * FROM makt
WHERE spras = sy-langu AND
matnr = vbap-matnr.
CLEAR cb_hdr1.
WRITE 'Material:'(042) TO cb_hdr1.
WRITE vbap-matnr TO cb_hdr1+10.
WRITE makt-maktx TO cb_hdr1+21.
NEW-PAGE.
ENDIF.
ENDAT.
AT NEW vbap-werks.
AT order.
RESERVE 3 LINES.
SKIP 1.
NEW-LINE.
* Indicate new open item
WRITE vbap-vbeln TO vbeln.
* Find Transport ID
* Fill the structure LS_COMWA
ls_comwa-mandt = sy-mandt.
ls_comwa-vbeln = vbap-vbeln.
CALL FUNCTION 'RV_ORDER_FLOW_INFORMATION'
EXPORTING
comwa = ls_comwa
TABLES
vbfa_tab = t_vbfa_tab.
IF sy-subrc EQ 0.
READ TABLE t_vbfa_tab WITH KEY vbtyp_n = '8'.
IF sy-subrc EQ 0.
SELECT SINGLE tdlnr INTO g_trans_id
FROM vttk WHERE tknum = t_vbfa_tab-vbeln.
CONDENSE g_trans_id.
ENDIF.
ENDIF.
IF vbak-erdat >= datum-1.
vbeln+10 = 'N'.
ENDIF.
CASE p_sort.
WHEN 1.
WRITE 1 vbak-vkbur.
WRITE 8 kna1-name1.
WRITE 44 vbeln.
WRITE 56 vbap-matnr.
WRITE:
75 vbap-kwmeng LEFT-JUSTIFIED,
vbap-vrkme,
100 vbak-bstnk,
vbak-ihrez,
134 vbak-vdatu,
vbak-vzeit,
154 vbep-lddat.
WRITE 166 vbap-werks.
NEW-LINE.
WRITE:
5 kna1-ort01,
41 kna1-regio.
IF name1_sp2 IS INITIAL.
WRITE:
45 name1_sp1,
ELSE.
WRITE 45 name1_sp2.
IF name1_sp1 = name1_sp2.
WRITE ' '.
ELSE.
WRITE '*'.
ENDIF.
ENDIF.
IF vbak-vkorg = v_sales_org_cpimex .
WRITE 81 g_trans_id.
ELSE.
WRITE 81 likp-traid.
ENDIF.
WRITE:
102 lips-vbeln,
115 lips-ntgew NO-ZERO LEFT-JUSTIFIED,
lips-gewei,
140 vbfa-vbeln,
152 vbrk-vbeln.
WHEN 2.
WRITE 1 vbak-ernam.
WRITE 14 vbak-vkbur.
WRITE 21 kna1-name1.
WRITE 57 vbeln.
WRITE:
69 vbap-kwmeng LEFT-JUSTIFIED,
vbap-vrkme,
92 vbak-bstnk,
vbak-ihrez,
126 vbak-vdatu,
vbak-vzeit,
146 vbep-lddat.
WRITE 162 vbap-werks.
NEW-LINE.
WRITE:
5 kna1-ort01,
41 kna1-regio.
IF name1_sp2 IS INITIAL.
WRITE:
45 name1_sp1,
ELSE.
WRITE 45 name1_sp2.
IF name1_sp1 = name1_sp2.
WRITE ' '.
ELSE.
WRITE '*'.
ENDIF.
ENDIF.
IF vbak-vkorg = v_sales_org_cpimex .
WRITE 81 g_trans_id.
ELSE.
WRITE 81 likp-traid.
ENDIF.
WRITE:
102 lips-vbeln,
115 lips-ntgew NO-ZERO LEFT-JUSTIFIED,
lips-gewei,
140 vbfa-vbeln,
152 vbrk-vbeln.
ENDCASE.
ENDAT.
ENDLOOP.
* FORM PARM_HDR *
FORM parm_hdr.
WRITE 'Program selections'(101) TO rpt_hdr1.
WRITE 'Sign'(102) TO rpt_hdr1+29.
WRITE 'Option'(103) TO rpt_hdr1+34.
WRITE 'From'(104) TO rpt_hdr1+41.
WRITE 'To'(105) TO rpt_hdr1+77.
ENDFORM. "PARM_HDR
* FORM RPT_HDR *
FORM rpt_hdr.
CASE p_sort.
WHEN 1. "When sort by CAA
WRITE 1'SOff'(066).
WRITE 8'Customer'(009).
WRITE 44'Sales Doc'(010).
WRITE 56'Material'(031).
WRITE 75'Sales Qty'(011).
WRITE 100'Customer PO'(012).
WRITE 134'Req.Del.Dt & Tm'(014).
WRITE 154'Load Dt'(015).
WRITE 166'Plnt'(016).
NEW-LINE.
WRITE 5'City'(017).
WRITE 41'Reg'(069).
WRITE 45'Carrier'(018).
WRITE 81'Transport ID'(019).
WRITE 102'Dlvry Doc'(021).
WRITE 115'Dlvry Qty'(025).
WRITE 140'PGI Doc'(026).
WRITE 152'Billng Doc'(027).
WHEN 2. "When sort by Material
WRITE 1'Created By'(008).
WRITE 14'SOff'(066).
WRITE 21'Customer'(009).
WRITE 57'Sales Doc'(010).
WRITE 69'Sales Qty'(011).
WRITE 92'Customer PO'(012).
WRITE 126'Req.Del.Dt & Tm'(014).
WRITE 146'Load Dt'(015).
WRITE 162'Plnt'(016).
NEW-LINE.
WRITE 5'City'(017).
WRITE 41'Reg'(069).
WRITE 45'Carrier'(018).
WRITE 81'Transport ID'(019).
WRITE 102'Dlvry Doc'(021).
WRITE 115'Dlvry Qty'(025).
WRITE 140'PGI Doc'(026).
WRITE 152'Billng Doc'(027).
ENDCASE.
ENDFORM. "RPT_HDR
INCLUDE zrpthdri.
WRITE:
/ rpt_hdr1.
ULINE.
IF v_flagh2 <> 0.
PERFORM rpt_hdr. "Write secondary header
ULINE.
* Control Break Header
WRITE / cb_hdr1.
ENDIF.
Continued in Part-2
Thanks a ton in advance.
Mythili Sharma
Edited by: Mythili sharma on Mar 30, 2009 3:32 AM
Edited by: Rob Burbank on Mar 30, 2009 10:46 AMHello ABAP Experts,
I need your help to modify the following report with following requirement as I have least knowledge about the field-group concept. Thats is the reason, I am pasting the whole code. As it is part of our production requirement. I really appreciate your help, If its sent modifying the code required.
Modification required in the report.
To allow the sales representatives to see billed shipments and open orders for the current month.
1) Selection Screen Changes:
u2022 Add selection by Sales group and Customer group
u2022 Add sort by: 5. Ship-to / Material
u2022 Add another selection box
[ ] Open Orders and Shipments with the current month
2) For the new selection box, subtotal sales quantity and delivery quantity.
If delivered, make the sales quantity zero in the subtotal
Current report displays, in Selection Screen
Sales org:
Person Name:
Material:
Plant:
Sales Office:
Ship to Name:
Ship to Number:
Sorts Report by :
1. Person Name
2. Material
3. Plant
4. Sales Office
Check Boxes :
1. Open Orders
2. Delayed Orders
3.Cancelled Orders
PLEASE DOWNLOAD THE COMPLETE REPORT FROM THE FOLLOWING LINK
<< Link removed >>
It would be a great help, If the program is modified according to the requirement and snd it back through send space and send link, even if u send the necessary changes to be done in the report is also appreciable.
Thanks a ton in adanvce
Mythili
I wanted to close this thread as I could not put my question in a proper format. So please reply in the new thread which is posted.
Edited by: Mythili sharma on Mar 30, 2009 2:16 PM
Edited by: Rob Burbank on Mar 30, 2009 4:24 PM -
Unable to modify Report using JRC alone
Hi
I am trying to modify the report generated thru Crystal reports 2008 programmatically using JRC.
I dont see any API in com.crystaldecisions.reports.sdk.DataDefController to modify filters,groups,parameters,sort objects and summaries.
I could find Controller API to modify the above in com.crystaldecisions.sdk.occa.report.application package part of RAS SDK which requires RAS to be installed.
WIll it be possible to modify report using JRC alone?
because when i use com.crystaldecisions.sdk.occa.report.application.ReportClientDocument class to open a report, it thorws
ReportSDKServerException: There is no server specified exception.
and i am not sure what need to set for ReportClientDocument.setReportAppServer()
Pls help me .Hi,
Thanks for your help.
I am getting the below exception when I am trying to open a report programmatically using com.crystaldecisions.reports.sdk.ReportClientDocument.
oReportClientDocument.open(reportName, 0);
I am not sure how to resolve this issue.
I have even created a new rpt file. I am getting the same exception/
I could open this report directly thru Crystal Reports.
12/16/10 16:19:57:376 IST] 10c3f2a6 WebGroup E SRVE0026E: [Servlet Error]-[The document is being opened.]: com.crystaldecisions.sdk.occa.report.lib.ReportSDKException: The document is being opened.---- Error code:-2147215349 Error code name:docNotReady
Error code:-2147215349 Error code name:docNotReady
at com.crystaldecisions.sdk.occa.report.lib.ReportSDKException.throwReportSDKException(Unknown Source)
at com.crystaldecisions.client.helper.ObjectState.a(Unknown Source)
at com.crystaldecisions.client.helper.ObjectState.if(Unknown Source)
at com.crystaldecisions.client.helper.ObjectState.stopping(Unknown Source)
at com.crystaldecisions.sdk.occa.report.application.ClientDocument.close(Unknown Source)
at com.crystaldecisions.sdk.occa.report.application.ReportClientDocument.close(Unknown Source)
at com.crystaldecisions.reports.sdk.ReportClientDocument.close(Unknown Source)
at org.apache.jsp._CrystalReportViewer._jspService(_CrystalReportViewer.java:389)
at com.ibm.ws.webcontainer.jsp.runtime.HttpJspBase.service(HttpJspBase.java:89)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:344)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.serviceJspFile(JspServlet.java:662)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.service(JspServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java:110)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java:174)
at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java:313)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java:116)
at com.ibm.ws.webcontainer.servlet.ServletInstance.service(
Pls help me.
Edited by: D.Sangeetha on Dec 16, 2010 12:33 PM -
Display PDF file in the Apex query report using HTML Expression
Hi Folks,
I have PDFs stored in BLOB columns along with FILE_ID column in the database.
I want to display these to the APEX user on the page at runtime.
I have created a SQL Query report page to display FILE_ID column.
I am using HTML Expression property of the FILE_ID column to pull the image from the table using PROC_DISPLAY_DOCUMENT procedure.
I typed folowing code int the HTML Expression text area of the FILE_ID column of the report page :
<img src="#OWNER#.proc_display_document?p_id=#file_id#"/>
I am using following Procedure code:
create or replace procedure "PROC_DISPLAY_DOCUMENT"(p_id number) as
s_mime_type varchar2(48);
n_length number;
s_filename varchar2(400);
lob_image blob;
Begin
select MIME_TYPE,dbms_lob.getlength(blob_content),file_name,blob_content
into s_mime_type,n_length,s_filename,lob_image
from tbl_upload_file
where file_id = p_id;
owa_util.mime_header(nvl(s_mime_type, 'application/octet' ),false);
--set the size so the browser knows how much it will be downloading
htp.p( 'content-length: '|| n_length );
--The file name will be used by the browser if the users does a "save as"
htp.p( 'content-Disposition: filename="' || s_filename ||'"');
owa_util.http_header_close;
--Download the BLOB
wpg_docload.download_file( lob_image );
exception
WHEN NO_DATA_FOUND THEN
RAISE_APPLICATION_ERROR(-202121,'Record matching screenfield filename not found, PROC_DISPLAY_DOCUMENT.');
end;
--This is very Important
--grant execute on PROC_DISPLAY_DOCUMENT to public;
This code does not work and report does not display PDF image.
Any help to troubleshoot this code will be appreciated.
Thank you in advance.
JayaHi Dimitri,
I hope you can see HTML Expression code now. Thank You for responding.
I have PDFs stored in BLOB columns along with FILE_ID column in the database.
I want to display these to the APEX user on the page at runtime.
I have created a SQL Query report page to display FILE_ID column.
I am using HTML Expression property of the FILE_ID column to pull the image from the table using PROC_DISPLAY_DOCUMENT procedure.
I typed folowing code int the HTML Expression text area of the FILE_ID column of the report page :
[!-- img src="#OWNER#.proc_display_document?p_id=#file_id#" ]
I am using following Procedure code:
create or replace procedure "PROC_DISPLAY_DOCUMENT"(p_id number) **
mimetype varchar2(48);
n_length number;
s_filename varchar2(400);
lob_image blob;
Begin
select MIME_TYPE,dbms_lob.getlength(blob_content),file_name,blob_content
into s_mime_type,n_length,s_filename,lob_image
from tbl_upload_file
where file_id = p_id;
owa_util.mime_header(nvl(s_mime_type, 'application/octet' ),false);
--set the size so the browser knows how much it will be downloading
htp.p( 'content-length: '|| n_length );
--The file name will be used by the browser if the users does a "save as"
htp.p( 'content-Disposition: filename="' || s_filename ||'"');
owa_util.http_header_close;
--Download the BLOB
wpg_docload.download_file( lob_image );
exception
WHEN NO_DATA_FOUND THEN
RAISE_APPLICATION_ERROR(-202121,'Record matching screenfield filename not found, PROC_DISPLAY_DOCUMENT.');
end;
--This is very Important
--grant execute on PROC_DISPLAY_DOCUMENT to public;
This code does not work and report does not display PDF image.
Any help to troubleshoot this code will be appreciated.
Thank you in advance.
Jaya -
How to get prompt value in Financial Reporting and use it as header
Hi Oracle Gurus,
I have Hyperion Financial Reporting 11.1.1.3. I created a report.
I have Products dimension on rows. And I also have prompt for Products.
Let's say there is 3 products, Product A, B, and C, with each has its own level 0 item (for example A1, A2, B1, C1)
Currently in my situation, user will be prompted to select a list of Products, and then the report will display only the level 0 of the product chosen by the user. For example, user select Product A, then the report (or the grid) will display A1 and A2 on rows. User select Product B, B1 will be displayed.
My question is, I want to create a dynamic header report, so how can I get this prompt value and use it as a report header? For example: Sales of Product A when user choose Product A, or Sales of Product B when user choose Product B.
Thanks a lot for your response.Hi,
Here is the possible way to achieve it:
1. Insert a row (may be as row 1) in the report which has product as "User prompt".
2. mark this row as hidden always
3. User other rows as level0 of product in row 1
4. Use MEMBERALIAS in your header to use product as dimension & row as row1
Hope it helps !!
Edited by: user8628169 on Jun 22, 2011 10:53 AM -
Read, Modify and Apply Report XML using Java Script
Hi Guys,
Is there any way that we can Pragmatically Read, Modify and Apply Report XML using Java Script or some other way.
Thanks
Kaushik
Edited by: Kaushik K on Jun 20, 2012 8:36 PMRequirement ::
Users should be able to add Column to the Report Dynamically at Runtime.
(There are around 1000+ Users, Answers Approach is not acceptable)
So we are planning to provide a Multi Select / Shuttle Box Option for Users to add Columns dynamically. (Only for Table View)
What we planned to DO ::
Create a Presentation Variable Prompt, Which reads the Metadata Table (Presentation Table.Column Name, populated using the Metadata Dictionary)
And Create a report with One Column and the Column Fx like @{var_dynamic_columns}{'"Time"."Year","Time"."Month"'}
With this, OBIEE is rewriting the Logical SQL Currently as "Select "Time"."Year","Time"."Month" from "A - Sample Sales" "
But getting an error
The number of columns returned in retrieving column metadata was invalid (expected: 1; received: 2)
So we want to see, if we can rewrite the Advanced XML of the Report to have dynamic columns based on the Values from the Presentation Variable.
Please help me if this is a viable solution or any other better solution. -
About using cursor expressions in Oracle Reports
I've just discovered a rather old syntax of the mighty select statement. It seems related to the concept of inline view or more precisely scalar view. It's the cursor syntax in a select statement.
Example:
select d.dname
,cursor(select e.empno,e.ename,sal
from scott.emp e
where e.deptno = d.deptno)
from scott.dept d
I have two questions:
1) Performance: how is the performance of this select in comparison to standard join?
2) Usage: I've use this from sqlplus and it's ok, but can't use it on a tool like Oracle Reports. Although the select statement is correctly processed, can't display it since the datatype is Database - Unknown ...
It seems there´s no way to use cursor expressions at least if datasource is a SQL Query.
Thanks in advance ....I think you have answered your own question: CURSOR is not something you can display.
-
Teststand, modifying xml report header
1) How do I add a station gloabl variable to the XML report header? I am using standard expand.xsl.
2) Does the example on this page work to change the displaying execution time in HH:MMS format? I am not seeing the expected resutls.
http://zone.ni.com/reference/en-XX/help/370052H-01/tssuppref/infotopics/changing_time_display/
Thanks,
-TCHi,
Here are the answers to your queries assuming you are using teststand 4.2 or above:
1. Report header modification in expand.xsl is mentioned in the following link: http://zone.ni.com/devzone/cda/epd/p/id/4759
In this explanation, the text which is getting display after the report generation can be replaced by a variable(local or global) in the "Modifyreportheader" callback.
2. The display execution does work as explained by NI in the link provided.
If you want the example for the above two queries please find the attached files and explaination given below.
In the sequence file, in "ModifyReportheader" callback, the first statement includes " Locals.newstring=" <Prop Name='New_Text' Type='String' Flags='0x0'><Value>"+Locals.message+"</Value> </Prop>
where "locals.message" can be replaced by global variable.
and you need to place the "expand.xsl" in stylesheets folder. Please rename the existing "expand.xsl" and place the new one.
Hope this helps.
Regards,
Surya.
Attachments:
Reportheader.zip 25 KB -
??? Using JSPs to Send Not-Modified-Since Header ???
Hi all,
In looking at past posts, I'm afraid I know the horrible answer
to this issue but I thought I'd ask just in case I missed
anything.
Let me start by saying I'm using Tomcat v4.0.4 beta 3.
As you know, when a client (usually a web browser) has a cached
version of a resource (usually a web page) it can send an
"If-Modified-Since" header to the HTTP server. The server
compares the time/date stamp specified in the header with that of
the requested resource. If the resource has not been modified
since the time specified in the "If-Modified-Since" header, the
server sends back a 304 (Not-Modified) response, effectively
telling the client (usually a web browser) that its cached
version of the resource is still valid.
When writing a servlet, it's easy to handle this sort of
scenario. The javax.servlet.http.HttpServlet class has a
"service()" method. This method first checks if the incoming HTTP
method is a GET. If it is, the "service()" method proceeds to
call the "getLastModified()" method of the servlet. As a
developer, you can override "getLastModified()" to return a long
value representing the last time the requested resource was
changed. Depending on the value returned by "getLastModified()"
(note that -1 is returned if you don't override the method) the
"service()" method may simply return a 304, Not-Modified response
rather than calling the servlet's "doGet()" method.
Now, the $18.32 Question: How do you ensure "getLastModified()"
is called in JSP?
No, you cannot simply do this:
<%!
public long getLastModified() {
return xxx;
%>The problem is that the above method will never be called by the
container.
I traced through some of the Tomcat/Catalina/Jasper code and it
seems to me that the response code is being set to 200/OK very
early on in the processing.
I also took a cursory look at the JSP spec and didn't find any
indication of setting a "Not-Modified" response code...so, I am
thinking this is something that is (strangely) missing in the JSP
specification. I have a JSP page that needs to update itself once
per day. Therefore, it would be very handy to have the
"getLastModified()" functionality enjoyed by servlet writers.
Can anyone confirm this?
Thanks...I've not come across this before, but like you I cannot find any mention of how to handle modification dates in the JSP spec. I can think of a couple of possible ways round this:
1. Try to delegate the functionality to a servlet. You'd need to pass the JSPs modification date and handle the return. Seems messy and I haven't tried it.
2. Add code to the JSP to read the headers directly and set the appropriate status code. e.g. at start of JSP:
<%@page import="java.util.*" %>
<%
if (request.getMethod().equals("GET")) {
GregorianCalendar lastModified = new GregorianCalendar(2002, 01, 01); // use constant for testing
response.setDateHeader("Last-Modified", lastModified.getTimeInMillis()); //always set header
long modifiedSince = -1;
try {
modifiedSince = request.getDateHeader("If-Modified-Since");
} catch (IllegalArgumentException iae) {
// System.out.println(iae);
if (modifiedSince != -1 && modifiedSince > lastModified.getTimeInMillis()) {
response.setStatus(HttpServletResponse.SC_NOT_MODIFIED);
return;
%>This would probably best be implemented as a custom tag if needed in more than one page. -
In order to dynamically display data in the Report Header based in the current record of the Dataset, we started using Shared Variables, we initially used ReportItems!SomeTextbox.Value, but we noticed that when SomeTextbox was not rendered in the body
(usually because a comment section grow to occupy most of the page if not more than one page), then the ReportItem printed a blank/null value.
So, a method was defined in the Code section of the report that would set the value to the shared variable:
public shared Params as String
public shared Function SetValues(Param as String ) as String
Params = Param
Return Params
End Function
Which would be called in the detail section of the tablix, then in the header a textbox would hold the following expression:
=Code.Params
This worked beautifully since, it now didn't mattered that the body section didn't had the SetValues call, the variable persited and the Header displayed the correct value. Our problem now is that when the report is being called in different threads with
different data, the variable being shared/static gets modified by all the reports being run at the same time.
So far I've tried several things:
- The variables need to be shared, otherwise the value set in the Body can't be seen by the header.
- Using Hashtables behaves exactly like the ReportItem option.
- Using a C# DLL with non static variables to take care of this, didn't work because apparently when the DLL is being called by the Body generates a different instance of the DLL than when it's called from the header.
So is there a way to deal with this issue in a multi thread safe way?
Thanks in advance!
Hi Angel,
Per my understanding that you want to dynamic display the group data in the report header, you have set page break based on the group, so when click to the next page, the report hearder will change according to the value in the group, when you are using
the shared variables you got the multiple thread safe problem, right?
I have tested on my local environment and can reproduce the issue, according to the multiple safe problem the better way is to use the harshtable behaves in the custom code, you have mentioned that you have tryied touse the harshtable but finally got
the same result as using the ReportItem!TextBox.Value, the problem can be cuased by the logic of the code that not works fine.
Please reference to the custom code below which works fine and can get all the expect value display on every page:
Shared ht As System.Collections.Hashtable = New System.Collections.Hashtable
Public Function SetGroupHeader( ByVal group As Object _
,ByRef groupName As String _
,ByRef userID As String) As String
Dim key As String = groupName & userID
If Not group Is Nothing Then
Dim g As String = CType(group, String)
If Not (ht.ContainsKey(key)) Then
' must be the first pass so set the current group to group
ht.Add(key, g)
Else
If Not (ht(key).Equals(g)) Then
ht(key) = g
End If
End If
End If
Return ht(key)
End Function
Using this exprssion in the textbox of the reportheader:
=Code.SetGroupHeader(ReportItems!Language.Value,"GroupName", User!UserID)
Links belowe about the hashtable and the mutiple threads safe problem for your reference:
http://stackoverflow.com/questions/2067537/ssrs-code-shared-variables-and-simultaneous-report-execution
http://sqlserverbiblog.wordpress.com/2011/10/10/using-custom-code-functions-in-reporting-services-reports/
If you still have any problem, please feel free to ask.
Regards
Vicky Liu -
Is there a solution for dynamic reports and using Denes' Export to Excel?
Oracle 10.2.0.4.0
Application Express 3.2.1.00.10
Hello all!
I am using Denes Kubicek's Export_Excel_Pkg in my application and I'm having trouble exporting reports based on report regions created using a PL/SQL function body returning SQL query. I realize this is not an Oracle supported package, but was hoping someone here could shed some light on it. When I open up the Excel file, I get an error such as: Report Values Error: ORA-06550: line 22, column 5: PL/SQL: ORA-00907: missing right parenthesis.
I've searched the forum and already have done as others suggested by modifying the REPLACE on the v_sql variable in Export_Excel_Pkg.Get_Usable_SQL, but it did not work. My assumption is that there is an issue with the value being passed to the wwv_flow_utilities.get_binds function. I could not find documentation on this function, but I'm thinking that it cannot extract the bind variables within a PL/SQL block. The report only works when I have just use SQL with bind variables...doesn't work for PL/SQL. Nor does it work for dynamic SQL reports that use a "lexical" parameter (e.g. using WHERE &p_and_condition.) to build the WHERE clause.
Has anyone come up with a work-around to this? I somehow need to be able to extract reports based on dynamic SQL (or PL/SQL) to Excel.
Help is appreciated!
This is my example of a report based on PL/SQL function:
DECLARE
v_sql VARCHAR2(4000);
BEGIN
v_sql := q'[SELECT UPPER(t1.olo_name) agency_title,
t1.class_code,
UPPER(t1.class_title) class_title,
t1.pay_plan,
t1.pay_grade_code,
COUNT(t1.appt_fte) total_employees,
SUM(t1.appt_fte) filled_fte,
AVG(DECODE(t2.pay_cycle_code,
'UB',((t1.wage_type1_amt_for_pay * 26)/t1.appt_fte),
'UM',((t1.wage_type1_amt_for_pay * 12)/t1.appt_fte),
0)) avg_annual_rate
FROM my_schema.table1 t1,
my_schema.table2 t2,
my_schema.table3 pro
WHERE t1.pos_wk = t2.pos_wk
AND t2.pos_rate_active_flag = 'Y'
AND t1.ops_ind = 'N'
AND t1.employee_type IN ('1','2')
AND pro.ROLE_CODE = :F101_DW_ROLE
AND pro.pos_role_orgs_active_flag = 'Y']';
IF :P_MULTI_OLO IS NOT NULL THEN
v_sql := v_sql || q'[ AND INSTR(':'||']' || v('P_MULTI_OLO') || q'['||':', ':'||t1.olo_code||':') > 0]';
END IF;
v_sql := v_sql || q'[GROUP BY UPPER(t1.olo_name), t1.class_code, UPPER(t1.class_title), t1.pay_plan, t1.pay_grade_code ORDER BY t1.class_code ASC, avg_annual_rate]';
RETURN v_sql;
END;This is my example using a SQL statement with a lexical parameter:
SELECT UPPER(t1.olo_name) agency_title,
t1.class_code,
UPPER(t1.class_title) class_title,
t1.pay_plan,
t1.pay_grade_code,
COUNT(t1.appt_fte) total_employees,
SUM(t1.appt_fte) filled_fte,
AVG(DECODE(t2.pay_cycle_code,
'UB',((t1.wage_type1_amt_for_pay * 26)/t1.appt_fte),
'UM',((t1.wage_type1_amt_for_pay * 12)/t1.appt_fte),
0)) avg_annual_rate
FROM my_schema.table1 t1,
my_schema.table2 t2,
my_schema.table3 pro
WHERE t1.pos_wk = t2.pos_wk
AND t2.pos_rate_active_flag = 'Y'
AND t1.ops_ind = 'N'
AND t1.employee_type IN ('1','2')
AND pro.ROLE_CODE = :F101_DW_ROLE
AND pro.pos_role_orgs_active_flag = 'Y'
&P63_AND_CONDITION.
GROUP BY UPPER(t1.olo_name),
t1.class_code,
UPPER(t1.class_title),
t1.pay_plan,
t1.pay_grade_code
ORDER BY t1.class_code ASC, avg_annual_rateThe *&P63_AND_CONDITION.* value is populated based on a "Before Header" computation under Page Rendering, using the logic below. It is then used by the SQL query defined in the reports region at run time.
DECLARE
v_sql VARCHAR2(4000) := NULL;
BEGIN
v_sql := ' ';
IF :P_MULTI_OLO IS NOT NULL THEN
v_sql := v_sql || q'[ AND INSTR(':'||']' || v('P_MULTI_OLO') || q'['||':', ':' || t1.olo_code || ':') > 0]';
END IF;
RETURN v_sql;
END;Did you get an answer for this?
-
Teststand Customizin​g Report Header - XML
I wanted to simply add an image to the report header, and I use the ModifyReportHeader callback and the added the following expression. This shows the image correctly for HTMl report, but gives an error with the XML style with expand.xsl style sheet.
What did I do wrong?
Parameters.ReportHeader = "<img src='C:\\Logo.jpg'>" + Parameters.ReportHeader
Thanks,
Top CatTop Cat,
first of all, you are missing the closing tag '</img>'. This is optional for HTML, but required for XML. This will remove the error message.
But still, the image will not be displayed because the style sheet does not instruct the browser to do so. The best approach for you is to modify the style sheet (backup it first!) to display your image. If it is a static image, this is all you have to do.
hope this helps,
Norbert
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it. -
Report header is missng while printing or spooling
Hi All,
I have a problem in print a report.its
After getting selection screen of the report ,If i click a print button (it's for execute and print)
the header details are missing in spool ( does not print selection fields of the report are missing in spool).
If i execute the report and got the output ,then i click the print button it's execute properly means in spool i am getting all the output properly ,header details also printed. means selection screen fields means what i entered in selection screen is printing.Its a AVL report.While debugging i am not getting solution.i have investigated in menu painter also.
but i am not getting proper idea to fix the bug.
i am sending the code also.please let me know ASAP
code:
REPORT ZMXXR048 LINE-SIZE 1023 "255 deleted AW2150 GLDK9AAYU9
LINE-COUNT 65
MESSAGE-ID zm
NO STANDARD PAGE HEADING.
*eject
TABLES declaration.
TABLES:ekko, "Purchasing Document: Header
ekpo, "Purchasing Document: Item
a016, "Contract Item AMT25JAN05
a019, "Contract Header AMT25JAN05
t024, "Purchasing Groups
t024e, "Purchasing Organizations
t161, "Purchasing Document Types
t001w, "Plants/branches
lfa1, "Vendor Master (General Section) AMT25JAN05
eket, "Scheduling Agreement Schedule Lines
ekbe, "Purchasing Document: History AMT25JAN05
ekab, "Release Documentation AMT25JAN05
zbsart_doc."Purchasing documents custom structure "GA01
ekkn. "Account Assignment in Purchasing Document "GA19062003
Comment AMT25JAN05
*eject
TYPE-POOLS definition.
TYPE-POOLS slis. "KAK01
*eject
CONSTANTS declaration.
CONSTANTS:
c_t(1) TYPE c VALUE 'T', "AMT25JAN05
c_l(1) TYPE c VALUE 'L',
c_m(1) TYPE c VALUE '4', "AMT25JAN05
c_y(1) TYPE c VALUE 'Y', "AMT25JAN05
c_i(1) TYPE c VALUE 'I',
c_ne(2) TYPE c VALUE 'NE',
c_eq(2) TYPE c VALUE 'EQ', "AMT25JAN05
c_lp(2) TYPE c VALUE 'LP',
c_nb(2) TYPE c VALUE 'NB',
c_ec(2) TYPE c VALUE 'EC',
c_lpa(3) TYPE c VALUE 'LPA',
c_zlp(3) TYPE c VALUE 'ZLP',
c_znba(4) TYPE c VALUE 'ZNBA',
c_mk(2) TYPE c VALUE 'MK', "AMT25JAN05
c_wk(2) TYPE c VALUE 'WK', "AMT25JAN05
c_doqot(1) TYPE c VALUE '"', "AMT25JAN05
c_totals(6) TYPE c VALUE 'TOTALS',
c_x(1) TYPE c VALUE 'X',
c_k(1) TYPE c VALUE 'K', "AMT25JAN05
c_a(1) TYPE c VALUE 'A',
C_S(1) TYPE C VALUE 'S',"insert AW2150 GLDK9AAYU9
c_55(2) TYPE c VALUE '55',
c_56(2) TYPE c VALUE '56',
c_44(2) TYPE c VALUE '44', "AMT25JAN05
c_45(2) TYPE c VALUE '45',
c_1(1) TYPE c VALUE '1',
c_2(1) TYPE c VALUE '2',
c_h(1) TYPE c VALUE 'H',
c_(1) TYPE c VALUE '', "GA18062003.
c_n(1) TYPE c VALUE 'N', "SRI24062003
c_o(1) TYPE c VALUE 'O', "SRI24062003
c_maxdays TYPE p VALUE '93', "GA29072003
c_wk1(10) type c VALUE 'WK1'. "NAR10NOV06
*Begin of Addition by AMT25JAN05
CONSTANTS :
c_3 TYPE i VALUE 3 ,
c_4 TYPE i VALUE 4 ,
c_5 TYPE i VALUE 5 ,
c_8 TYPE i VALUE 8 ,
c_10 TYPE i VALUE 10 ,
c_11 TYPE i VALUE 11 ,
c_12 TYPE i VALUE 12 ,
c_15 TYPE i VALUE 15 ,
c_18 TYPE i VALUE 18 ,
c_20 TYPE i VALUE 20 ,
c_23 TYPE i VALUE 23 , "TUL02022005 "KVI04Feb05
c_40 TYPE i VALUE 40 ,
c_all(4) TYPE c VALUE '&ALL' ,
c_sa(3) TYPE c VALUE '&SA' ,
c_bs(3) TYPE c VALUE '&BS' ,
c_sum(4) TYPE c VALUE '&SUM' ,
c_eb3(4) TYPE c VALUE '&EB3' ,
c_xpa(4) TYPE c VALUE '&XPA' ,
c_omp(4) TYPE c VALUE '&OMP' ,
c_crb(4) TYPE c VALUE '&CRB' ,
c_cre(4) TYPE c VALUE '&CRE' ,
c_ave(4) TYPE c VALUE '&AVE' ,
c_pc10(4) TYPE c VALUE 'PC10' ,
c_coltab(6) TYPE c VALUE 'COLTAB' ,
c_excel(5) TYPE c VALUE 'EXCEL' ,
c_ic1(4) TYPE c VALUE '&IC1' ,
c_dload(5) TYPE c VALUE 'DLOAD' ,
c_refrs(5) TYPE c VALUE 'REFRS' ,
c_waers(5) TYPE c VALUE 'WAERS' ,
c_bprme(5) TYPE c VALUE 'BPRME' ,
c_ekbe(4) TYPE c VALUE 'EKBE' ,
c_meins2(6) TYPE c VALUE 'MEINS2' ,
c_meins3(6) TYPE c VALUE 'MEINS3' ,
c_ekkn(4) TYPE c VALUE 'EKKN' ,
c_ekpo(4) TYPE c VALUE 'EKPO' ,
c_ekko(4) TYPE c VALUE 'EKKO' ,
c_lfa1(4) TYPE c VALUE 'LFA1' ,
c_meins(5) TYPE c VALUE 'MEINS' ,
c_eket(4) TYPE c VALUE 'EKET' ,
c_me33l(5) TYPE c VALUE 'ME33L' ,
c_me23(4) TYPE c VALUE 'ME23' ,
c_bes(3) TYPE c VALUE 'BES' ,
c_bedat(11) TYPE c VALUE 'S_BEDAT-LOW',
c_pur(15) TYPE c VALUE 'PURCHASING DOC.',
c_item(4) TYPE c VALUE 'ITEM' ,
c_doc(8) TYPE c VALUE 'DOC.DATE' ,
c_vendor(6) TYPE c VALUE 'VENDOR' ,
c_vname(11) TYPE c VALUE 'VENDOR NAME' ,
c_plant(5) TYPE c VALUE 'PLANT' ,
c_pdesc(17) TYPE c VALUE 'PLANT DESCRIPTION',
c_sloc(4) TYPE c VALUE 'SLOC' ,
c_pgr(3) TYPE c VALUE 'PGR' ,
c_porg(4) TYPE c VALUE 'PORG' ,
c_mat(8) TYPE c VALUE 'MATERIAL' ,
c_standard(8) TYPE c VALUE 'STANDARD' ,
c_matdesc(20) TYPE c VALUE 'MATERIAL DESCRIPTION',
c_deldate(13) TYPE c VALUE 'DELIVERY DATE' ,
c_qty(13) TYPE c VALUE 'SCHEDULED QTY' ,
c_quom(4) TYPE c VALUE 'OUOM' ,
c_net(9) TYPE c VALUE 'NET PRICE' ,
c_curr(4) TYPE c VALUE 'CURR' ,
c_per(3) TYPE c VALUE 'PER' ,
c_opuom(5) TYPE c VALUE 'OPUOM' ,
c_grqty(6) TYPE c VALUE 'GR QTY' ,
c_gruom(6) TYPE c VALUE 'GR UOM' ,
c_irqty(6) TYPE c VALUE 'IR QTY' ,
c_iruom(6) TYPE c VALUE 'IR UOM' ,
c_trnum(15) TYPE c VALUE 'TRACKING NUMBER' ,
c_rec(12) TYPE c VALUE 'RECEIVER-BBP' ,
c_tcont(18) TYPE c VALUE 'T_CONDITIONS-EBELN' .
*End of Addition by AMT25JAN05
*BEGIN INSERT BB1097 - add a constant for the vendor mat field
CONSTANTS C_VENDMAT(15) TYPE C VALUE 'VENDOR MATERIAL'.
*END INSERT BB1097
*eject
DATA Work fields definition.
DATA : w_repid LIKE sy-repid,
w_color TYPE i,
w_info LIKE sy-lisel, "AMT25JAN05
w_lifnr LIKE eina-lifnr, "AMT25JAN05
w_matnr LIKE eina-matnr, "AMT25JAN05
w_werks LIKE marc-werks, "AMT25JAN05
w_tabkey LIKE cdpos-tabkey, "AMT25JAN05
w_objectid LIKE konp-knumh, "AMT25JAN05
w_len TYPE i , "AMT25JAN05
w_field LIKE konp-kopos, "AMT25JAN05
w_eindt LIKE eket-eindt, "AMT25JAN05
w_ebeln LIKE ekko-ebeln, "ujo1jul
zsort(6) TYPE c, "KAK01
w_fldname(20) TYPE c, "GA16062003.
w_titel LIKE spop-titel, "GA25062003.
w_text1 LIKE spop-textline1, "GA25062003.
w_text2 LIKE spop-textline2, "GA25062003.
W_FLAG(1) TYPE C, "KVI04Feb05
Start of GLDK9A8WWS (AS3848)
Defined variable for line size.
w_linsz LIKE sy-linsz.
End of GLDK9A8WWS (AS3848)
DATA: date_diff LIKE ekko-aedat.
*BEGIN OF SRI26062003
*DATA: w_s1 LIKE ekbe-menge, AMT25JAN05
w_s2 LIKE ekbe-bamng, AMT25JAN05
w_s3 LIKE ekbe-bpmng, AMT25JAN05
w_s4 LIKE ekpo-netpr. AMT25JAN05
w_s5 LIKE ekkn-wempf. AMT25JAN05
w_s6 LIKE ekpo-webaz, AMT25JAN05
*END OF SRI26062003
*eject
DATA Structure definition.
DATA: e_coltab TYPE slis_specialcol_alv.
*eject
DATA Internal table definition with INCLUDE STRUCTURE
*Begin of comment by AMT25JAN05
*DATA: BEGIN OF ibdcdata OCCURS 0.
INCLUDE STRUCTURE bdcdata.
*DATA: END OF ibdcdata.
*End of comment by AMT25JAN05
*eject
DATA Other internal table definition.
DATA: BEGIN OF t_documents OCCURS 0, "Main initial internal table
ekgrp LIKE ekko-ekgrp,
ekorg LIKE ekko-ekorg,
eknam LIKE t024-eknam,
ebeln LIKE ekko-ebeln,
ebelp LIKE ekpo-ebelp,
lgort LIKE ekpo-lgort,
kschl LIKE a016-kschl,
datbi LIKE a016-datbi,
datab LIKE a016-datab,
LOEKZ LIKE EKPO-LOEKZ, "insert AW2150 GLDK9AAYU9
infnr LIKE ekpo-infnr,
pstyp LIKE ekpo-pstyp,
konnr LIKE ekpo-konnr,
ematn LIKE ekpo-ematn,
txz01 LIKE ekpo-txz01,
werks LIKE ekpo-werks,
aedat LIKE ekpo-aedat,
epstp LIKE rm06e-epstp,
lifnr LIKE ekko-lifnr,
waers LIKE ekko-waers, "SRI26062003
name1 LIKE lfa1-name1,
name2 LIKE t001w-name1,
ktmng LIKE ekpo-ktmng,
meins LIKE ekpo-meins,
meins2 LIKE ekpo-meins, "GA23062003
meins3 LIKE ekpo-meins, "GA23062003
bednr LIKE ekpo-bednr,
loevm_ko LIKE konp-loevm_ko,
bsart LIKE ekko-bsart,
eindt LIKE eket-eindt, "SBH01
netpr LIKE ekpo-netpr, "SBh01
peinh LIKE ekpo-peinh, "GA01
bprme LIKE ekpo-bprme, "GA01
menge LIKE ekpo-menge,
menge2 like ekbe-menge, "GA23062003.
bamng LIKE ekbe-bamng, "GA23062003.
bpmng LIKE ekbe-bpmng,
vgabe LIKE ekbe-vgabe, "GA01
webaz LIKE ekpo-webaz,
wempf LIKE ekkn-wempf, "GA19062003.
flgdel(1) TYPE c, "ujo9jul
Start of GLDK9A8WWS (AS3848)
Added fields WEPOS (GR indicator), REPOS (IR indicator) and WEBRE (GR-
based IV indicator).
wepos LIKE ekpo-wepos, "GR indicator
repos LIKE ekpo-repos, "IR indicator
webre LIKE ekpo-webre, "GR-based IV indicator
End of GLDK9A8WWS (AS3848)
ELIKZ LIKE ekpo-ELIKZ, "Delivery "TUL02022005
EREKZ LIKE EKPO-EREKZ, "Invoice AW2150 GLDK9AAYU9
*BEGIN INSERT BB1097 - add column for the vendor mat field. this field
will hold the value of the vendor material #
IDNLF LIKE EKPO-IDNLF,
*END INSERT BB1097
END OF t_documents.
Added begin ujo9jul
*DATA: t_documents_tmp LIKE t_documents OCCURS 0 WITH HEADER LINE.
*Comment by AMT25JAN05
*eject
DATA Other internal table definition.
*Begin of Comment by AMT25JAN05
*DATA: BEGIN OF t_ekko OCCURS 0,
ebeln LIKE ekko-ebeln,
bsart LIKE ekko-bsart,
loekz LIKE ekko-loekz,
aedat LIKE ekko-aedat,
lifnr LIKE ekko-lifnr,
ekorg LIKE ekko-ekorg,
ekgrp LIKE ekko-ekgrp,
waers LIKE ekko-waers,
name1 LIKE lfa1-name1,
END OF t_ekko.
*End of Comment by AMT25JAN05
Added end ujo9jul
*Begin of SRI26062003
DATA:BEGIN OF t_t024 OCCURS 0 ,
ekgrp LIKE t024-ekgrp,
eknam LIKE t024-eknam,
END OF t_t024.
DATA:BEGIN OF t_t001w OCCURS 0 ,
werks LIKE t001w-werks,
name1 LIKE t001w-name1,
END OF t_t001w.
*End of SRI26062003
DATA: BEGIN OF t_conditions OCCURS 0, "Main final internal table
ebeln LIKE ekpo-ebeln,
ekgrp LIKE ekko-ekgrp,
ekorg LIKE ekko-ekorg,
waers LIKE ekko-waers, "SRI26062003
eknam LIKE t024-eknam,
ebelp LIKE ekpo-ebelp,
lgort LIKE ekpo-lgort,
kschl LIKE a016-kschl,
datbi LIKE a016-datbi,
datab LIKE a016-datab,
infnr LIKE ekpo-infnr,
pstyp LIKE ekpo-pstyp,
konnr LIKE ekpo-konnr,
ematn LIKE ekpo-ematn,
txz01 LIKE ekpo-txz01,
werks LIKE ekpo-werks,
aedat LIKE ekpo-aedat,
epstp LIKE rm06e-epstp,
lifnr LIKE ekko-lifnr,
name1 LIKE lfa1-name1,
name2 LIKE t001w-name1,
ktmng LIKE ekpo-ktmng,
meins LIKE ekpo-meins,
meins2 LIKE ekpo-meins, "GA23062003.
meins3 LIKE ekpo-meins, "GA23062003.
bednr LIKE ekpo-bednr,
loevm_ko LIKE konp-loevm_ko,
bsart LIKE ekko-bsart,
eindt LIKE eket-eindt,
netpr LIKE ekpo-netpr,
peinh LIKE ekpo-peinh,
bprme LIKE ekpo-bprme,
menge LIKE ekpo-menge,
menge2 like ekbe-menge, "GA23062003.
bamng LIKE ekbe-bamng, "GA23062003.
bpmng LIKE ekbe-bpmng,
vgabe LIKE ekbe-vgabe, "GA01
webaz LIKE ekpo-webaz,
wempf LIKE ekkn-wempf, "GA19062003.
AGING TYPE I, "insert AW2150 GLDK9AAYU9
ELIKZ LIKE ekpo-ELIKZ, "TUL02022005
EREKZ LIKE EKPO-EREKZ, "insert AW2150 GLDK9AAYU9
coltab TYPE slis_t_specialcol_alv, "SRI24062003
*BEGIN INSERT BB1097 - add column for the vendor mat field. this field
will hold the value of the vendor material #
IDNLF LIKE EKPO-IDNLF,
*END INSERT BB1097
END OF t_conditions.
Internal Table for the Purchasing Group name
*Begin of Comment by AMT25JAN05
*DATA: BEGIN OF t_purchgr OCCURS 0,
name2 LIKE t024-eknam,
END OF t_purchgr.
*End of Comment by AMT25JAN05
internal table for the plant name
*Begin of Comment by AMT25JAN05
*DATA: BEGIN OF t_plant OCCURS 0,
name1 LIKE t001w-name1,
END OF t_plant.
*End of Comment by AMT25JAN05
*Begin of Comment by AW2150
Internal Table for the Vendor Number and Vendor Name
*DATA: BEGIN OF t_lfa1 OCCURS 0,
lifnr LIKE lfa1-lifnr,
name1 LIKE lfa1-name1,
END OF t_lfa1.
*End of Comment by AW2150
*Start of GA19062003
Internal table for the Good Recipient in case of BBP
DATA: BEGIN OF t_ekkn OCCURS 0,
ebeln LIKE ekkn-ebeln, "SRI26062003
ebelp LIKE ekkn-ebelp, "SRI26062003
wempf LIKE ekkn-wempf,
END OF t_ekkn.
*End of GA19062003
Internal Table for EXCEL DOWNLOADING
DATA: BEGIN OF t_conditions_exe OCCURS 0,
ebeln(15) TYPE c,
ebelp(11) TYPE c,
aedat(11) TYPE c,
lifnr(16) TYPE c,
name1(35) TYPE c,
werks(5) TYPE c,
name2(30) TYPE c, "GA16062003.
lgort(4) TYPE c,
ekgrp(3) TYPE c,
ekorg(4) TYPE c,
" eknam(30) type c, "GA16062003.
ematn(20) TYPE c,
txz01(40) TYPE c,
*BEGIN INSERT BB1097 - this field will hold the value of the vendor
material #
IDNLF(35) TYPE C,
*END INSERT BB1097
eindt(13) TYPE c,
menge(13) TYPE c,
meins(4) TYPE c,
netpr(11) TYPE c,
waers(5) TYPE c, "ujo7jul
peinh(4) TYPE c,
bprme(4) TYPE c,
menge2(11) type c,
bamng(11) TYPE c,
meins2(6) TYPE c,
bpmng(11) TYPE c,
meins3(6) TYPE c,
bednr(21) TYPE c,
wempf(12) TYPE c, "GA19062003.
AGING(7) TYPE C, "insert AW2150 GLDK9AAYU9
ELIKZ(23) TYPE c, "TUL02022005
EREKZ(23) TYPE C, "insert AW2150 GLDK9AAYU9
END OF t_conditions_exe.
*eject
*INTERNAL TABLE TO FIND THE RECEIVED AND INVOICED QUANTITY
DATA: BEGIN OF t_ekbe OCCURS 0,
ebelp LIKE ekbe-ebelp,
ebeln LIKE ekbe-ebeln,
vgabe LIKE ekbe-vgabe,
BELNR LIKE EKBE-BELNR,
*Begin Of Change BH9511 20-Aug-07
menge LIKE ekbe-menge,
menge(16) TYPE P DECIMALS 3,
*End Of Change BH9511 20-Aug-07
shkzg LIKE ekbe-shkzg,
END OF t_ekbe.
*INTERNAL TABLE TO FIND THE RECEIVED AND INVOICED UoM
DATA: BEGIN OF t_ekbe_temp OCCURS 0,
ebelp LIKE ekbe-ebelp,
ebeln LIKE ekbe-ebeln,
vgabe LIKE ekbe-vgabe,
menge LIKE ekbe-menge,
END OF t_ekbe_temp.
Added begin ujo7jul
DATA: BEGIN OF t_totals OCCURS 0,
menge LIKE ekpo-menge,
meins LIKE ekpo-meins,
bamng LIKE ekbe-bamng,
meins2 LIKE ekpo-meins,
bpmng LIKE ekbe-bpmng,
meins3 LIKE ekpo-meins,
END OF t_totals.
DATA: BEGIN OF t_tot_netpr OCCURS 0,
netpr LIKE ekpo-netpr,
waers LIKE ekko-waers,
END OF t_tot_netpr.
DATA: BEGIN OF t_tot_peinh OCCURS 0,
peinh LIKE ekpo-peinh,
bprme LIKE ekpo-bprme,
END OF t_tot_peinh.
*Begin of Comment by AW2150
*DATA: BEGIN OF t_eket OCCURS 0,
ebeln LIKE eket-ebeln,
ebelp LIKE eket-ebelp,
eindt LIKE eket-eindt,
END OF t_eket.
Added end ujo7jul
*End of Comment by AW2150
BEGIN OF KAK01
FOR ALV Related Details.
DATA: alv_fieldcat TYPE slis_t_fieldcat_alv,
alv_layout TYPE slis_layout_alv,
alv_exclude TYPE slis_t_extab,
alv_sort TYPE slis_t_sortinfo_alv,
g_variant LIKE disvariant,
gx_variant LIKE disvariant,
gt_event_exit TYPE slis_t_event_exit, "GA23062003.
g_save(1) TYPE c, "GA23062003.
g_exit(1) TYPE c, "AMT25JAN05
lt_dynpread LIKE dynpread OCCURS 1 WITH HEADER LINE,"AMT25JAN05
g_repid LIKE d020s-prog,
END OF KAK01
Start of GLDK9A8WWS (AS3848)
Added the definition of structure for the events that will be used
in the logic for generating the standard report header for the report.
v_events TYPE slis_t_event.
End of GLDK9A8WWS (AS3848)
*eject
PARAMETERS and SELECT-OPTIONS definition
Start of GLDK9A8WWS (AS3848)
Changed the text-100 in the list of text elements. It was changed
from OPEN PURCHASE DOCUMENTS LIST DISPLAY to Open Purchaser Order
Report.
SELECTION-SCREEN: BEGIN OF BLOCK three WITH FRAME TITLE text-100.
End of GLDK9A8WWS (AS3848)
SELECTION-SCREEN: BEGIN OF BLOCK one WITH FRAME TITLE text-060.
SELECT-OPTIONS : s_ekorg FOR ekko-ekorg OBLIGATORY MEMORY ID eko
NO INTERVALS,
s_lifnr FOR ekko-lifnr,
s_werks FOR ekpo-werks MEMORY ID wrk,
s_ekgrp FOR ekko-ekgrp MEMORY ID ekg
NO INTERVALS,
s_ebeln FOR ekko-ebeln MEMORY ID bes,
s_ebelp FOR ekpo-ebelp MEMORY ID bsp,
s_bsart FOR zbsart_doc-bsart MEMORY ID bsa,"GA01
s_pstyp FOR ekpo-pstyp,
s_loekz FOR ekko-loekz,
s_knttp FOR ekpo-knttp MEMORY ID knt,
s_matnr FOR ekpo-matnr MEMORY ID mat,
s_matkl FOR ekpo-matkl MEMORY ID mkl,
start of modifications AW2150 GLDK9AAYU9
s_bedat FOR ekko-bedat OBLIGATORY, "GA29072003
S_BEDAT FOR EKKO-BEDAT,
end of modifications AW2150 GLDK9AAYU9
S_EINDT FOR EKET-EINDT.
PARAMETERS: p_sum AS CHECKBOX, "SRI26062003
start of modification AW2150 GLDK9ABI53
deleted checkbox for manually closed PO
p_pod AS CHECKBOX DEFAULT 'X'."insert AW2150 GLDK9AAYU9
added checkbox for DCI and FI.
P_DCI AS CHECKBOX DEFAULT 'X', "insert AW2150 GLDK9ABI53
P_FI AS CHECKBOX. "insert AW2150 GLDK9ABI53
end of modification AW2150 GLDK9ABI53
SELECTION-SCREEN: END OF BLOCK one .
SELECTION-SCREEN: BEGIN OF BLOCK two WITH FRAME TITLE text-070.
start of insert AW2150 GLDK9ABSZ8
PARAMETERS: P_ALLPO AS CHECKBOX DEFAULT 'X'.
end of insert AW2150 GLDK9ABSZ8
start of insert AW2150 GLDK9AAYU9
this was just moved from the block below. this is not a new
requirement.
PARAMETERS: P_VARI LIKE DISVARIANT-VARIANT NO-DISPLAY. " ALV Variant
SELECTION-SCREEN COMMENT 47(40) VARNAME FOR FIELD P_VARI.
end of insert AW2150 GLDK9AAYU9
*Start of GA16062003
PARAMETERS: p_qty RADIOBUTTON GROUP qtvl,
p_date RADIOBUTTON GROUP qtvl,
p_date1 RADIOBUTTON GROUP qtvl.
*End of GA16062003
SELECTION-SCREEN: END OF BLOCK two .
start of modification AW2150 GLDK9AAYU9
Start of GLDK9A8WWS (AS3848)
Commented out the following portion of the source code to remove the
field VARIANT under Settings on the report selection screen.
*SELECTION-SCREEN: BEGIN OF BLOCK four WITH FRAME
TITLE text-073. "TUL0202200
*selection-screen: begin of block four with frame title text-1
*Start of GA23062003
*PARAMETERS: p_vari LIKE disvariant-variant NO-DISPLAY. " ALV Variant
*SELECTION-SCREEN COMMENT 47(40) varname FOR FIELD p_vari.
*Select-Options : S_ELIKZ FOR ekpo-ELIKZ . "TUL0202200
End of modification AW2150 GLDK9AAYU9
Ext. check warning ignored for the comment. AMT25JAN05
*SELECTION-SCREEN: END OF BLOCK four.
End of GLDK9A8WWT (AS3848)
*selection-screen: end of block three.
PARAMETERS p_loggrp(4) TYPE c NO-DISPLAY DEFAULT 'PC10'.
SELECTION-SCREEN: END OF BLOCK three.
*End of GA23062003
*eject
*eject
INITIALIZATION
INITIALIZATION.
*Deletion Indicator
s_loekz-low = c_l.
s_loekz-sign = c_i.
s_loekz-option = c_ne.
APPEND s_loekz.
*start of insert AW2150 GLDK9ABSZ8
IF P_ALLPO EQ C_X.
LOOP AT SCREEN.
IF SCREEN-NAME EQ 'P_QTY'.
SCREEN-ACTIVE = 0.
ELSEIF SCREEN-NAME EQ 'P_DATE'.
SCREEN-ACTIVE = 0.
ELSEIF SCREEN-NAME EQ 'P_DATE1'.
SCREEN-ACTIVE = 0.
ENDIF.
MODIFY SCREEN.
ENDLOOP.
ELSEIF P_ALLPO NE C_X.
LOOP AT SCREEN.
IF SCREEN-NAME EQ 'P_QTY'.
SCREEN-ACTIVE = 1.
ELSEIF SCREEN-NAME EQ 'P_DATE'.
SCREEN-ACTIVE = 1.
ELSEIF SCREEN-NAME EQ 'P_DATE1'.
SCREEN-ACTIVE = 1.
ENDIF.
MODIFY SCREEN.
ENDLOOP.
ENDIF.
*end of insert AW2150 GLDK9ABSZ8
*Start of GA23062003
Settings for display variants
*INITIALIZATION. "GA03122003.
g_repid = sy-repid.
g_save = c_a(1).
CLEAR g_variant.
g_variant-report = g_repid.
g_variant-log_group = p_loggrp.
g_variant-username = sy-uname.
Get default variant
gx_variant = g_variant.
CALL FUNCTION 'REUSE_ALV_VARIANT_DEFAULT_GET'
EXPORTING
i_save = g_save
CHANGING
cs_variant = gx_variant
EXCEPTIONS
not_found = 2.
IF sy-subrc EQ 0.
p_vari = gx_variant-variant.
ENDIF.
varname = gx_variant-text.
VALIDATE INITIAL DATA ENTERED BY THE USERS ***************
*Start of GA29072003.
IF NOT s_bedat IS INITIAL.
Start of GLDK9A8WWS (AS3848)
Changed sequence in subroutine name to comply with coding standards
based on the review tool ZZCHK.
PERFORM f0100_check_s_bedat.
End of GLDK9A8WWS (AS3848)
ENDIF.
*End of GA29072003.
*eject
*start of insert AW2150 GLDK9ABSZ8
AT SELECTION-SCREEN OUTPUT.
IF P_ALLPO EQ C_X.
LOOP AT SCREEN.
IF SCREEN-NAME EQ 'P_QTY'.
SCREEN-ACTIVE = 0.
ELSEIF SCREEN-NAME EQ 'P_DATE'.
SCREEN-ACTIVE = 0.
ELSEIF SCREEN-NAME EQ 'P_DATE1'.
SCREEN-ACTIVE = 0.
ENDIF.
MODIFY SCREEN.
ENDLOOP.
ELSEIF P_ALLPO NE C_X.
LOOP AT SCREEN.
IF SCREEN-NAME EQ 'P_QTY'.
SCREEN-ACTIVE = 1.
ELSEIF SCREEN-NAME EQ 'P_DATE'.
SCREEN-ACTIVE = 1.
ELSEIF SCREEN-NAME EQ 'P_DATE1'.
SCREEN-ACTIVE = 1.
ENDIF.
MODIFY SCREEN.
ENDLOOP.
ENDIF.
*end of insert AW2150 GLDK9ABSZ8
*eject
*start of insert by AW2150 GLDK9AAYU9
AT SELECTION SCREEN ON S_EINDT.
AT SELECTION-SCREEN ON S_EINDT.
IF NOT S_EINDT IS INITIAL.
PERFORM F17200_CHECK_S_EINDT.
ENDIF.
*end of insert by AW2150 GLDK9AAYU9
*eject
AT SELECTION SCREEN ON S_EKORG
AT SELECTION-SCREEN ON s_ekorg.
Validate value of purchasing org(s) entered on the selection *
screen by executing subroutine 0100_VALIDATE_PURC_ORG. *
IF NOT s_ekorg IS INITIAL.
PERFORM f0200_validate_purc_org.
ENDIF.
*eject
AT SELECTION SCREEN ON S_EKGRP
AT SELECTION-SCREEN ON s_ekgrp.
Validate value of purchasing group(s) entered on the selection *
screen by executing subroutine 0200_VALIDATE_PURC_GROUP. *
IF NOT s_ekgrp IS INITIAL.
PERFORM f0300_validate_purc_group.
ENDIF.
*eject
AT SELECTION SCREEN ON S_EBELN
AT SELECTION-SCREEN ON s_ebeln.
Validate value of purchase order(s) entered on the selection *
screen by executing subroutine F0310_VALIDATE_PURC_ORDER.
IF NOT s_ebeln IS INITIAL.
PERFORM f0310_validate_purc_order.
ENDIF.
*eject
AT SELECTION SCREEN ON S_WERKS
AT SELECTION-SCREEN ON s_werks.
Validate value of plant(s) entered on the selection *
screen by executing subroutine F0400_VALIDATE_PLANT.
IF NOT s_werks IS INITIAL.
PERFORM f0400_validate_plant.
ENDIF.
*eject
AT SELECTION SCREEN ON S_BSART
AT SELECTION-SCREEN ON s_bsart.
Validate value of Document type(s) entered on the selection *
screen by executing subroutine F0500_VALIDATE_DOC_TYPE.
IF NOT s_bsart IS INITIAL.
PERFORM f0500_validate_doc_type.
ENDIF.
*eject
AT SELECTION SCREEN ON S_PSTYP
AT SELECTION-SCREEN ON s_pstyp.
Validate value of Item Category entered on the selection *
screen by executing subroutine F0600_VALIDATE_ITEM_CATEGORY.
IF NOT s_pstyp IS INITIAL.
PERFORM f0600_validate_item_category.
ENDIF.
*eject
AT SELECTION SCREEN ON S_MATNR
AT SELECTION-SCREEN ON s_matnr.
Validate value of Material Number entered on the selection *
screen by executing subroutine F0700_validate_mat_number
IF NOT s_matnr IS INITIAL.
PERFORM f0700_validate_mat_number.
ENDIF.
*eject
AT SELECTION SCREEN ON S_LIFNR
AT SELECTION-SCREEN ON s_lifnr.
Validate value of Vendor entered on the selection by executing *
subroutine F0800_VALIDATE_VENDOR_NUMBER
IF NOT s_lifnr IS INITIAL.
PERFORM f0800_validate_vendor_number.
ENDIF.
*eject
AT SELECTION SCREEN ON S_MATKL
AT SELECTION-SCREEN ON s_matkl.
Validate value of material group entered on the selection screen *
by executing subroutine F0900_validate_mat_group.
IF NOT s_matkl IS INITIAL.
PERFORM f0900_validate_mat_group.
ENDIF.
*eject
AT SELECTION SCREEN ON S_KNTTP
AT SELECTION-SCREEN ON s_knttp.
Validate the value of account assignment category entered on the *
selection screen by executing subroutine 1000_validate_mat_group. *
IF NOT s_knttp IS INITIAL.
PERFORM f1000_validate_***_category.
ENDIF.
*eject
AT SELECTION SCREEN ON S_EBELP
AT SELECTION-SCREEN ON s_ebelp.
Validate the value of PO line item entered on the *
selection screen by executing subroutine F1100_VALIDATE_PO_ITEM.
IF NOT s_ebelp IS INITIAL.
PERFORM f1100_validate_po_item.
ENDIF.
*eject
AT SELECTION SCREEN ON S_LOEKZ
AT SELECTION-SCREEN ON s_loekz.
Validate the value of deletion indicator enterd on the selection *
selection screen by executing subroutine F1200_VALIDATE_DEL_IND.
IF NOT s_loekz IS INITIAL.
PERFORM f1200_validate_del_ind.
ENDIF.
Start of GLDK9A8WWS (AS3848)
Commented out the following block of code as a result of the removal
of the field VARIANT from the selection screen.
*at selection-screen on value-request for p_vari.
perform 14000_f4_for_variant.
End of GLDK9A8WWS (AS3848)
*Start of deletion AW2150
*eject
Block Added From Here TUL02022005
AT SELECTION SCREEN ON S_ELIKZ
*AT SELECTION-SCREEN ON s_ELIKZ.
Validate the value of Delivery Completed Indicator entered.
IF NOT s_ELIKZ IS INITIAL.
Check the Valid Values.
IF not SPACE in S_ELIKZ
AND not C_X in S_ELIKZ .
MESSAGE e999 WITH
'Invalid Delivery Completed Flag entered'(006).
ENDIF.
ENDIF.
Block Added Till Here TUL02022005
*End of deletion AW2150
*eject
AT SELECTION SCREEN
AT SELECTION-SCREEN.
PERFORM f15000_pai_of_selection_screen.
*End of GA23062003
start of insert AW2150 GLDK9AAYU9
IF S_BEDAT IS INITIAL
AND S_EINDT IS INITIAL.
MESSAGE E999 WITH TEXT-E01.
ENDIF.
end of insert AW2150 GLDK9AAYU9
MAIN PROCESSING **
*eject
START-OF-SELECTION.
START-OF-SELECTION.
Store report name and report size into temp. varaibles for later use.
w_repid = sy-repid.
Select OAs and Info Records to be displayed into internal table
PERFORM f2000_get_pos.
Store data into final reporting internal table
PERFORM f3000_store_data.
Begin of KAK01
Start of GLDK9A8WWS (AS3848)
Calls the subroutine for building the event catalog for ALV. This
event catalog will be used in the function module that will generate
the ALV report. Logic will eventually be used for the generation of
the standard report header on top of each page.
CLEAR v_events.
w_linsz = sy-linsz.
PERFORM f17100_build_events USING v_events.
End of GLDK9A8WWS (AS3848)
Use ALV instead of normal list.
Write data to the screen.
Populate ALV Field Category Structure.
PERFORM f8000_field_cat.
Populate ALV Exclude Structure.
PERFORM f9000_alv_exclude.
*eject
END-OF-SELECTION.
END-OF-SELECTION.
Begin of KVI04Feb05
IF W_FLAG EQ C_X.
CLEAR W_FLAG.
STOP.
ENDIF.
End of "KVI04Feb05
Display Report.
PERFORM f10000_call_disp.
*eject
AT USER-COMMAND .
*AT USER-COMMAND.
CASE SY-UCOMM.
WHEN 'EXEL'.
PERFORM F5000_DOWNLOAD_TO_EXCEL.
WHEN 'CLIK'.
IF SY-LISEL+1(2) EQ '45'.
PERFORM F6000_see_po_details.
ELSE.
PERFORM F7000_see_oa_details.
ENDIF.
ENDCASE.
End of KAK01
*eject
Form(s)/Subroutine(s) ************************
*Start of GA29072003.
*& FORM F0100_CHECK_S_BEDAT
Check if user entered appropriate date values as selection criteria *
----Hi!
After you click on the printer icon, a popup will apeear. Depends on the SAP system version, you are using, somewhere on the popup, you can find a filed, which is called SAP COVER PAGE.
Here you can choose, coverpage, without cover page, or standard cover page.
Regards
Tamá
Maybe you are looking for
-
Problem adding some user or active directory group to sharepoint 2010 group
Hi All I have a problem in a specific site collection in a web Application (but not on other site collection in that webApp). whenever I add a user like some system account to a sharepoint group or create a new sharepoint group or add an ActiveDirect
-
Hi all, I'm trying to display report ( SQL Query report ) the query is as follows:- SELECT E.C001, E.C002, AE.C001, AE.C002 FROM APEX_COLLECTIONS COLLECTION_NAME = 'EXAMPLE' A INNER JOIN APEX_COLLECTIONS COLLECTION_NAME = 'ANOTHER_EXAMPLE' AE ON E.SE
-
Restoring after hard drive crash
Hi- I had a hard drive crash. I had everything backed up on Carbonite. So I've reinstalled Lightroom 4.2 and am a little confused on how to restore everything back to Lightroom with all my metadata and changes etc I am using Windows 7 and have alrea
-
A bunch of cable installers run Firefox now. This isn't as much about bartab as about Firefox. At one time Firefox wanted to be a great browser, it seems those days are gone. Did you not realize people are going to revert to previous versions to be a
-
If I restore my ipod, will it prompt me to backup my existing data? When I begin the restore process, it tells me that all data will be erased. I'm trying to download my library to a different ipod.