Problem saving a report when using rpad in query for fixed-width
Hi There,
I'm using 9.0.4 and trying to make and save a report that will eventually produce a fixed-width text output (as opposed to delimited).
I keep getting: REP-1051 Unable to save document to file mypath/filename
REP-1070 Error while opening or saving a document - Non-specific file error occurred.
My sql query is a large string that RPADs everything and concatenates into one very long string (about 600 characters). The report runs fine while I'm working on it, but I can't save it. I finally pared the query down to a small fraction of what I need, and it did save, but as soon as I started adding back to the query, it failed again.
Does anyone know how to work around this? I don't have any flexibility with my version of Reports, as the client will not update their version.
TIA, J
Hi Ronan,
You can use the parameter WRAPPING to adjust the height of the header lines. Please have a look at note 1292696 which explains how to.
Best regards,
Janine
Similar Messages
-
Problem saving data model when using Oracle DB Pivot feature
I have problem saving a data model - SQL Query that uses the Oracle DB PIVOT feature?
When I hit save, nothing happends.... have also tried "save as" - nothing is saved
No error message is shown.
Is Oracle DB PIVOT not supported by OBIEE?
The SQL that is causing the problem is this one:
SELECT * FROM
SELECT field_name as field,
CASE
WHEN col_1 = 'A' THEN 'Name 1'
WHEN col_1 like 'B_%' THEN 'Name 2'
END
as gastype,
energy
FROM table_1
WHERE code = 'K'
AND trunc(DAYTIME,'YYYY') = trunc(to_date('2012-01-01 00:00:00','YYYY-MM-DD HH24:MI:SS'), 'YYYY')
AND (col_1 in ('A') or col_1 like 'B_%')
PIVOT (sum(energy) for (gastype) in ('Name 1' as Name1, 'Name 2' as Name2))
order by field
We are using OBIEE 11.1.1.6.7 (Win 2008R2) against Oracle DB 11.2.0.3Just a wild guess .. Have you done dbsetup after installing IAS and said you are going to said databases ?
-
Can not print report when using HTML or DHTML
Can not print report when using HTML or DHTML. When I open the report and click the print icon I get a small blank dialog box and then nothing. If I change to activex it works and I can print.
Any Ideas?
Thanks
JeffHi,
I did not come across this situation before. Did you apply any fix packs. Try to check whether its a issue which can be fixed by applying fix pack( try to check release notes of fix pack and see if they mentioned any thing about this).
Thanks,
SK. -
Problems w/ race conditions when using attachmovie
Hello,
I'm having a strange problem w/ race conditions when using attachmovie.
I have a class linked to a movie clip that I'm attaching to the stage. The class is
fired off when the movie clip is attached but also other classes are getting loaded at the same time
while the movie clips is attached. Even though the other classes are called after the
movieclip is attached, they are getting loaded faster and therefor the class linked to the attached movie clip
cannot access their functions.
I'm looking for a listener that will fire off an event ONLY when the attached movieclip is fully loaded but I can't
seem to find any examples of associating a listener to a attachmovie method.
Any ideas?
Thanks,
Clem Cflash is single threaded so nothing happens simultaneously. what do you mean by, "other classes are getting loaded at the same timewhile the movie clips is attached"
-
Issue: When using BW Bex query analyzer users cannot change reporting queries. Any attempt to change queries results in errors.
Error: BEx Query Designer: Run-time error '-2147221499 (80040005) Fatal Error - Terminating
Impact: Business reporting is currently being negatively impacted because users cannot modify queries, cannot change filters for fiscal period and fiscal year.
OS / MS Office Suite being used: Vista & Office 2007
Backend System: BW 2.0B
Frontend System: Being a large organization, we have a controlled environment wherein all users will have the following applications installed by default:
1. SAP Client Base 7.10
2. SAP BW 3.5 Patch 4
3. SAP BI 7.10 Patch 900
4. SAP GUI 7.10 Patch 12
Does anyone has any idea as to why we are getting this error? Is it a Vista issue? Is it a front-end issue?Just a thought - did you guys apply any Microsoft security patches before this started happening - we had a similar issue in other SAP application due to MS security update. Raise an OSS with SAP
-
Wrong date format when using selection screen query
Hi all,
I have a problem in a report when usign the selection screen of the query.
the system has been upgraded recently from a 3.5 to 7.0. when a query is run in the bex web the user can put in the selection date needer to run the query.
currently if u select a month using the selection screen next to the input form, the month will show up in the input field
as 006 09 (006space09) instead of 06.2009 for the selection of june.
does anyone know how to fix this? it was working good using the 3.5 version of the bex web.
Any help apriciatedUsing the list cube transaction and using the selection sceen and selecting the month it does put the right selection in the input field. ive also just tested it using de bx excel plugin and using the selection screen the correct value is set in the input field. so i think it more of a bex we b problem but i dont know where to start the search for the solution.
-
When using Lightroom Book module for Blurb book making, why do I keep getting a low image quality message if it's supposedly accessing my large raw files in my library?
I think I've solved my problem with a Google Search. I came across a free slide show generator
(contributions requested) that shows much higher quality slide shows than either iPhoto or Aperture 3.
You click on a folder of jpegs and it almost immediately generates thumbnails and within a few seconds
I can be viewing a full screen, tack sharp, slideshow of all of the files in the folder. Much sharper than
I'm used to seeing.
I think I'll keep the Aperture 3 and use if for the purpose it's intended for in the future. I'll also redo the
image preview files to the small size it started with and then I'll copy all of the files I'm interested in from
iPhoto into a separate folder on another disk. I'll use Aperture to catalog and to perform image manipulations
on but I won't try to use it as an iPhoto replacement. I don't think I'll be using iPhoto much as an image
viewer in the future either after I finish moving my favorite pictures to the Phoenix Slides folder.
The name of the free program is Phoenix Slides. It's free to download and try, free to keep (though I
think you'd want to pay the small amount requested) and fast. My pictures have never looked so good
before.
http://blyt.net/phxslides/
Message was edited by: Jimbo2001 -
Flash crashing when using Command + Option + S for Scale and Rotate?
Flash crashing when using Command + Option + S for Scale and Rotate?
It's happening to me when I use those hotkeys
Please let me know if it's happening to you too.
I don't know the cause but I need a fix.
I'm using Adobe FLASH cs6 for Mac
My computer:
Mac mini
Mid 2011
Software OS X 10.8.1 (12B19)
-LineWith all due respect to your totally coindescending reply, this is a bug in Flash. Happens every 4-5 times I use that menu item. Been happening for months, but we just installed a Brand new iMac (1/13). Quadcore 3.4 16G RAM and 1TB Fusion drive. Fresh install of CS6. Not running any other 3rd Party Software. Problem STILL happens in new Flash docs with small, simple vector Graphics.
So instead of blaming the users computers, how about you guys just fix the effin' problem? Thanks. -
Hi, i have windows 7 hp, sp1. When using adobe flash player, for example, in the game. Screen will fade after a few seconds of inactivity. But the pixels on are highlighted. This is accomplished by installing the latest update flash.If I move the mouse the screen returns. Screen goes from one second to several, and sometimes not at all. Pleas help me
To give you any useful advice, I'm going to need to know more about your computer and browser:
https://forums.adobe.com/thread/1195540 -
Im trying to use AVG in query for my dataset in ssrs.
This is my query
SELECT name, id, AVG(complience) AS complience
FROM result
WHERE (date >=@startdate) AND (date<= @enddate)
Im later on doing a sprakline with the complience for each date.
Please help me :)
Systemdeveloper @ 4filmFor Sparkline in SSRS refer below link ;
http://www.mssqltips.com/sqlservertip/2757/ssrs-textbox-tips-and-tricks/
Thanks -
Problem modifying the connection details in a Report when using Weblogic 12
Hi
I have a j2ee application that uses the Java Reporting Component (JRC). At runtime, the code programmatically changes the connection type and schema name of a crystal report before running it. The connection that was used when designing the report is replaced with new JNDI parameters pointing to a Weblogic/Oracle datasource.
The application works perfectly when using Weblogic 11, but the same code and report fails when deployed to Weblogic 12.
I used Version 12.2.207.916 of the JRC, and updating to the most current version I could find (12.2.217) did not solve the problem.
The code snippet below shows how the connection and schema name is replaced for each of the tables in the report (not all the code is shown here)...
PropertyBag propertyBag = new PropertyBag();
propertyBag.put("Database DLL", "crdb_jdbc.dll");
propertyBag.put("JNDI Datasource Name", jndiName);
propertyBag.put("Initial Context", "");
while (tableList.hasNext()) {
ITable table = tableList.next();
ITable tableNew = (ITable) table.clone(true);
IConnectionInfo connectionInfo = table.getConnectionInfo();
connectionInfo.setAttributes(propertyBag);
connectionInfo.setKind(ConnectionInfoKind.SQL);
tableNew.setQualifiedName(newQualifier + "." + table.getName());
tableNew.setConnectionInfo(connectionInfo);
dbController.setTableLocation(table, tableNew);
The setTableLocation() function throws the following exception ...
2014-05-13 16:46:27,173 ERROR [[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'] JRCCommunicationAdapter detected an exception: Unexpected database connector error
at com.crystaldecisions.reports.queryengine.Table.u7(SourceFile:2409)
at com.crystaldecisions.reports.dataengine.datafoundation.AddDatabaseTableCommand.new(SourceFile:529)
at com.crystaldecisions.reports.common.CommandManager.a(SourceFile:71)
at com.crystaldecisions.reports.common.Document.a(SourceFile:203)
at com.businessobjects.reports.sdk.requesthandler.f.a(SourceFile:175)
at com.businessobjects.reports.sdk.requesthandler.DatabaseRequestHandler.byte(SourceFile:1079)
at com.businessobjects.reports.sdk.JRCCommunicationAdapter.do(SourceFile:1167)
at com.businessobjects.reports.sdk.JRCCommunicationAdapter.if(SourceFile:661)
at com.businessobjects.reports.sdk.JRCCommunicationAdapter.a(SourceFile:167)
at com.businessobjects.reports.sdk.JRCCommunicationAdapter$2.a(SourceFile:529)
at com.businessobjects.reports.sdk.JRCCommunicationAdapter$2.call(SourceFile:527)
at com.crystaldecisions.reports.common.ThreadGuard.syncExecute(SourceFile:102)
at com.businessobjects.reports.sdk.JRCCommunicationAdapter.for(SourceFile:525)
at com.businessobjects.reports.sdk.JRCCommunicationAdapter.int(SourceFile:424)
at com.businessobjects.reports.sdk.JRCCommunicationAdapter.request(SourceFile:352)
at com.businessobjects.sdk.erom.jrc.a.a(SourceFile:54)
at com.businessobjects.sdk.erom.jrc.a.execute(SourceFile:67)
at com.crystaldecisions.proxy.remoteagent.RemoteAgent$a.execute(SourceFile:716)
at com.crystaldecisions.proxy.remoteagent.CommunicationChannel.a(SourceFile:125)
at com.crystaldecisions.proxy.remoteagent.RemoteAgent.a(SourceFile:537)
at com.crystaldecisions.sdk.occa.report.application.ds.a(SourceFile:186)
at com.crystaldecisions.sdk.occa.report.application.an.a(SourceFile:108)
at com.crystaldecisions.sdk.occa.report.application.b0.if(SourceFile:148)
at com.crystaldecisions.sdk.occa.report.application.b0.b(SourceFile:95)
at com.crystaldecisions.sdk.occa.report.application.bb.int(SourceFile:96)
at com.crystaldecisions.proxy.remoteagent.UndoUnitBase.performDo(SourceFile:151)
at com.crystaldecisions.proxy.remoteagent.UndoUnitBase.a(SourceFile:106)
at com.crystaldecisions.sdk.occa.report.application.DatabaseController.a(SourceFile:2159)
at com.crystaldecisions.sdk.occa.report.application.DatabaseController.a(SourceFile:543)
at com.crystaldecisions.sdk.occa.report.application.DatabaseController.a(SourceFile:3898)
at com.crystaldecisions.sdk.occa.report.application.DatabaseController.setTableLocation(SourceFile:2906)
at com.systest.reporting.engine.crystal.CrystalReportEngine.replaceConnection(CrystalReportEngine.java:523)
at com.systest.reporting.engine.crystal.CrystalReportEngine.changeDataSource(CrystalReportEngine.java:449)
at com.systest.CrystalReportPane.setReportDataSourceDetails(CrystalReportPane.java:170)
at com.systest.CrystalReportPane.commandLoad(CrystalReportPane.java:136)
at com.systest.ReportRunner.CrystalReport.Load(CrystalReport.java:401)
at com.systest.ReportRunner.SaveReportToFile(ReportRunner.java:1385)
Any idea what I can do to fix this ?
Thanks in advance!Last reference in any documentation re. version of supported weblogic is 10.3.x. And it may very well be that things worked in weblogic 11, but as versions go by the differences get bigger and eventually the app stops working.
I'll ping the Program Manager for definitive info and future support. Once I have the info, I'll update this Discussion.
- Ludek
Senior Support Engineer AGS Product Support, Global Support Center Canada
Follow us on Twitter -
Empty report returned from WEBI and Crystal report when using external hier
Hi,
WEBI and Crystal report build from BEX query returned empty report when we used external hierarchy 0PROFIT_CTR. In BEX we don't have any problems with it.
No authority check is perfomed on the hierarchy when we start the report in WEBI/Crystal. Only check on the hierarchy is performed when the root authorization is assigned to the userWe using BO4 SP12
-
Cursors are not closed when using Ref Cursor Query in a report ORA-01000
Dear Experts
Oracel database 11g,
developer suite 10.1.2.0.2,
application server 10.1.2.0.2,
Windows xp platform
For a long time, I'm hitting ORA-01000
I have a 2 group report (master and detail) using Ref Cusor query, when this report is run, I found that it opens several cursors (should be only one cursor) for the detail query although it should not, I found that the number of these cursors is equal to the number of master records.
Moreover, after the report is finished, these cursors are not closed, and they are increasing cumulatively each time I run the report, and finally the maximum number of open cursors is exceeded, and thus I get ORA-01000.
I increased the open cursors parameter for the database to an unbeleivable value 30000, but of course it will be exceeded during the session because the cursors are increasing cumulatively.
I Found that this problem is solved when using only one master Ref Cursor Query and create a breake group, the problem is solved also if we use SQL Query instead of Ref Query for the master and detail queries, but for some considerations, I should not use neither breake group nor SQL Query, I have to use REF Cursor queries.
Is this an oracle bug , and how can I overcome ?
Thanks
Edited by: Mostafa Abolaynain on May 6, 2012 9:58 AMThank you Inol for your answer, However
Ref Cursor give me felxibility to control the query, for example see the following query :
function QR_1RefCurDS return DEF_CURSORS.JOURHEAD_REFCUR is
temp_JOURHEAD DEF_CURSORS.JOURHEAD_refcur;
v_from_date DATE;
v_to_date DATE;
V_SERIAL_TYPE number;
begin
SELECT SERIAL_TYPE INTO V_SERIAL_TYPE
FROM ACC_VOUCHER_TYPES
where voucher_type='J'
and IDENT_NO=:IDENT
AND COMP_NO=TO_NUMBER(:COMPANY_NO);
IF :no_date=1 then
IF V_SERIAL_TYPE =1 THEN
open temp_JOURHEAD for select VOCH_NO, VOCH_DATE
FROM JOURHEAD
WHERE COMP_NO=TO_NUMBER(:COMPANY_NO)
AND IDENT=:IDENT
AND ((TO_NUMBER(VOCH_NO)=:FROM_NO and :FROM_NO IS NOT NULL AND :TO_NO IS NULL)
OR (TO_NUMBER(VOCH_NO) BETWEEN :FROM_NO AND :TO_NO and :FROM_NO IS NOT NULL AND :TO_NO IS NOT NULL )
OR (TO_NUMBER(VOCH_NO)<=:TO_NO and :FROM_NO IS NULL AND :TO_NO IS NOT NULL )
OR (:FROM_NO IS NULL AND :TO_NO IS NULL ))
ORDER BY TO_NUMBER(VOCH_NO);
ELSE
open temp_JOURHEAD for select VOCH_NO, VOCH_DATE
FROM JOURHEAD
WHERE COMP_NO=TO_NUMBER(:COMPANY_NO)
AND IDENT=:IDENT
AND ((VOCH_NO=:FROM_NO and :FROM_NO IS NOT NULL AND :TO_NO IS NULL)
OR (VOCH_NO BETWEEN :FROM_NO AND :TO_NO and :FROM_NO IS NOT NULL AND :TO_NO IS NOT NULL )
OR (VOCH_NO<=:TO_NO and :FROM_NO IS NULL AND :TO_NO IS NOT NULL )
OR (:FROM_NO IS NULL AND :TO_NO IS NULL ))
ORDER BY VOCH_NO;
END IF;
ELSE
v_from_date:=to_DATE(:from_date);
v_to_date:=to_DATE(:to_date);
IF V_SERIAL_TYPE =1 THEN
open temp_JOURHEAD for select VOCH_NO, VOCH_DATE
FROM JOURHEAD
WHERE COMP_NO=TO_NUMBER(:COMPANY_NO)
AND IDENT=:IDENT
AND ((voch_date between v_from_date and v_to_date and :from_date is not null and :to_date is not null)
OR (voch_date <= v_to_date and :from_date is null and :to_date is not null)
OR (voch_date = v_from_date and :from_date is not null and :to_date is null)
OR (:from_date is null and :to_date is null ))
ORDER BY VOCH_DATE,TO_NUMBER(VOCH_NO);
ELSE
open temp_JOURHEAD for select VOCH_NO, VOCH_DATE
FROM JOURHEAD
WHERE COMP_NO=TO_NUMBER(:COMPANY_NO)
AND IDENT=:IDENT
AND ((voch_date between v_from_date and v_to_date and :from_date is not null and :to_date is not null)
OR (voch_date <= v_to_date and :from_date is null and :to_date is not null)
OR (voch_date = v_from_date and :from_date is not null and :to_date is null)
OR (:from_date is null and :to_date is null ))
ORDER BY VOCH_DATE,VOCH_NO;
END IF;
END IF;
return temp_JOURHEAD;
end; -
Hi
I have this ALV Report when I run and change the layout (add/remove column and add column for sorting) it works fine but when i come back i get the change columns but it doesn't save the sorting options that i made.
Here is my Code
*& Report ZAKTIME *
*& AKABIR 02/06/2007 New Report for Cluster B2 *
REPORT ZAKTIME no standard page heading message-id zw line-size 255.
* Dictionary tables/structures
tables: pa0007, PA0002.
DATA: IT_T549Q TYPE T549Q OCCURS 0 WITH HEADER LINE,
IT_ZL TYPE PC2BF OCCURS 0 WITH HEADER LINE,
IT_PT TYPE PDCPT OCCURS 0 WITH HEADER LINE,
IT_ALP TYPE PC20E OCCURS 0 WITH HEADER LINE,
IT_C1 TYPE PC25X OCCURS 0 WITH HEADER LINE,
IT_PSP TYPE PC2BA OCCURS 0 WITH HEADER LINE.
* Global ALV Data Declarations
type-pools slis.
DATA: BEGIN OF tgetbuff occurs 0,
x(10),
END OF tgetbuff.
include rpcxB200.
INCLUDE RPTBAL01.
* infotypes: 0001. "Org. Zuordnung
Data: TempHours LIKE PC2BF-BEGUZ,
even type i value 0.
data: begin of hd,
struc like dd03l-tabname,
end of hd.
DATA: BEGIN OF REC OCCURS 0,
PERNR LIKE PERNR-PERNR,
SSN Like pa0002-perid,
NAME(25),
TYPE(1),
WRKS LIKE PC2BA-TPROG,
DATE(10),
STIME(8),
ETIME(8),
HOURS LIKE PC2BF-BEGUZ,
PNUMB LIKE PC20E-PRAKN,
PID LIKE PC20E-PRAKZ,
UNIT LIKE PC20E-ANZHL,
VALU LIKE PC20E-BWGRL,
AMOUNT LIKE PC20E-BETRG,
XPAYID LIKE PC20E-AUFKZ,
CCNTR LIKE PC25X-KOSTL,
CCODE LIKE PC25X-BUKRS,
AUFNR LIKE PC25X-AUFNR,
KTEXT LIKE CAUFV-KTEXT,
LGART LIKE PC2BF-LGART,
LGTXT LIKE T512T-LGTXT,
STER LIKE PDCPT-BTERM,
ETER LIKE PDCPT-ETERM.
DATA: END OF REC.
data:
begin of x_sortinfo_alv occurs 0,
spos like alvdynp-sortpos,
fieldname type slis_fieldname,
tabname type slis_fieldname,
up like alvdynp-sortup,
down like alvdynp-sortdown,
group like alvdynp-grouplevel,
subtot like alvdynp-subtotals,
comp(1) type c,
expa(1) type c,
obligatory(1) type c,
end of x_sortinfo_alv,
v_variant like disvariant,
v_repid like sy-repid,
v_save(1) type c,
lv_sortseq type i,
s_title(20), "Maximum selection field description 20 bytes.
fieldcat type slis_t_fieldcat_alv,
ls_line type slis_listheader,
gd_layout type slis_layout_alv,
gt_sort type slis_t_sortinfo_alv,
ls_sort type slis_sortinfo_alv,
events type slis_t_event,
list_top_of_page type slis_t_listheader,
top_of_page type slis_formname value 'TOP_OF_PAGE',
v_exit(1) type c.
constants:
alv_slis_formname type slis_formname value 'ALV_USER_COMMAND',
c_yes like space value 'X',
c_no like space value space.
DATA: BEGIN OF E_NAME,
NACHN LIKE PA0002-NACHN,
VORNA LIKE PA0002-VORNA.
DATA: END OF E_NAME.
* define selection screen
selection-screen begin of block elmo with frame title text-001.
selection-screen begin of line.
selection-screen comment 1(22) text-005.
select-options opt4 for pa0007-schkz.
selection-screen end of line.
parameters: debg_lst as checkbox default 'X'.
selection-screen end of block elmo.
selection-screen begin of block blk2 with frame title text-002.
PARAMETERS: p_vari like disvariant-variant.
selection-screen end of block blk2.
* Form Initialization
initialization.
clear: REC.
refresh: REC.
v_repid = sy-repid.
v_save = 'A'.
clear v_variant.
v_variant-report = v_repid.
* Get default variant
alv_variant = v_variant.
call function 'REUSE_ALV_VARIANT_DEFAULT_GET'
exporting
i_save = v_save
changing
cs_variant = alv_variant
exceptions
not_found = 2.
if sy-subrc = 0.
p_vari = alv_variant-variant.
endif.
* At Selection-Screen event (value help)
at selection-screen on value-request for p_vari.
perform f4_for_variant.
* At Selection-Screen event (check input data)
at selection-screen on p_vari.
if p_vari <> space.
v_variant-report = v_repid.
v_variant-variant = p_vari.
call function 'REUSE_ALV_VARIANT_SELECT'
EXPORTING
i_dialog = c_no
it_default_fieldcat = field_tab[]
i_layout = gs_layout
CHANGING
cs_variant = v_variant.
if sy-subrc <> 0.
call function 'REUSE_ALV_VARIANT_SELECT'
EXPORTING
i_dialog = c_yes
it_default_fieldcat = field_tab[]
i_layout = gs_layout
CHANGING
cs_variant = v_variant.
endif.
endif.
* main logic
TOP-OF-PAGE.
START-OF-SELECTION.
GET PERNR.
RP-PROVIDE-FROM-LAST P0001 SPACE PNPBEGDA PNPENDDA.
* process the data according to the payroll area
IF PERNR-WERKS EQ P0001-WERKS AND PERNR-BTRTL EQ P0001-BTRTL
AND PERNR-KOSTL EQ P0001-KOSTL AND PERNR-BUKRS EQ P0001-BUKRS
AND PERNR-ABKRS EQ P0001-ABKRS AND PERNR-KOKRS EQ P0001-KOKRS.
PERFORM RETRIEVE_Time.
ENDIF.
END-OF-SELECTION.
Perform call_alv.
*======================================================================*
* forms *
*======================================================================*
FORM RETRIEVE_Time.
DATA: date_modified(10), V_STIME(8), V_ETIME(8).
DATA: Flag(1),
v_lgtxt like T512T-LGTXT,
v_ktext like caufv-ktext,
v_WRKS LIKE PC2BA-TPROG.
CALL FUNCTION 'HR_PAYROLL_PERIODS_GET'
EXPORTING
get_begda = PNPBEGDA
get_endda = PNPENDDA
TABLES
get_periods = it_t549q
EXCEPTIONS
no_period_found = 1
no_valid_permo = 2.
CHECK sy-subrc = 0.
LOOP AT it_t549q.
FLAG = 0.
CALL FUNCTION 'HR_TIME_RESULTS_GET'
EXPORTING
get_pernr = PERNR-PERNR
get_pabrj = it_t549q-pabrj
get_pabrp = it_t549q-pabrp
TABLES
GET_TBUFF = TGETBUFF
get_zl = it_zl
get_pt = it_PT
get_alp = it_ALP
get_c1 = it_C1
get_psp = it_psp
EXCEPTIONS
no_period_specified = 1
wrong_cluster_version = 2
no_read_authority = 3
cluster_archived = 4
technical_error = 5.
LOOP AT it_zl.
IF it_ZL-DATUM >= PNPBEGDA AND it_ZL-DATUM <= PNPENDDA.
* Include PSP Data if Exists.
LOOP AT IT_PSP.
IF it_psp-ZMODN IN OPT4 AND it_zl-DATUM EQ it_psp-DATUM.
MOVE it_psp-ZMODN TO REC-WRKS.
FLAG = 1.
Move:
Pernr-Pernr To REC-PERNR,
'Z' To REC-TYPE,
it_ZL-LGART TO REC-LGART,
it_ZL-ANZHL TO REC-HOURS.
perform get_ssn.
perform get_wage_type_text using REC-LGART v_lgtxt.
move v_lgtxt to REC-LGTXT.
CONCATENATE it_zl-DATUM+4(2) '/' it_zl-DATUM+6(2) '/' it_zl-DATUM(4) INTO date_modified.
IF it_ZL-BEGUZ <> ''.
CONCATENATE it_ZL-BEGUZ(2) ':' it_ZL-BEGUZ+2(2) ':' it_ZL-BEGUZ+4(2) INTO V_STIME.
ELSE.
V_STIME = ''.
ENDIF.
IF it_ZL-ENDUZ <> ''.
CONCATENATE it_ZL-ENDUZ(2) ':' it_ZL-ENDUZ+2(2) ':' it_ZL-ENDUZ+4(2) INTO V_ETIME.
ELSE.
V_ETIME = ''.
ENDIF.
Move:
date_modified To REC-DATE,
V_STIME To REC-STIME,
V_ETIME To REC-ETIME.
* Include ALP Data if Exists else include Blanks.
MOVE:
'' TO REC-UNIT,
'' TO REC-PNUMB,
'' TO REC-PID,
'' TO REC-VALU,
'' TO REC-AMOUNT,
'' TO REC-XPAYID.
IF it_ZL-ALZNR GT 0.
LOOP AT IT_ALP.
IF it_zl-ALZNR EQ it_ALP-ALZNR.
MOVE:
it_ALP-ANZHL TO REC-UNIT,
it_ALP-PRAKN TO REC-PNUMB,
it_ALP-PRAKZ TO REC-PID,
it_ALP-BWGRL TO REC-VALU,
it_ALP-BETRG TO REC-AMOUNT,
it_ALP-AUFKZ TO REC-XPAYID.
ENDIF.
ENDLOOP.
ENDIF.
* Include C1 Data if Exists Else Include Blanks.
MOVE:
'' TO REC-CCODE,
'' TO REC-CCNTR,
'' To REC-AUFNR,
'' TO REC-KTEXT.
IF it_ZL-C1ZNR GT 0.
LOOP AT IT_C1.
IF it_zl-C1ZNR EQ it_c1-C1ZNR.
MOVE:
it_C1-BUKRS TO REC-CCODE,
it_C1-KOSTL TO REC-CCNTR,
it_C1-AUFNR To REC-AUFNR.
perform get_service_order_text using REC-AUFNR v_ktext.
move v_ktext to rec-ktext.
ENDIF.
ENDLOOP.
ENDIF.
APPEND REC.
* ENDIF FOR the IF on IT_PSP
ENDIF.
ENDLOOP.
* ENDIF FOR the IF on Date Check
ENDIF.
* ENDLOOP ON IT_ZL
ENDLOOP.
LOOP AT it_pt.
IF it_PT-LDATE >= PNPBEGDA AND it_PT-LDATE <= PNPENDDA.
* Include PSP Data if Exists.
LOOP AT IT_PSP.
IF IT_PSP-ZMODN IN OPT4 AND it_pt-LDATE EQ it_psp-DATUM.
MOVE it_psp-ZMODN TO REC-WRKS.
FLAG = 1.
Move:
Pernr-Pernr To REC-PERNR,
'P' to REC-TYPE,
it_pt-BTERM TO REC-STER,
it_pt-ETERM TO REC-ETER.
perform get_ssn.
CONCATENATE it_pt-LDATE+4(2) '/' it_pt-LDATE+6(2) '/' it_pt-LDATE(4) INTO date_modified.
IF it_pt-BEGTM NE ''.
CONCATENATE it_pt-BEGTM(2) ':' it_pt-BEGTM+2(2) ':' it_pt-BEGTM+4(2) INTO V_STIME.
ELSE.
V_STIME = ''.
ENDIF.
IF it_pt-ENDTM NE ''.
CONCATENATE it_pt-ENDTM(2) ':' it_pt-ENDTM+2(2) ':' it_pt-ENDTM+4(2) INTO V_ETIME.
ELSE.
V_ETIME = ''.
ENDIF.
Move:
date_modified To REC-DATE,
V_STIME To REC-STIME,
V_ETIME To REC-ETIME.
TempHours = ''.
IF it_pt-BEGTM LT it_pt-ENDTM.
TempHours = it_pt-ENDTM(4) - it_pt-BEGTM(4).
TempHours = TempHours / 100.
ENDIF.
MOVE:
TempHours TO REC-HOURS,
'' TO REC-LGART,
'' TO REC-LGTXT,
'' TO REC-UNIT,
'' TO REC-PNUMB,
'' TO REC-PID,
'' TO REC-VALU,
'' TO REC-AMOUNT,
'' TO REC-XPAYID,
'' TO REC-CCODE,
'' TO REC-CCNTR,
'' TO REC-AUFNR,
'' TO REC-KTEXT.
APPEND REC.
ENDIF.
ENDLOOP.
ENDIF.
ENDLOOP.
IF FLAG = 0 AND debg_lst = 'X'.
Move:
Pernr-Pernr To REC-PERNR,
'' To REC-TYPE,
'' TO REC-DATE,
'' TO REC-STIME,
'' TO REC-ETIME,
'' TO REC-LGART,
'' TO REC-LGTXT,
'' TO REC-HOURS,
'' TO REC-UNIT,
'' TO REC-PNUMB,
'' TO REC-PID,
'' TO REC-VALU,
'' TO REC-AMOUNT,
'' TO REC-XPAYID,
'' TO REC-CCODE,
'' TO REC-CCNTR,
'' To REC-AUFNR,
'' To REC-KTEXT,
'' TO REC-STER,
'' TO REC-ETER.
perform get_ssn.
PERFORM LOAD_SHIFT using v_WRKS.
Move v_WRKS TO REC-WRKS.
IF REC-WRKS IN OPT4.
APPEND REC.
ENDIF.
ENDIF.
ENDLOOP.
ENDFORM. " RETRIEVE_PAYROLL
* CALL_ALV
form call_alv.
* v_repid = sy-repid.
perform build_field_catalog using field_tab[].
perform build_eventtab using events[].
perform comment_build using header_alv[].
perform build_sorttab using gt_sort[].
perform build_layout.
* v_variant-variant = '/TEST3'.
* Call ABAP List Viewer
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
it_fieldcat = field_tab[]
i_structure_name = 'REC'
i_callback_program = v_repid
is_variant = v_variant
it_events = events[]
it_sort = gt_sort[]
i_save = v_save
is_layout = gd_layout
tables
t_outtab = REC
exceptions
program_error = 1
others = 2.
endform.
* BUILD_FIELD_CATALOG
form build_field_catalog USING pt_fieldcat type
slis_t_fieldcat_alv.
clear: fieldcat, pt_fieldcat[]. refresh: fieldcat.
data: ls_fieldcat type slis_fieldcat_alv.
ls_fieldcat-tabname = 'REC'.
ls_fieldcat-edit = ' '.
ls_fieldcat-fieldname = 'PERNR'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'PERNR'.
ls_fieldcat-seltext_l = 'Employee #'.
ls_fieldcat-outputlen = 15.
ls_fieldcat-no_sum = 'X'. "Don't use field for totals
ls_fieldcat-datatype = 'NUMC'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'NAME'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'NAME'.
ls_fieldcat-seltext_l = 'Employee Name'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'TYPE'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'TYPE'.
ls_fieldcat-seltext_m = 'Type'.
ls_fieldcat-outputlen = 4.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'DATE'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'DATE'.
ls_fieldcat-seltext_l = 'Date'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'WRKS'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'WRKS'.
ls_fieldcat-seltext_m = 'Daily Sch'.
ls_fieldcat-outputlen = 10.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'STIME'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'STIME'.
ls_fieldcat-seltext_l = 'Start Time'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'ETIME'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'ETIME'.
ls_fieldcat-seltext_l = 'End Time'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'HOURS'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'HOURS'.
ls_fieldcat-seltext_s = 'Hours'.
ls_fieldcat-datatype = 'NUMC'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'PNUMB'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'PNUMB'.
ls_fieldcat-seltext_l = 'Premium #'.
ls_fieldcat-datatype = 'NUMC'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'PID'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'PID'.
ls_fieldcat-seltext_l = 'Premium Id'.
ls_fieldcat-datatype = 'NUMC'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'UNIT'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'UNIT'.
ls_fieldcat-seltext_s = 'Unit'.
ls_fieldcat-datatype = 'NUMC'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'VALU'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'VALU'.
ls_fieldcat-seltext_s = 'Valuation Basis'.
ls_fieldcat-datatype = 'NUMC'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'AMOUNT'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'AMOUNT'.
ls_fieldcat-seltext_s = 'Amount'.
ls_fieldcat-datatype = 'NUMC'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'XPAYID'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'XPAYID'.
ls_fieldcat-seltext_s = 'Extra Pay ID'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'CCNTR'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'CCNTR'.
ls_fieldcat-seltext_l = 'Cost Center'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'CCODE'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'CCODE'.
ls_fieldcat-seltext_l = 'Company Code'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'AUFNR'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'AUFNR'.
ls_fieldcat-seltext_l = 'Service Number'.
ls_fieldcat-datatype = 'NUMC'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'KTEXT'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'KTEXT'.
ls_fieldcat-seltext_l = 'Service Number Text'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'LGART'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'LGART'.
ls_fieldcat-seltext_l = 'Wage Type'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'LGTXT'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'LGTXT'.
ls_fieldcat-seltext_l = 'Wage Type Text'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'STER'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'STER'.
ls_fieldcat-seltext_l = 'Starting Terminal'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-fieldname = 'ETER'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'ETER'.
ls_fieldcat-seltext_l = 'Ending Terminal'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
ls_fieldcat-edit = ' '.
endform.
* BUILD_EVENTTAB
form build_eventtab using events type slis_t_event.
* Registration of events to happen during list display
data: tmp_event type slis_alv_event.
call function 'REUSE_ALV_EVENTS_GET'
exporting
i_list_type = 0
importing
et_events = events.
read table events with key name = slis_ev_top_of_page into tmp_event.
if sy-subrc = 0.
move top_of_page to tmp_event-form.
append tmp_event to events.
endif.
endform.
* COMMENT_BUILD
form comment_build using pt_top_of_page type slis_t_listheader.
data: v_head_string(255) value space, d1(2), m1(2), y1(2), d2(2), m2(2), y2(2).
clear: ls_line, pt_top_of_page.
ls_line-typ = 'H'.
data pnpfrom(10).
data pnpto(10).
data: print_date(10).
data: print_time(10).
d1 = PNPBEGDA+6(2). d2 = PNPENDDA+6(2).
m1 = PNPBEGDA+4(2). m2 = PNPENDDA+4(2).
y1 = PNPBEGDA+2(2). y2 = PNPENDDA+2(2).
concatenate m1 '/' d1 '/' y1 into pnpfrom.
concatenate m2 '/' d2 '/' y2 into pnpto.
d1 = sy-datum+6(2). d2 = sy-uzeit+2(2).
m1 = sy-datum+4(2). m2 = sy-uzeit+0(2).
y1 = sy-datum+2(2). y2 = sy-uzeit+4(2).
concatenate m1 '/' d1 '/' y1 into print_date.
concatenate m2 ':' d2 ':' y2 into print_time.
ls_line-info = sy-repid.
append ls_line to pt_top_of_page.
concatenate 'Printed by:' sy-uname 'on' print_date 'at' print_time
into ls_line-info separated by space.
append ls_line to pt_top_of_page.
ls_line-info = 'BGM INDUSTRIES, INC.'.
append ls_line to pt_top_of_page.
concatenate 'Supply Period:' pnpfrom 'to' pnpto
into ls_line-info separated by space.
append ls_line to pt_top_of_page.
endform.
* Build layout for ALV grid report
form build_layout.
gd_layout-no_input = 'X'.
gd_layout-colwidth_optimize = 'X'.
gd_layout-totals_text = 'Totals'(201).
gd_layout-info_fieldname = 'LINE_COLOR'.
endform. " BUILD_LAYOUT
* TOP_OF_PAGE
form top_of_page.
call function 'REUSE_ALV_COMMENTARY_WRITE'
exporting
i_logo = 'Z_BGLOGO'
it_list_commentary = header_alv.
endform.
*& Form build_sorttab
* Set up the sorting for the report.
form build_sorttab using pt_sort type slis_t_sortinfo_alv.
clear lv_sortseq.
perform build_sort tables pt_sort changing ls_sort.
ls_sort-fieldname = 'PERNR'.
ls_sort-subtot = 'X'.
append ls_sort to pt_sort.
ls_sort-subtot = ' '.
perform build_sort tables pt_sort changing ls_sort.
ls_sort-fieldname = 'NAME'.
ls_sort-subtot = 'X'.
append ls_sort to pt_sort.
ls_sort-subtot = ' '.
endform. " build_sorttab
* Use to add another sort field.
form build_sort
tables pt_sort
changing ls_sort structure x_sortinfo_alv.
clear ls_sort.
add 1 to lv_sortseq.
ls_sort-spos = lv_sortseq.
ls_sort-up = 'X'.
ls_sort-tabname = 'REC'.
endform. "build_sort
*} INSERT
*& Form GET_SSN & EMP Name
* text
FORM GET_SSN.
SELECT SINGLE * FROM PA0002 WHERE PERNR = PERNR-PERNR.
IF SY-SUBRC EQ 0.
MOVE: PA0002-PERNR TO REC-SSN,
PA0002-VORNA TO E_NAME-VORNA,
PA0002-NACHN TO E_NAME-NACHN.
CONDENSE E_NAME.
MOVE: E_NAME TO REC-NAME.
ENDIF.
ENDFORM. " GET_SSN
* Form GET_WAGE_TYPE_TEXT
form get_wage_type_text using rec-LGART p_v_lgtxt.
select single LGTXT from T512T into p_v_lgtxt
where LGART = rec-LGART.
endform. " GET_WAGE_TYPE_TEXT
* Form GET_SERVICE_ORDER_TEXT
form get_service_order_text using rec-AUFNR p_v_ktext.
select single ktext from caufv into p_v_ktext
where aufnr = rec-aufnr.
endform. " GET_SERVICE_ORDER_TEXT
*& Form LOAD_SHIFT
* text
FORM LOAD_SHIFT USING V_WRKS.
SELECT SINGLE * FROM PA0007 WHERE PERNR = REC-PERNR.
IF SY-SUBRC EQ 0.
MOVE: PA0007-SCHKZ TO V_WRKS.
ENDIF.
ENDFORM.
*& Form f4_for_variant
form f4_for_variant.
call function 'REUSE_ALV_VARIANT_F4'
EXPORTING
is_variant = v_variant
i_save = v_save
IMPORTING
e_exit = v_exit
es_variant = alv_variant
EXCEPTIONS
not_found = 2.
if sy-subrc = 2.
message id sy-msgid type 'S' number sy-msgno
with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
else.
if v_exit = space.
p_vari = alv_variant-variant.
endif.
endif.
endform. " f4_for_variant
Please help. I will reward Points for the right answers.
ThanksOk found the problem at last
ls_fieldcat-fieldname = 'PERNR'.
ls_fieldcat-ref_tabname = 'REC'.
ls_fieldcat-ref_fieldname = 'PERNR'.
ls_fieldcat-seltext_l = 'Employee #'.
ls_fieldcat-outputlen = 15.
ls_fieldcat-no_sum = 'X'. "Don't use field for totals
ls_fieldcat-datatype = 'NUMC'.
append ls_fieldcat to pt_fieldcat.
clear ls_fieldcat.
In my build catalog i was clearing every field using the
clear ls_fieldcat.
which was some how clearing the sortings...
SO commented them out and it works. -
Problem with data integration when using KCLJ
Hello,
For a project, I had to integrate a new field using transaction KCLJ.
For this I extented the DDIC structure of the sender structure, and after that, I updated the corresponding transfer rules.
When I execute transaction KCLJ I have no error, and table BUT000 is updated with the data of the flat file.
The problem is that erase also 6 BUT000's fields; they're not in the sender structure and so, have no transfer rules.
Could you help me ?Hi
Please read this.
External Data Transfer
These activities are not relevant if you use a CRM/EBP system.
In the following activities you make definitions for transfer of business partner data or business partner relationship data from an external system to a SAP System.
Data transfer takes place in several stages:
1. Relevant data is read from the external system and placed in a sequential file by the data selection program. The data structure of the file is defined in the sender structure.
This procedure takes place outside of the SAP environment and is not supported by SAP programs. For this reason, data changes can be made at this point by the data selection program.
2. The sequential file is stored on an application server or a presentation server.
3. The SAP transfer program reads data from the file and places this in the sender structure. This does not change the data. This step is carried out internally by the system and does not affect the user.
4. Following transfer rules that have to be defined, the transfer program takes the data from the sender structure and places it in the receiver structure. During this step you can change or convert data.
The receiver structure is firmly defined in the SAP system. Assignment of the sender structure to the transfer program, and of the transfer program to the receiver structure is made using a defined transfer category.
5. The data records in the receiver structure are processed one after the other and, if they do not contain any errors, they are saved in the database.
Before you transfer external data for the first time, make the following determinations:
The structure of the data in the external system may not match the structure expected by the SAP system. You may have to supplement data.
There are two ways in which you can adapt the structure:
You make the required conversions and enhancements within the data selection program prior to beginning the transfer to the SAP system. This will be the most practical solution in most cases since you have the most freedom at this point.
You do the conversion using a specially developed transfer program and transfer rules.
You then define the fields of the sender structure. The system offers you the option of automatically generating a sender structure that is compatible with the receiver structure.
You define transfer rules to create rules according to which the fields of the sender structure are linked with those of the receiver structure.
You now carry out the transfer.
SAP Enhancements for External Data Transfer
The following SAP enhancements are offered in the following areas of External Data Transfer:
Four Customer Exits exist for the data transfer or for the conversion from IDOC segments. The Exits are contained in the enhancement KKCD0001. As soon as the Customer Exits are activated, they are carried out for all sender structures or segments. The first two Customer Exits require minimal coding once they are activated. The sender structure concept is used when loading data into the SAP-System. The concept Segment is used in the context of the distribution of the SAP-System. It is a matter of a record of data to be transferred or converted. It is recommendable to code a CASE -instruction within the Customer Exit, where (differentiated according to sender structure (REPID) or segment) various coding is accessed. In the parameter REPID, the name of the segment for the conversion from IDOC segments. The parameter GRPID is not filled out with the conversion from IDOC segments. You should have a WHEN OTHERS branch within the CASE instruction, in which the 'SENDER_SET' is allocated to the 'SENDER_SET_NEW' or the 'RECEIVER_SET' to the 'RECEIVER_SET_NEW'. Utherwise the return code will have its initial value. You can view a possible solution in Code sample.
The first Customer Exit is accessed before the summarizing or conversion. It is called up as follows:
CALL CUSTOMER-FUNCTION '001' EXPORTING GRPID = GRPID "Origin REPID = REPID "Sender program SENDER_SET = SENDER_SET "Sender record IMPORTING SENDER_SET_NEW = SENDER_SET "modified sender record SUBRC = SUBRC. "Returncode
If the variable 'SUBRC' is initial, the modified record is edited further or else passed over. The import parameter 'SENDER_SET_NEW ' must be filled out in the Customer Exit, as only this field and not the field 'SENDER_SET is further edited. This also especially means that you must allocate the import parameter 'SENDER_SET_NEW' the value of 'SENDER_SET' for records, for which no special handling will be carried out otherwise.
The second Customer Exit is accessed after the summarization and before the update:
CALL CUSTOMER-FUNCTION '002' EXPORTING REPID = REPID "Senderprogramm GRPID = GRPID "Herkunft RECEIVER_SET = RECEIVER_SET "verdichteter Satz IMPORTING RECEIVER_SET_NEW = RECEIVER_SET "modifizierter verdichteter Satz SUBRC = SUBRC. "Returncode
The modified record is only updated if the variable 'SUBRC'
is initial.
The import parameter 'RECEIVER_SET_NEW' must be filled out in the Customer Exit, since only this field and not the field 'RECEIVER_SET _NEW' is updated.
The third Customer Exit is used for replacing variables. It is called up when you load the transfer rules.
CALL CUSTOMER-FUNCTION '003' EXPORTING REPID = REPID GRPID = GRPID VARIA = VARIA RFELD = RFELD VARTP = VARTP CHANGING KEYID = KEYID EXCEPTIONS VARIABLE_ERROR = 1.
The parameters REPID and GRPID are supplied with the sender structure and the origin. The variable name is in the field VARIA. The name of the receiver field is in the parameterRFELD. Field VARTP contains the variable type. Valid types are fixed values of the domain KCD_VARTYP. You transfer the variable values in the parameter KEYID. If an error occurs you use the exception VARIABLE_ERROR.
the fourth Customer Exit is required in EC-EIS only. It is called up after the summarization and before the determination of key figures. It is a necessary enhancement to the second Customer Exit. This is because changes to the keys are considered before the database is checked to see if records exist for the keys.
The function is called up as follows:
CALL CUSTOMER-FUNCTION '004' CHANGING RECEIVER_SET = R SUBRC = UE_SUBRC.
The parameter RECEIVER_SET contains the receiver record to be changed. The parameter RECEIVER_SET is a changing parameter. No changes must be made to the function module if it is not used.
The User-Exits can be found in the Module pool 'SAPFKCIM'. If you want to use the Customer Exits, you can create a project and activate the Customer Exits with the transaction 'CMOD'. The enhancement which you must use with it is KKCD0001.
Note that when programming customer exits, that these will also run if corrected data records are imported into the datapool within the context of post processing for both test and real runs.
I will provide some pointers soon. Give me some time.
Hope this will help.
Please reward suitable points.
Regards
- Atul
Maybe you are looking for
-
Re Mapping your Creative Remote
Hi everybody I recently bought a Creative X-FI surround 5.1 Pro USB soundcard, and I must say I found the remote quite amazing XD. The only bad part is the apps available.... so I googled a little : I found that VLC thread on how to remap for a speci
-
How to change the Dr Sales Dealer to Dr Accrued Sales?
Hi All, For normal billing/invoice, the double entry is as below : Dr Sales Dealer Cr Sales Cr Exise Duty Payable Dr Dealers Margin In order to implement the proforma invoice, we have decided to create debit memo which is similar to Excise Inv wi
-
Organizing albums into one album
We are new to the Mac world and have a large number of pictures to be organized, In iPhoto, are you able to create "sub-albums"? For example, if we have photos of a number of related events, like football games in a season, can we have an album "Foot
-
How to setup facetime on my macbookpro
how to setup facetime on my macbook pro
-
Hi all, I want to extract the data from the invoice smartform and i should display it in pdf format.I have invoice number with me as input parameter. Can any one solve my problem...it is urgent plz......... Thanks , Rakesh.