Copy/create program with logical database
Hi
I need to create a program with the same selection-screen as SAP standard program RPRAPA00.
RPRAPA00 is using a logical database, but even that I have passed in the PNP in the attributes of my own progam, I don't get the selection in the top (buttons, key-date info + selection info).
The rest of my program looks fine.
Any ideas how I get the missing selections into the selection-screen?
Hi,
Define pernr table under tables statement then and use GET PERNR event.This get event is followed by End-Of-Selection.
Syntax: Tables pernr.
Get pernr.
Try, activate and test. This should solve your problem.
Regards,
Abhijeet
Similar Messages
-
How does works default parameters in a program with logical database PNP?
Hi Friends,
I have a basic program, i need to filter info with period parameters in a program that uses logical database PNP, but it doesn't work.
If i use "person selection period" that it's suposed to filter info according to infotype 0001 (as the sap help says), it doesn't work, i use: PNPBEGPS = today and PNPENDPS = today, and the result it's a lot of registers that doesn't meet that criteria.
Also i tried with: data selection period, today, up to day, current month. And the result it's with the same problem.
How does works period parameters in a program with logical database PNP?
This it's the program example, i use the default category.
REPORT ZRPHRTEST.
tables: pernr.
infotypes: 0001.
start-of-selection.
get pernr.
write: pernr-pernr, p0001-begda, p0001-endda.
end-of-selection.
write 'fin'.Hi,
Define pernr table under tables statement then and use GET PERNR event.This get event is followed by End-Of-Selection.
Syntax: Tables pernr.
Get pernr.
Try, activate and test. This should solve your problem.
Regards,
Abhijeet -
Calling standard program with logical database
Hi all,
I am trying to call a standard report (RPTBAL00) from a custom program without displaying the selection screen. I want to fill some of the select-options programmatically.
My code is somethig like this
submit RPTBAL00
with pernr-pernr = 'XXX'
with pernr-pnpbegda = '20020101'
with pernr-pnpenddaa = '99991231'
and return.
but the report gets called with defaults.
Does anyone know what I am doing wrong?Hi
I seem your code is right, but I don't understand which elements are filled with default values.
Anyway this is a little code to submit a report with logical database:
Co.Ge.
loop at so_umskz.
move-corresponding so_umskz to selopt.
append selopt to frange-selopt_t.
endloop.
if sy-subrc = 0.
frange-fieldname = 'UMSKZ'.
append frange to range-frange_t.
endif.
refresh frange-selopt_t.
loop at so_zlsch.
move-corresponding so_zlsch to selopt.
append selopt to frange-selopt_t.
endloop.
if sy-subrc = 0.
frange-fieldname = 'ZLSCH'.
append frange to range-frange_t.
endif.
if not range-frange_t[] is initial.
range-tablename = 'BSIK'.
append range to trange.
call function 'FREE_SELECTIONS_RANGE_2_EX'
exporting
field_ranges = trange
importing
expressions = texpr.
endif.
submit rfitemap
with ................
with free selections texpr and return.
Max -
HR - Programming without Logical database
Hi All
I have some doubts, I am mainly using Logical database while creting Reports in HR, if I want to use HR function modules and BAPI do they use logical database,
question is when we have to do HR programming with Logical database and when without Logical database.
cheers
AJHi Srinivas
If I am doing some Enhancement on ESS/ MSS , using Webdypros, I cant define Logical database anywhere, so I have to use Function modules or BAPIs ........???
But usually in Reporting you can define the Logical database in the Program attributes.........so I think Logical database can only be used when it can be defined in the program attributes........if you have any other scenarios........please let me know
regards
AJ -
Dear all,
While creating SQVI with logical database ( PNPCE - HR Master Record ), I found error at the time of saving
"Global syntax check
-> Selection Criteria
-> Error in parameter PYPARAID
-> Statement concluding with "...TYPE" ended unexpectedly. "
Please Help.
-MaharshiHello,
SQ02 Infoset Query
hope its helps -
Problem with Logical Database DDF
Hey All,
I have a problem with Logical Database DDF.
In my program I am typing this
GET KNA1 based on selection screen. It is bringing back everything I want except BRAN1 whereby the field is ''. However in SE16 for KNA1 and for the same KUNNR, the field is populated with 'T180'
I am not understanding this?! I thought LDB where menat to make things easy!!I think it's not used by DDF.
so you must check it with:
check kna1-bran1 in s_bran1.
A. -
Is it possible to create report with two databases in Web Analysis Studio
Hi,
I am new to Hyperion Web Analysis, Could anyone help me out, whether its possible to create report with two databases for eg: OLAP(ESSBASE) and relational.
Thanks & Regards,
Prashanthi.Hi Mohit,
Thanks for the reply, could you throw out some scenario so that i can try it out.As I am just trying my hands wet on this would like to know in detail & even i have gone through WA user guide but dint get any clue. Please throw some light.
thanks
prasanthi -
ABAP Objects and table processing (with logical databases)
I have a report that is written right now using procedural abap and a logical database. The report is structured follows (high level):
start-of-selection.
get pernr.
perform get_it0001 using wtab.
perform get_it0002 using wtab.
perform get_it0003 using wtab.
append wtab to itab.
end-of-selection.
call function 'reuse_alv_grid_display'
exporting
i_structure_name = 'itabstructure'
tables
t_outtab = itab.
So basically I'm going through a bunch of personnel numbers, getting a few infotypes and outputting to ALV. I don't see where ABAP Objects is going to help me for this particular program.
Can somebody show me where OO ABAP would make this easier? Does it even make sense to use OO when you're processing with a logical database? (Not just PNP, but any logical database in general).
Thanks in advance.Hello Lee
I assume that the routines GET_ITnnnn are written by yourself. For reading infotypes ABAP Objects provides us with same very helpful classes as shown below:
* define data
DATA:
gif_employee type ref to if_pt_employee,
go_employee type ref to cl_pt_employee,
gt_infotypes TYPE tim_tmw_itlist_tab,
go_control TYPE REF TO if_pt_td_control,
go_data TYPE REF TO if_pt_td_base,
go_pnnnn TYPE REF TO if_pt_td_itnnnn,
gt_p0001 TYPE TIM_P0001_TAB,
gt_p0002 TYPE TIM_P0002_TAB,
gt_p0003 TYPE TIM_P0003_TAB.
start-of-selection.
GET pernr.
<b>* Create employee instance</b>
gif_employee = cl_pt_employee=>get_employee( pernr ).
go_employee ?= gif_employee.
<b>* Get master infotypes (0001, 0002)</b>
CALL METHOD go_employee->get_master_data
EXPORTING
im_begda = id_fromdate
im_endda = id_todate
IMPORTING
* EX_I0000 =
EX_I0001 = gt_p0001
EX_I0002 = gt_p0002
* EX_I0007 =
* EX_I0008 =
<b>* Append all other required infotypes to itab</b>
APPEND '0003' TO gt_infotypes.
CALL METHOD go_employee->get_infotypes
EXPORTING
i_itlist = gt_infotypes
i_fromdate = id_fromdate " start date
i_todate = id_todate " end date
* I_FILTER =
i_noauthcheck = 'X'
IMPORTING
e_result = gt_infty_request
e_retcd = gd_retcd.
* Please see documentation of parameter e_retcd...
LOOP AT gt_infty_request INTO go_control.
go_data = go_control->data. <b>" get data object</b>
* Casting
TRY.
go_pnnnn ?= go_data.
CATCH cx_sy_move_cast_error.
CONTINUE.
ENDTRY.
<b>* Convert infotype (semi-transparent -> transparent)</b>
CALL METHOD cl_hr_pnnnn_type_cast=>prelp_to_pnnnn
EXPORTING
prelp = lo_pnnnn->prelp
IMPORTING
pnnnn = gs_p0003.
APPEND gs_p0027 TO gt_p0003.
ENDLOOP.
The class CL_PT_EMPLOYEE provides us already with very easy access to so-called master infotypes (000, 0001, 0002, 0007 and 0008). All other infotypes can be read using method GET_INFOTYPES.
Using these classes we have a very convenient and standardized way of accessing all kinds of infotypes.
Regards
Uwe -
Report Parameters with logical database
Hello
I have to read some HR infotypes that are provided with the logical database PNPCE.
Fort his i have written a report that will use my logical database and get some information.
What i need,are some new input parameters on the screen that are added by my report:
parameters: p_persnr type person-pernr,
p_name type p0002-nachn,
p_sname type p0002-vorna.
The problem is that i do not know how to link these parameters to my logical database reading.
When i try to call "get <node>" ,my report is not returning anything.
Is there a way to send my parameters as selection parameters to the logical database?
thank youThe selection screen 1000 is created dynamically during runtime. I doubt change done by SE51 will solve the issue. In fact there is some code which can help on this.
INITIALIZATION.
To restrict the range of PERNRs
PERFORM z_seloption_restrict USING 'PNPPERNR'.
*& Form Z_Seloption_Restrict
* Restrict range in select option
* -->VALUE(SOP_NAME) Name of select option as string
FORM z_seloption_restrict USING value(pv_sop_name).
IF st_restrict-opt_list_tab[] IS INITIAL.
CLEAR st_opt_list.
MOVE: 'EQ' TO st_opt_list-name,
'X' TO st_opt_list-options-eq.
APPEND st_opt_list TO st_restrict-opt_list_tab.
ENDIF.
REFRESH : st_restrict-***_tab.
* READ TABLE st_restrict-***_tab INTO st_asst
* WITH KEY name = pv_sop_name.
* IF sy-subrc NE 0.
CLEAR st_asst.
MOVE: 'S' TO st_asst-kind,
pv_sop_name TO st_asst-name,
'I' TO st_asst-sg_main,
' ' TO st_asst-sg_addy,
'EQ' TO st_asst-op_main.
APPEND st_asst TO st_restrict-***_tab.
* ENDIF.
CALL FUNCTION 'SELECT_OPTIONS_RESTRICT'
EXPORTING
restriction = st_restrict.
ENDFORM. "Z_Seloption_Restrict -
Selection screen for HR report with logical database PNP
Hi All,
I am writing a HR report. And I use the logical database PNP. Also I create a HR report category for this report. In the report category, I can define the selection screen field. But all these fields are selection option format. My question is How can I add parameters, radiobutton group and checkbox in the selection screen. Thanks.
AlexHi Alex,
Sorry for replying so late. Please try this tutorial:
w w w. s a p t e c h n i c a l. c o m -> tutorials -> ABAP-HR -> Creating HR Report category in PNP logical database
Sorry, I put it like this, because direct link doens't let me post the answer. Don't know why.
It can also be something with your custom code in selection screen. Though it works fine for, try to remove COMMENTs and observe the result. Maybe parameters are overlapping somehow. First try this:
SELECTION-SCREEN begin of BLOCK blk2 WITH FRAME TITLE text-002.
PARAMETERS RefDate type DATS.
parameter BFlag type c RADIOBUTTON GROUP grp1.
PARAMETER FFlag type c RADIOBUTTON GROUP grp1.
parameters days type i.
PARAMETERS spvsr like PA0001-MSTBR.
selection-SCREEN end of BLOCK blk2.
If that works together with the report category, try to extend it with adding a selection-screen comment, but do this in reversed order (comment goes first and FOR FIELD addition is supplied) like this:
SELECTION-SCREEN begin of BLOCK blk2 WITH FRAME TITLE text-002.
PARAMETERS RefDate type DATS.
SELECTION-SCREEN begin of line.
SELECTION-SCREEN COMMENT 3(10) text-003 for field bflag. "FOR FIELD, and goes first
parameter BFlag type c RADIOBUTTON GROUP grp1.
SELECTION-SCREEN COMMENT 16(10) text-004 for FIELD fflag. "here two
PARAMETER FFlag type c RADIOBUTTON GROUP grp1.
SELECTION-SCREEN end of line.
parameters days type i.
PARAMETERS spvsr like PA0001-MSTBR.
selection-SCREEN end of BLOCK blk2.
If still not working, see if text-003 and text-004 are not too long (you expect them to be 10 chars), This may somehow affect selection screen.
You may also try with setting cursor position explicity by:
SELECTION-SCREEN begin of line.
SELECTION-SCREEN POSITION 3.
SELECTION-SCREEN COMMENT (10) text-003 for field bflag.
parameter BFlag type c RADIOBUTTON GROUP grp1.
SELECTION-SCREEN POSITION 16.
SELECTION-SCREEN COMMENT (10) text-004 for FIELD fflag. "here two
PARAMETER FFlag type c RADIOBUTTON GROUP grp1.
SELECTION-SCREEN end of line.
It is really hard to identify where can be a bug as it is working fine for me. Keep trying with different variations, it should finally run with some.
Regards
Marcin -
Problem with logical database DDF in ABAP query
Hi All,
I have created an ABAP query via the transaction SQ01 using the logical database DDF to retrieve customer master data from tables KNA1 & KNB1. The selection screen used is the screen 903 of the logical database DDF. But now the problem is that when I execute the query, I am getting a blank value in the tax code4(KNA1-STCD4) field though there is value in the KNA1 table for this particular field. This field was added to the table by means of a customizing include. Can anyone suggest a way to get around this problem so that I can view the content of the field STCD4 in the query.
Thanks and regards,
Sarath.I think it's not used by DDF.
so you must check it with:
check kna1-bran1 in s_bran1.
A. -
Problem with logical database ADA
I am trying to create query with asset values and master data fields but when trying to use logical database ADA I am getting error No component exists with the name "VALUE0". .InfoSet Cannot be Used for InfoSet Query.
Does anyone have an idea about such problem?Hi,
The message "No component exists with the name "VALUE0"" created when you omit to edit the field group only happens if no field is assigned to a fieldgroup, it should not appear if you add at least one field to a field group.
regards Bernhard -
RMAN Connections To Primary DB While Creating Standby With Active Database
OS Version : AIX 6.1
DB Version : 11.2.0.1
I am creating a standby database with active database option (without any backups). When i am checking number of connections in my primary database, i can see 3 rman connections
from the standby machine. How oracle reaches to a conclusion of 3 sessions ? Is this number fix or this number can be manipulated with requirment ?
SQL> select sid,serial#,program from v$session;
SID SERIAL# PROGRAM
1 1 oracle@cph-core-db01-s (DIA0)
2 1 oracle@cph-core-db01-s (MMNL)
3 1 oracle@cph-core-db01-s (QMNC)
32 1 oracle@cph-core-db01-s (MMAN)
33 1 oracle@cph-core-db01-s (DMON)
34 3 oracle@cph-core-db01-s (Q000)
63 1 oracle@cph-core-db01-s (PMON)
64 1 oracle@cph-core-db01-s (DBW0)
65 3 sqlplus@cph-core-db01-s (TNS V1-V3)
66 10 oracle@cph-core-db01-s (Q001)
94 1 oracle@cph-core-db01-s (VKTM)
SID SERIAL# PROGRAM
95 1 oracle@cph-core-db01-s (LGWR)
96 3 oracle@cph-core-db01-s (INSV)
*97 27 rman@cph-core-db02-s (TNS V1-V3)*
125 1 oracle@cph-core-db01-s (GEN0)
126 1 oracle@cph-core-db01-s (CKPT)
127 3 oracle@cph-core-db01-s (ARC0)
*129 18 rman@cph-core-db02-s (TNS V1-V3)*
156 3 oracle@cph-core-db01-s (ARC1)
157 1 oracle@cph-core-db01-s (DIAG)
158 1 oracle@cph-core-db01-s (SMON)
159 12 oracle@cph-core-db01-s (SMCO)
SID SERIAL# PROGRAM
187 1 oracle@cph-core-db01-s (DBRM)
188 1 oracle@cph-core-db01-s (RECO)
189 1 oracle@cph-core-db01-s (ARC2)
192 2 oracle@cph-core-db01-s (W000)
218 1 oracle@cph-core-db01-s (PSP0)
219 1 oracle@cph-core-db01-s (MMON)
221 1 oracle@cph-core-db01-s (ARC3)
*222 3 rman@cph-core-db02-s (TNS V1-V3)*Check for the RMAN parallelism in standby database it might be set to 3.
RMAN> show all;
or
Might be you had allocated 3 channels while executing active standby database query. -
Optimization with logical database
Hi all.
I have to optimize a report, and it is using BRM logical database to get data from BKPF and BSEG. Could you say to me if it is the faster way or if it would be better to use a SELECT?
Thanks a lot.
Marta.Hello Marcin,
Once I met with statement that good ABAPers don't use direct SELECT statement, at least they shouldn't have to.
What?? This might be true for HR ABAP, where LDBs are used in abundance
There are so many standard FMs which cover most of SAP db queries.
Most of these std. FMs are generally "not released" & are not performance friendly either.The "released" BAPIs (BAPIGET) don't cater to all your requirements.
I seldom use FMs to fetch the data. I find it easy to implement relevant authority objects & build an optimised SQL construct as per my requirement
Let me know your comments.
BR,
Suhas -
Users are creating programs with accesskey
Hi
Suppose if the users are created programs (non z & y) with access key how to get the list of these programs.hi Kiran,
go to table ADIRACCESS, where you'll find each object where access key was entered. In table TADIR you can check for these objects if AUTHOR is SAP or someone else (that means a user).
hope this helps
ec
Maybe you are looking for
-
Does the inability to forward mail from the new In...
(1) Am I right in believing that simply by opening an email you can pick up a trojan or other nasty? That's what I've always heard. (2) Am I also right in saying that we can no longer 'forward' an email when viewing the list of 50 emails in the Inbox
-
hi We are getting the following sql statement dump, and i am not able to understand what should be done here, would anyone please advise Registered qb: SEL$1 0xc4c8a150 (PARSER) QUERY BLOCK SIGNATURE signature (): qb_name=SEL$1 nbfros=1 flg=0 fro(0):
-
HT4759 icloud grayed out on ipad2
my icloud if grayed out on my ipad cant figure out why?
-
Apple should flex some securities they are not neccessary at all
How to enable whatsapp calling feature on whatsapp guys...help mi...is it posible i think if not then iphone is the waste phone ever for real...
-
Non-Residence Tax - Withholding
I am preparing masterdata setup to do functional testing on TUB # 197. Within SAP, how do you set up the masterdata to test out Non-Residence Tax? Specifically, How do you get a township's withholding to pass to BSI? How should the deduction be setu