‎2013 Feb 28 3:01 PM
I made a function group ZFGROUP and function module ZFMODUL like this:
FUNCTION ZFMODUL.
*"----------------------------------------------------------------------
*"*"Local Interface:
*" EXPORTING
*" VALUE(ZFINTTBL) TYPE ZFINTTABLE
*"----------------------------------------------------------------------
select distinct *
from DFMCA_RETURN
into table ZFINTTBL
where REVENUE_TYPE = 'DNPV'.
ENDFUNCTION.
ZFINTTABLE is a table type defined in SE11. It has the same structure as DFMCA_RETURN (some table). For a test i just want to select distinct records from that table.
The module works fine when I call it from ABAP program:
*&---------------------------------------------------------------------*
*& Report ZTEST20130227
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*
REPORT ZTEST20130227.
data: X type ZFINTTABLE,
X_line like line of X.
call function 'ZFMODUL' importing ZFINTTBL = X.
data n type i.
n = 0.
loop at X into X_line.
write: / X_line-TAXPAYER, X_line-FBNUM.
n = n + 1.
endloop.
write: / 'Konec programa, število zapisov = ', n.
But when I try to use it as a base for data source, i get the error "The specified table does not exist" (see attached file).
Can anybody tell me what is wrong ?
Thanks in advance.
‎2013 Feb 28 3:24 PM
Hi Miran,
I think you are doing this development for Late Payment Interest Charges- FINT.
DFMCA_RETURN is a standard SAP Table available within R/3 SAP systems depending on your version and release level, possibly this table is accessible in you system or not it depends on some condition.
Find more on
http://help.sap.com/saphelp_nw70/helpdata/en/c1/c5b1f0db4e42ae8d8ff07b73b0c592/frameset.htm
Regards,
Arpit Varma
‎2013 Feb 28 3:31 PM
In RSO2 you must fill the 2 fields function module name AND structure for the DataSource, of course you must first click on extraction by FM and do not play with the other options...
However, the FM must have a defined signature to be allowed as Datasouce, Usually we copy the sample FM RSAX_BIW_GET_DATA_SIMPLE to customernamespace, like Z_XXXX and adapt the code.
(More information is available at help.sap.com like Maintaining Generic DataSources.)
Regards,
Raymond
‎2013 Mar 01 7:53 AM
Thank you for your answer.
Now I copied the RSAX_BIW_GET_DATA_SIMPLE module into ZFMODUL1, function group ZFGROUP. But when I try to adapt it according to intformation written in
http://help.sap.com/saphelp_crm700_ehp02/helpdata/EN/86/1c8c3e94243446e10000000a114084/content.htm
I get the message TABLE parameters are obsolete (Capture2.png) and from now on I can't edit the module anymore.
Regards
Miran
‎2013 Mar 01 8:01 AM
‎2013 Mar 01 8:09 AM
Thanks again, but when I replace SFLIGHT with DFMCA_RETURN (in the field "Associated type") ,
I get the message "TABLES parameters are obsolete". After that I am not able to save, activate nor edit the module.
Regards
Miran
‎2013 Mar 01 8:29 AM
‎2013 Mar 01 8:39 AM
ENTER did the work. Now I managed to save the data source.
Thanks a lot & regards
Miran