Urgent: About Obsolete ABAP statements in Netweaver 4.0?
Can any body please help us about the obsolete ABAP statements in Netweaver 4.0 corresponding to SAP 4.6?
Hi,
Pls read first the rules of engagement.
Anyway, open an editor and choose Utilities->Help on->New features in ABAP.
Or check notes like
367676 and 689951
Eddy
Similar Messages
-
Obsolete ABAP statements in OOPs context
Obsolete ABAP statements in OOPs context
hi,
Check t-code UCCheck.
Put the program name in the t-code and you will get the obsolete statements.
Also check table radir.
<b>Reward points if useful.</b> -
Obsolete ABAP statements/FM/BAPI in sap 4.7
dear experts
pls gv me the details of obsolete ABAP statements/FM/BAPI in sap 4.7 and their replacement in ECC 6.0,the statements should be related to MODULE POOL ,reportsHello
ERP 6.0 implies Unicode as well. Therefore have a look at [ABAP and Unicode|http://help.sap.com/saphelp_nw04/helpdata/en/62/3f2cadb35311d5993800508b6b8b11/content.htm]
You will find useful documentation in the ABAP keyword documenation (ERP 6.0) as well:
Obsolete Statements
The statements described in this subnode are obsolete and are only still available for reasons of compatibility with releases prior to 4.6 or 6.10. You may still come across these statements in old programs but you should not use them in new programs.
Most of the obsolete statements listed here are syntactically forbidden in ABAP Objects or in Unicode programs. As a result, they can now only be used outside of classes or non-Unicode programs. There are replacement constructions for all obsolete statements which improve the efficiency and readability of programs.
Apart from the obsolete statements listed in this node, there are also obsolete variants and additions for non-obsolete statements. These cannot be used in ABAP Objects and Unicode programs either. They are detailed in the description of the corresponding statements.
Regards
Uwe -
Obsolete ABAP Statements from 2004s - what about your existing code-base?
Hi
Note: This is a question for someone that has a very deep understanding of the SAP compiler either through research or through actually working on the Netweaver Code stack
Since upgrading from 4.7 to ECC6 the ABAP compiler has become a lot stricter on the use of certain statements in the OO context.
For instance you're not allowed to use the statement LIKE, but in stead have to use TYPE and internal tables does not have an implicit header line, etc.
These restrictions are explained in greater detail [here:|http://help.sap.com/abapdocu/en/ABENABAP_OBJECTS_DIFF_TYPES_DATA.htm]
MY QUESTION: To what extent does this restriction affect your existing code-base?.
We have over a thousand "Classes" written since 1998 in OO as far as it was available at the time. For the most part each class is its own include in SE38, with the class definition and implementation together in this include.
Up to now, we could successfully change and activate these classes as long as the main program was pre-existing in 4.7. Now we are trying to use one of these older classes in a new main program for regression test purposes, and we are getting the following error:
"Within classes and interfaces, you can only use "TYPE" to refer to ABAP Dictionary types (not "LIKE" or "STRUCTURE")."
This error is valid as per the current definition of the SAP language.
BUT I'm concerned about the confidence we can have that SAP will continue to interpret and execute existing code correctly. So far it has, but I would like to know wheter that is by chance, or by design.Hello Esti
Thank you for your explanation which shows that I misunderstood your question.
I would have expected that all of your syntactically incorrect coding would not be executed, irrespective of whether it is an old or a new program. My interpretation of this system behaviour is that the syntax check appears to be release-dependent.
A possible way to check this would be to manipulate the TRDIR entry for one of your old programs. You will find a field LEVL with the following meaning:
DE RDIR_LEVL
Short Text
Level
Definition
System release under which the ABAP/4 program was created or last
changed.
Another way would be to copy an old program to a new Z-program which should fail in the syntax check. Check again if you find any significant difference in their TRDIR entries.
Coming back to you question and the remark by Dion I am convinced that one of the biggest threats for each and every SAP customer is custom coding of poor quality, i.e.
"spaghetti" coding instead of structured programming
incomprehensible coding (at least for the developers who did NOT create the program)
low transparency resulting in high efforts to enhance or improve the coding
In your case: the possible breakdown of your coding depending on unknown external factors
Given the huge amount of coding that is affected from these unknown external factors I would classify your situation as "high risk" which demands rather quick actions. How could you communicate this to your management team?
Here are two possible suggestions:
(1) It is possible that your entire custom coding may be no longer executable after a SAP release upgrade. Thus, the currenct coding base may prevent one of the next upgrades.
I guess this is not yet impressive enough for a manager because usually a SAP customer is not forced to upgrade its SAP system in order to get new functionalities which are required for legal reasons.
(1.a) It is possible that your entire custom coding may no longer be executable after importing ABA and/or BASIS hot packages.
Given the fact that we need to import such packages quite frequently and sometimes they are mandatory (I think especially of SAP-HR systems) then I would be scared as a manager.
(2) Assuming that most of your Z-reports are started via Z-transactions and perhaps you are lucky and you have specific roles containing these Z-transactions then you may ask your management team to do a simulation of coding breakdown: remove the role assignments for a couple of users and see what happens.
(2.a) As an alternative you may try to lock Z-transactions via SM01 and again check for the user reactions.
If your managment team is still not impressed then I would set up a document with the following contents:
Explain the problems of the old coding base and why you could not anticipate future changes of the ABAP syntax check
Describe the possible scenario if the custom coding no longer works after an upgrade or hot package import
Describe the required actions to make your custom coding compatible to the latest ABAP release
Most important: urge your management team to sign this document. If one day your custom coding breaks and they are looking for somebody to blame you just take this document out from the bottom of the deck
Regards
Uwe -
hi friends,
Is it poosible to find out what are the Obsolete ABAP commands and Statements by comparing two different versions? an old version and an advanced version??
Is it stored in any table?
Pls Help
Regards
DineshHi,
Just check this link
http://www.nikat.org/www.geocities.com/victorav15/sapr3/abapobs.html
http://help.sap.com/saphelp_nw2004s/helpdata/en/fc/eb33cc358411d1829f0000e829fbfe/content.htm
You may have an overview wirth Solution Browser tool (at the solution point of view) in order to compare functionality between your current system and the ERP 2005.
at:
http://solutionbrowser.erp.sap.fmpmedia.com/
You can get the detailed release information from the following link.
http://service.sap.com/releasenotes.
A release note is a brief explanation of new features or changes to the system since the last software release. A release note typically describes a new function or an existing function that has been enhanced or changed.
Regards,
Padmam. -
SAP Certified Development Professional - ABAP with SAP NetWeaver 7.0
Hi.
I want do the test "SAP Certified Development Professional - ABAP with SAP NetWeaver 7.0".
I find some book about, but i not find it.
I pass in the SAP Certified Development Associate.
My english is not good, i´m from Brazil.
Does anyone have any books to recommend on me?
Thanks.Try this sample question from SAP
http://www.sap.com/services/education/certification/schedule/PABAP70.epx
and prepare according to Competency Areas
http://www.sap.com/services/education/certification/certroles/certificationtest.epx?context=%5b%5bP_ABAP_70%7cG%5d%5d%7c
I cannot find the book speacially for this certification. -
I want to know about enterprise soa and sap netweaver
Hi all,
i am ABAP'r , i want to know about Enterprise SOA And SAP Netweaver ,
please send some documents about that .
Thanks®ards.
Naveen KumarESOA mean Enterprise Service Oriented Architecture
SOA mean an Architecture approach to define IT solution for business problems using loose couples SERVICES
Service mean: definition of a business function in terms of the service message, protocol and nature
Nature mean Service direction, Service mode and service contract
WEB SERVICE, XML, XSD, SOAP : Mean a technology following SOA architecture approach to IT enablement of a business need.
WEB service compose business functions, location of services, messages of service offering and protocol into a single definition to define service contract.
XML mean a common language to represent message
XSD mean a common way to define message structure
SOAP mean a procol which carry messages of services between service consumer and service provider.
Finally : Web service is not SOA. Web service is a technology implementing SOA architectural approach to IT enablement of a business NEED.
Note: If you are happy with answer please make sure point is rewarded.
Thanks -
Hi all,
does anyone know what the abap statement RSYN is for?
I haven't found anything about it in help docs.
:busHi,
I am getting dump call_function_format_not_sup which showing sapmssy1 program error. i am attaching the dump. plz check and kindly help me.
ABAP/4 runtime error CALL_FUNCTION_FORMAT_NOT_SUP
Occurred on 07.07.2009 at 15:15:18
RFC data format not supported.
What happened?
An error occurred when executing a Remote Function Call.
The current ABAP/4 program "SAPMSSY1" had to be terminated because
one of the statements could not be executed.
This is probably due to an error in the ABAP/4 program.
What can you do?
Print out the error message (using the "Print" function)
and make a note of the actions and input that caused the
error.
To resolve the problem, contact your
SAP system administrator.
Error analysis
A data error occurred when executing a Remote Function Call.
The data format used is not supported by the recipient.
How to correct the error
A 'Remote Function Call' passed data in the incorrect format or
length. If both the calling program and the called program are
ABAP/4 function modules, there is an error in the
SAP system.
If one of these programs is a CPI-C program which interprets the
RFC log itself, the error has probably occurred because the program
does not conform to the standards defined by SAP.
System environment
SAP Release.............. "31H"
Application server....... "PCPPROD1"
Network address.......... "10.106.128.71"
Operating system......... "SunOS"
Release.................. "5.6"
Hardware type............ "sun4u"
Database server.......... "PHYPLW02"
Database type............ "ORACLE"
Database name............ "ALP"
Database owner........... "SAPR3"
Character set............ "en"
SAP kernel............... "31I"
Created on............... "Jul 24 2001 05:20:53"
Created in............... "SunOS 5.5.1 Generic_103640-19 sun4u"
Database version......... "ora OCI_73400"
Patch level.............. "616"
Patch text............... " "
Supported environment....
Database................. "ORACLE 7.2..., ORACLE 7.3..., ORACLE
8.0...*"
SAP database version..... "31I"
Operating system......... "SunOS 5.5.1, SunOS 5.6, SunOS 5.7, SunOS 5.8"
User, transaction...
Client.............. 000
User................ "SAPSYS"
Language key........ "E"
Transaction......... " "
Program............. "SAPMSSY1"
Screen.............. "SAPMSSY13004"
Screen line......... 2
Information on where termination occurred
The termination occurred in the ABAP/4 program "SAPMSSY1" in
"REMOTE_FUNCTION_CALL".
The main program was "SAPMSSY1".
The termination occurred in line 67
of the source code of program "SAPMSSY1" (when calling the editor 670).
Source code extract
000370 ENDMODULE.
000380
000390 MODULE %_RFCDIA_CALL OUTPUT.
000400 "Do not display screen !
000410 CALL 'DY_INVISIBLE_SCREEN'.
000420 PERFORM REMOTE_FUNCTION_DIACALL.
000430 ENDMODULE.
000440
000450 MODULE %_CPIC_START.
000460 IF SY-XPROG(4) = '%RFC'.
000470 PERFORM REMOTE_FUNCTION_CALL USING RFCTYPE_EXTERNAL_CPIC.
000480 ELSE.
000490 CALL 'APPC_HD' ID 'HEADER' FIELD HEADER ID 'CONVID' FIELD CONVID.
000500 PERFORM CPIC_CALL USING CONVID.
000510 ENDIF.
000520 ENDMODULE.
000530
000540
000550 FORM CPIC_CALL USING CONVID.
000560 COMMUNICATION SEND ID CONVID BUFFER HEADER.
000570 IF SY-SUBRC EQ 0.
000580 PERFORM (SY-XFORM) IN PROGRAM (SY-XPROG).
000590 ELSE.
000600 MESSAGE A800.
000610 ENDIF.
000620 ENDFORM.
000630
000640
000650 FORM REMOTE_FUNCTION_CALL USING VALUE(TYPE).
000660 DO.
CALL 'RfcImport' ID 'Type' FIELD TYPE.
000680 PERFORM (SY-XFORM) IN PROGRAM (SY-XPROG).
000690 RSYN >SCONT SYSC 00011111 0.
000700 ENDDO.
000710 ENDFORM.
000720
000730 FORM REMOTE_FUNCTION_DIASTART.
000740 DO.
000750 CALL 'RfcImport' ID 'Type' FIELD RFCTYPE_RFCDIA.
000760 PERFORM (SY-XFORM) IN PROGRAM (SY-XPROG).
000770 "Parking position for next request
000780 RSYN >SCONT SYSC 00011111 10.
000790 "ALternativ : Free mode
000800 "COMMIT WORK.
000810 "SYSTEM-CALL FREE MODE 0.
000820 ENDDO.
000830 ENDFORM.
000840
000850 FORM REMOTE_FUNCTION_DIACALL.
000860 SY-XCODE = '%_@no@'.
Contents of system fields
SY field contents..................... SY field contents.....................
SY-SUBRC 0 SY-INDEX 1
SY-TABIX 0 SY-DBCNT 0
SY-FDPOS 0 SY-LSIND 0
SY-PAGNO 0 SY-LINNO 1
SY-COLNO 1
Chosen variables
Name.......................... Contents.1........2........3....+....4
SY-MSGV1
2222222222222222222222222222222222222222
0000000000000000000000000000000000000000
... + 40
2222222222
0000000000
SY-MSGV2
2222222222222222222222222222222222222222
0000000000000000000000000000000000000000
... + 40
2222222222
0000000000
SY-MSGV3
2222222222222222222222222222222222222222
0000000000000000000000000000000000000000
... + 40
2222222222
0000000000
SY-MSGV4
2222222222222222222222222222222222222222
0000000000000000000000000000000000000000
... + 40
2222222222
0000000000
TYPE 3
0000
0003
SY-XPROG
22222222
00000000
SY-XFORM
222222222222222222222222222222
000000000000000000000000000000
Active calls / events
No.... Program INCLUDE Line Type.... Name.....................
1 SAPMSSY1 SAPMSSY1 67 FORM REMOTE_FUNCTION_CALL
2 SAPMSSY1 SAPMSSY1 30 MODULE %_RFC_START
Internal notes
The termination occurred in the function "ab_rfctinfo" of the SAP
Basis System, specifically in line 1178 of the module " ".
The internal operation just processed is "CALY".
List of ABAP/4 programs affected
Program
Load size
Roll size
Gen. date
/ time Changed by
SAPMSSY1
20480
83050
21.05.1997
16:27
21.05.1997
SAP
List of internal tables
No dump information available
Directory of application tables (contents)
Program name........... Contents.1........2........3....+....
SAPMSSY1 TCPIC
Directory of data areas (administration information)
No Program name........... Length Gen.date Gen.time Ofst Type Next
0 SAPMSSY1 /%_LISTTABLES 3128 -3 DATA
1 SAPMSSY1 stack area 65536 -2 DATA
2 SAPMSSY1 text pool 4064 -1 DATA
3 SAPMSSY1 global data 1136 0 DATA
4 SAPMSSY1 local data 0 1 STCK
5 SAPMSSY1 constant data 647 2 LITL
6 SAPMSSY1 not assigned 0 3 INVL
7 SAPMSSY1 SYST 2232 4 TABL
8 SAPMSSY1 SY 2232 5 TABL
9 SAPMSSY1 RSJOBINFO 84 6 TABL
10 SAPMSSY1 /%_SCREEN 56 7 DATA
11 SAPMSSY1 /%_SYS%% 480 8 DATA
12 SAPMSSY1 TCPIC 70 9 TABL
Directory of data areas (contents)
No Program name........... Contents.1........2........3....+....
0 SAPMSSY1 /%_LISTTABLES |00000x0C000000000x0C0
1 SAPMSSY1 stack area |000x030000ÿÿÿÿ00000000
2 SAPMSSY1 text pool |ÿÿ000006E000000x01R00000
3 SAPMSSY1 global data | 0 x04
4 SAPMSSY1 local data
ABAP/4 control blocks CONT
Index Name F1 Co Par01 Par2. Par3. Par4. Tabl Source Line Source code........
146 CLEA 00 83 SAPMSSY1 60 MESSAGE A800.
147 CLEA 00 84 SAPMSSY1 60
148 CLEA 00 85 SAPMSSY1 60
149 CLEA 00 86 SAPMSSY1 60
150 MESS 00 327 SAPMSSY1 60
151 ENDF 00 SAPMSSY1 62 ENDFORM.
156 PERP 02 SAPMSSY1 65 FORM REMOTE_FUNCTI
157 WHIL 00 2 SAPMSSY1 66 DO.
161 WHIL 00 3 SAPMSSY1 66
165 BRAN 05 Branch to 178 SAPMSSY1 66
166 CALY 00 3 87 72 73 73 SAPMSSY1 67 CALL 'RfcImport' I
>>>>> CALY 02 88 P0 SAPMSSY1 67
174 xper 02 22 23 SAPMSSY1 68 PERFORM (SY-XFORM)
176 SYSC 1F SAPMSSY1 69 RSYN >SCONT SYSC 0
177 BRAX 00 Branch to 161 SAPMSSY1 70 ENDDO.
178 WHIL 00 4 SAPMSSY1 70
182 ENDF 00 SAPMSSY1 71 ENDFORM.
187 WHIL 00 2 SAPMSSY1 74 DO.
End of runtime analysis -
Same ABAP statements for SY-SUBRC 0 or 4
Hi,
I have a READ TABLE statement and if the SY-SUBRC is equal to 0 or 4, the same ABAP statements should be giving to both. What would be the most efficient way of writing this? Should I just not check for for the SY-SUBRC?
Thanks,
RTYou can simply check for 0 and 4, or if there is no chance of sy-subrc being anything other 0 or 4, simply don't check it..
clear itab.
read table itab with key....
check sy-subrc = 0
or sy-subrc = 4.
Regards,
Rich Heilman -
ECC 6.0 Upgrade from R/3 4.6B - Obsolete ABAP Language
Hello all,
I am part of a team that is performing an upgrade to ECC 6.0 from R/3 4.6B. I was wondering if all of the reports, FM, etc. that were developed under "old" ABAP will have to be modified in order to comply with the <a href="https://www.sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/5ac31178-0701-0010-469a-b4d7fa2721ca">Obsolete ABAP Language Constructs</a>.
If the code still works after the upgrade is it necessary to perform all these modifications?
Thank you very much in advance,
Best Regards,
EzequielI would say that is is not necessary. From the second paragraph of your link:
"Although you are generally not forced to modify your existing programs to represent these changes, it would be a very good practice to implement these rules and constructs with any new code development and coding samples." -
Error "Error in ABAP statement when processing an internal table. table."
Hello,
I am facing the error when tried for GR from SRM portal for my shopping cart and for others created shopping cart. The error is
"Error in ABAP statement when processing an internal table. table."
I have the central receipient role. Couold any body assist me?
Thanks,
PijushHi Harish,
Execute the query in RSRT and check whether you have any short dump is in ST22. This would give a clear idea at what might have gone wrong.
Another thing is to check whether the code for the variable is fine in the user exit.
Hope this helps.
Bye
Dinesh -
In which cases can the ABAP statement CALL TRANSFORMATION be used?
Hi friends,
here is my questions with options below.
In which cases can the ABAP statement CALL TRANSFORMATION be used? (T/F)
-To transform as iXML document object into and ABAP data structure using
XSLT.
- To transform an XML document contained in a string into another XML
document
using and XSLT program.
- To get canonic XML display of an ABAP data structure.
- To transform an XML document contained in an xstring into another XLM
document using an ST program (Simple Transformation).
- To transform and ABAP data structure into an SML document using ST.
Kindly give me the expalnation to each statement with either True or False.CALL TRANSFORMATION is a new language element in ABAP that we can use to <b>call up the transformation</b>.
The type of transformation:
XML to XML
XML to ABAP
ABAP to XML or
ABAP to ABAP is already determined by the two additions SOURCE and RESULT in CALL TRANSFORMATION.
Check this link for more details.
http://help.sap.com/saphelp_nw04/helpdata/en/a8/824c3c66177414e10000000a114084/content.htm
Regards,
Maha -
LIKE and Type in abap statements
Hello All ,
I have a question regarding the 'Like' and' Type'
I have created a badi XXX , The method has a changing parameter 'A' which is referenced to a structure .
The typing method I have mentioned in the method ( in the parameter list ) is TYPE .( I feel it should have been Like ). Can this cause an issue while writing abap statements in the method ?
Thanks in advance .
Best Regards,
swethaHi Swetha,
Check out the below link for your question.
what is the difference between type and like
Re: what is the difference between type and like
Re: what is the difference between type and like
Thanks,
Chidanand -
Need info about c_taw12 abap certification exam
Hi All,
I have 3 years of experience in SAP ABPA and i would like to write the ABAP c_taw12 exam. Can any body please let me know what is producer to apply? What are the exam criteria (mean experience)? Please provide me more detail information about the ABAP certification exam.
Thanks in advance!
Regards,
Kannan<b>http://www.sap.com/asia/services/education/centres/index.epx</b>
You can contact the education center nearest to ur location, they would guide you how to apply.
They generally ask for 1 year working expereince in the company from which u r applying, but its not mandatory. If u r company sponsred, then no such pre-requisites.
If u have 3 years exp in ABAP then clearing the certification wont be that tough, just follow the 5 books that SAP provides. The certification tests the conceptual knowledge of the candidate.
<b>Hope this is helpful.</b> -
About HR-ABAP Sample program.
Hi,
I am new to SAP.I wanna know about basics about HR-ABAP can any one help me to get very basic ideas in HR-ABAP.
Thanks,
Sakthi.HR deals with the INFOTYPES which are similar to Tables in General ABAP.
There are different ways of fetching data from these infotypes.
There are different areas in HR LIKE Personal Admn, Orgn Management, Benefits, Time amangement, Event Management, Payroll etc
Infotypes for these areas are different from one another area.
storing of records data in each type of area is different
LDBS like PNP are used in HR programing.
Instead of Select.. we use some ROUTINES and PROVIDE..ENDPROVIDE.. etc
and in the case of Pay roll we use Clusters and we Import and Export them for data fetching.
On the whole Normal ABAP is different from HR abap.
For Personal Admn the Infotypes start with PA0000 to PA1999
Time Related Infotypes start with PA2000 to PA2999.
Orgn related Infotypes start with HRP1000 to HRP1999.
All custom developed infotypes stsrat with PA9000 onwards.
In payroll processing we use Clusters like PCL1,2,3 and 4.
Instead of Select query we use PROVIDE and ENDPROVIDE..
You have to assign a Logical Database in the attributes PNP.
Go through the SAp doc for HR programming and start doing.
http://www.sapdevelopment.co.uk/hr/hrhome.htm
See:
http://help.sap.com/saphelp_46c/helpdata/en/4f/d5268a575e11d189270000e8322f96/content.htm
sites regarding hr-abap:
http://www.sapdevelopment.co.uk/hr/hrhome.htm
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/PAPA/PAPA.pdf
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/PAPD/PAPD.pdf
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/PYINT/PYINT_BASICS.pdf
http://www.atomhr.com/training/Technical_Topics_in_HR.htm
http://www.planetsap.com/hr_abap_main_page.htm
You can see some Standard Program examples in this one ...
http://www.sapdevelopment.co.uk/programs/programshr.htm
http://searchsap.techtarget.com/originalContent/0,289142,sid21_gci1030179,00.html?Offer=SAlgwn12604#Certification
http://www.erpgenie.com/faq/hr.htm.
http://www.planetsap.com/hr_abap_main_page.htm
http://www.sapbrain.com/TUTORIALS/FUNCTIONAL/HR_tutorial.html
These are the FAQ's that might helps you as well.
http://www.sap-img.com/human/hr-faq.htm
http://www.sapgenie.com/faq/hr.htm
http://www.planetsap.com/hr_abap_main_page.htm
http://www.atomhr.com/library_full.htm
HR Long texts Upload
Look at the below link
BDC - hr maintain text
Please refer to the following sample program for accessing PCH LDB.
For concept to start with refer url:
http://www.sap-press.de/download/dateien/860/sappress_mysap_hr_technical_principles2.pdf
It contains info regarding PCH Reporting.
REPORT zhsol010.
TABLES: objec, gdstr.
INFOTYPES: 0002, 0006, 1003.
DATA: stabs LIKE p1003-stabs,
name LIKE p0001-ename.
INITIALIZATION.
pchotype = 'O'.
pchwegid = 'O-S-P'.
GET objec.
IF objec-otype = 'S'.
CLEAR stabs.
LOOP AT p1003 WHERE begda LE pc-endda
AND endda GE pc-begda.
IF p1003-stabs = 'X'.
stabs = 'X'.
WRITE : / objec-objid, objec-short, objec-stext.
ENDIF.
ENDLOOP.
ENDIF.
IF objec-otype = 'P' AND stabs = 'X'.
PROVIDE vorna nachn FROM p0002
subty telnr FROM p0006
BETWEEN pc-begda and pc-endda
WHERE p0006-subty = '1'.
IF p0006_valid = 'X'.
CONCATENATE p0002-vorna p0002-nachn INTO name
SEPARATED BY space.
WRITE: / name, p0006-telnr.
SKIP.
ENDIF.
ENDPROVIDE.
ENDIF.
<b>sample code:</b>
REPORT zpwtest .
TABLES : t001 .
TYPE-POOLS slis .
DATA : t_t001 TYPE TABLE OF t001 ,
t_abaplist TYPE TABLE OF abaplist .
DATA : w_abaplist TYPE abaplist .
SELECT-OPTIONS : s_bukrs FOR t001-bukrs OBLIGATORY .
PARAMETERS : p_list TYPE c NO-DISPLAY .
START-OF-SELECTION .
IF sy-batch = 'X' AND p_list IS INITIAL .
Submit report and get list in memory
SUBMIT zpwtest EXPORTING LIST TO MEMORY
WITH s_bukrs IN s_bukrs
WITH p_list = 'X'
AND RETURN.
Get the list from memory.
CALL FUNCTION 'LIST_FROM_MEMORY'
TABLES
listobject = t_abaplist
EXCEPTIONS
not_found = 1
OTHERS = 2.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
Send report to mail receipent
PERFORM send_mail .
ELSE.
PERFORM select_data .
PERFORM display_data .
ENDIF.
*SO_NEW_DOCUMENT_SEND_API1
*& Form select_data
FORM select_data.
SELECT *
INTO TABLE t_t001
FROM t001
WHERE bukrs IN s_bukrs .
ENDFORM. " select_data
*& Form display_data
FORM display_data.
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
i_structure_name = 'T001'
TABLES
t_outtab = t_t001
EXCEPTIONS
program_error = 1
OTHERS = 2.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
ENDFORM. " display_data
*& Form send_mail
FORM send_mail.
DATA: message_content LIKE soli OCCURS 10 WITH HEADER LINE,
receiver_list LIKE soos1 OCCURS 5 WITH HEADER LINE,
packing_list LIKE soxpl OCCURS 2 WITH HEADER LINE,
listobject LIKE abaplist OCCURS 10,
compressed_attachment LIKE soli OCCURS 100 WITH HEADER LINE,
w_object_hd_change LIKE sood1,
compressed_size LIKE sy-index.
Fot external email id
receiver_list-recextnam = '[email protected]'.
receiver_list-recesc = 'E'.
receiver_list-sndart = 'INT'.
receiver_list-sndpri = '1'.
FOr internal email id
receiver_list-recnam = sy-uname .
receiver_list-esc_des = 'B'.
APPEND receiver_list.
General data
w_object_hd_change-objla = sy-langu.
w_object_hd_change-objnam = 'Object name'.
w_object_hd_change-objsns = 'P'.
Mail subject
w_object_hd_change-objdes = 'Message subject'.
Mail body
APPEND 'Message content' TO message_content.
CALL FUNCTION 'TABLE_COMPRESS'
IMPORTING
compressed_size = compressed_size
TABLES
in = t_abaplist
out = compressed_attachment.
DESCRIBE TABLE compressed_attachment.
CLEAR packing_list.
packing_list-transf_bin = 'X'.
packing_list-head_start = 0.
packing_list-head_num = 0.
packing_list-body_start = 1.
packing_list-body_num = sy-tfill.
packing_list-objtp = 'ALI'.
packing_list-objnam = 'Object name'.
packing_list-objdes = 'Attachment description'.
packing_list-objlen = compressed_size.
APPEND packing_list.
CALL FUNCTION 'SO_OBJECT_SEND'
EXPORTING
object_hd_change = w_object_hd_change
object_type = 'RAW'
owner = sy-uname
TABLES
objcont = message_content
receivers = receiver_list
packing_list = packing_list
att_cont = compressed_attachment.
ENDFORM. " send_mail
regards,
srinivas
<b>*reward for useful answers*</b>
Maybe you are looking for
-
Acrobat 9 Standard Update Fails
Error from Microsoft Visual C++ Runtime Library: This application has requested the Runtime to terminate in an unusual way. Please contact the application's support team for more informnation." As a result, my Acrobat Printer has disappeared so from
-
Best way to join 2 columns from table A to same column in Table B?
Hi, This is a simplified example of the query I'm trying to write. I have two tables - PIPELINE (which includes columns CREDIT_RECEIVER and CREATOR) and EMPLOYEES (which includes columns EMAIL and LOB). I want to write a query which joins PIPELINE.CR
-
There's an announcement in this story that FX Teleport for the Mac is coming in Q2. http://www.soniccontrol.com/features/article.php?ID=17 G5 Mac OS X (10.4.2)
-
Hi, Cany any one tell me with example how we will use the customccontrols in module pool program..Why it is used
-
I can't log into Adobe Business Catalyst. I always get an error.
I know I'm using the correct user name and password. I've been trying to check the status reports of the website iampjanthony.com Everytime I try to login, it gives me an error message!!! I can't figure it out. File not found (404 error) If you think