[Custom Infotype] Maintaining field based on subtype
Hi expert,
I want to create a new subtype to store an employee's test result
Data need to be maintained are:
1. Test_type -> Subtype field
2. Person_in_charge
3. Result
4. Date.
The problem which i have is:
the result field can only be filled with certain value and specific for a subtype.
e.g:
Subtype 1 can only has result: A, B, C.
subtype 2 can only has result: D, E, F.
It's basically similar like the one on infotype 22 education where certain certificate is only applicable based on its educational establishment.
So my question is, how do you achieve above objective?
You will need to create a mapping table for you subtype and the allowed result values.
In your screen flow logic under a process on value-request. You can generate the values for your field based on the subtype.
process on value-request.
field p9xxx-zresult module result_help.
Then in the module result_help:
module sub_code_help input.
*--- Select your allowed values from your mapping table
Into table_of_results
*---- And call the function for value help..
call function 'F4IF_INT_TABLE_VALUE_REQUEST'
exporting
retfield = 'ZRESULT_CODE'
dynpprog = sy-cprog
dynpnr = sy-dynnr
dynprofield = 'T_PXXX-SUB_CODE'
value_org = c_struc
tables
value_tab = table_of_results
exceptions
parameter_error = 1
no_values_found = 2
others = 3.
if sy-subrc <> 0.
message e000(38) with 'Unable to provide Value Help'(003).
else.
Similar Messages
-
Add new loop field in custom infotype - error field .. not assigned to loop
Hi,
I have a task of adding a new loop field in a custom infotype screen 3000. Here, in the past there have only been the fields begin date and end date. I need to add a new field, so this is how I proceeeded:
1) I modified the screen 3000 in SE38, adding the field where I wanted and defining a loop.
Now, I get the syntax error : Field P9500-field is not assigned to a LOOP. LOOP...ENDLOOP must appear in PBO and PAI.
There must be something wrong in what I'm doing, can you please let me know a quick fix on this or how I can accomplish this in PM01? Please keep in mind that this is a custom infotype for SAP TEM, I can't see it in PA.
Best regards,
GeorgeNot a nice solution but I had to do this quick and I'll correct it in the next days:
The old flow logic PBO code was:
LOOP.
MODULE FILL_DYNPRO.
ENDLOOP.
If I wanted to insert here something like:
FIELD whatever
MODULE dummy.
, I'd get stupid error messages like this other field is not in loop, endloop, then if I put that other field I'd get the error that the fields are in the same loop...
Wanting just to get this over with, I added the following code (after the initial loop):
LOOP.
FIELD whatever
MODULE FILL_DYNPRO."same module as above
ENDLOOP.
This was repeated in PAI.
This pretty much works out fine for the moment, I'll look for finer solutions in the week to come.
Thanks for the help, guys.
Best regards,
George -
Hi all,
My requirement is to Create Custom Infotyp 9100 with two new subtypes(9001 & 9002).
Subtype 9002 will pick up relationship data from the subtype of Infotype 0021
IT9801 u2013 Subtype 9001
PERNR EmpNo NUMC 8
ZISNo Serial No NUMC 4
VORNA First Name In Passport CHAR 25
NACHN Last Name In Passport CHAR 25
MIDNM Middle Name In Passport CHAR 40
IT9801 u2013 Subtype 9002
PERNR EmpNo NUMC 8
ZISNo Serial No NUMC 4
VORNA First Name In Passport CHAR 25
NACHN Last Name In Passport CHAR 25
MIDNM Middle Name In Passport CHAR 40
SUBTY Relationship Serial No CHAR 4
The field SUBTY should display as drop down by picking up the subtypes related to Infotype 0021 from the table T591A
Can you please provide ur inputs as this is very urjent requirement .Step by step procedure will be of great help.
Thanks in advance.Transaction to create an infotype is PM01. See online help there.
You have to create the PS structure first (SE11). This structure containms the fields, look at existing infotype for example.
hope it helps. -
Subtype ERROR in Custom infotype
Hi,
i have created a custome infotype.
i have assigned a subtype for the same.
but it is not working.
when i press F4 in subtype field error is displayed.
ERROR MESSAGE is " infoytpe xxxx not supported".
regards
thiruI am also facing the same problem .
Can anybody tell how to remove this error.
Thanx
Prabhati -
Module pool F4-Help problem for a field in custom Infotype(HR).
Dear Gurus,
I have created a custom Infotype and fields are like
P9015-NAM01.
P9015-NAM02.
P9015-NAM03.
all are fields for name.
I want F4 help for these fields with values same as Family Members-First name given in 21 Infotype .
for all 3 fields same f4 help values.
But when i see in the screen for first field the values are populating as selected but for second field the selected value is not picking..
DATA: BEGIN OF it_val1 OCCURS 7,
nam01 LIKE p9015-nam01,
rel01 LIKE p9015-rel01,
END OF it_val1.
SELECT * FROM t591s INTO TABLE it_t591s WHERE
sprsl = 'EN' AND
infty = '0021'.
*SUBTY
*STEXT
SELECT * FROM pa0021 INTO wa_21 WHERE pernr = p9015-pernr .
READ TABLE it_t591s WITH KEY subty = wa_21-famsa.
it_val1-rel01 = it_t591s-stext.
CONCATENATE wa_21-favor wa_21-fanam INTO it_val-nname SEPARATED BY space.
it_val1-nam01 = wa_21-favor.
APPEND it_val1.
CLEAR : it_val1, it_t591s.
ENDSELECT.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
DDIC_STRUCTURE = ' '
retfield = 'NAM01'
PVALKEY = ' '
dynpprog = sy-cprog
dynpnr = sy-dynnr
dynprofield = 'P9015-NAM01'
STEPL = 0
WINDOW_TITLE =
VALUE = ' '
value_org = 'S'
multiple_choice = ' '
display = 'F'
CALLBACK_PROGRAM = ' '
CALLBACK_FORM = ' '
MARK_TAB =
IMPORTING
USER_RESET =
TABLES
value_tab = it_val1[]
field_tab = t_fields[]
return_tab = t_return[]
DYNPFLD_MAPPING = t_DYNPFLD_MAPPING
EXCEPTIONS
PARAMETER_ERROR = 1
NO_VALUES_FOUND = 2
OTHERS = 3
In the same way i am calling for P9015-NAM02. & P9015-NAM03.
Is there any wrong in calling this FM...kindly help.....Write the FM inside,
at selection-screen on value-request for <nam1>.
It seems that you are calling the funtion module for only first field. Repeat it for other two fields also-
at selection-screen on value-request for <nam2>
call FM.
at selection-screen on value-request for <nam3>
call FM.
Sumit -
Time Constraint assignement to PD infotypes based on Subtypes.
Hello All,
Is there a way to assign Time contraint to PD infotype like 1005 based on Subtypes? If so how can we do this? I tried in table T591A but I guess this table is only for PA infotypes.
Thanks,
Chakri.Hi,
Goto to sm30 and give T777I. There choose your infotype and click the time constraint. You can give the subtype and time constraint.
Balaji -
Error while creating a query for my custom infotype
Hi,
I have created a custom infotype with fields currency amount and currency field .
While I am creating a query for it its giving an error
Message no. AQ_AD_HOC221 Error when generating the report(see long text )
I tried to execute the standard program RPUMS40CCI but still I am facing same error .
I have also maintained table T777i for my infotype but still problem exists.
Please help.
PHi
Check in PM01 -
HR ABAP : Custom Infotype updations through FM HR_INFOTYPE_OPERATION
Hi All,
Actually, I want to update the custom infotype 3 fields as per my user inputs. I am fetching the data from the PA table acoording to sy-datum falling in the begda, enda limitations. now I am changing the field with new values in the work area. And pass with the following data to the FM.
But I am getting the error 'No data stored for 9008 in the selected period', eventhough it is already having a data in the database table. I had seen prvious therads, but could not get how they solved the issue.
Please provide the inpus for the following code.
( I had also passed the validity start and end from the database entry. at this moment it gets dumped at the statement
assign record to <record> casting type (tabname). "XDP UniCode
where tabname is proposed from t777d-ppnnn. which is a structure and having a value as P9008. If i change the value at debug point to PA9008. it works fine. is there anything extra i need to do to solve this issue? )
CALL FUNCTION 'HR_INFOTYPE_OPERATION'
EXPORTING
infty = '9008'
number = pernr
"SUBTYPE =
"OBJECTID =
"LOCKINDICATOR =
"VALIDITYEND =
"VALIDITYBEGIN =
"RECORDNUMBER =
record = wa_pa9008
operation = 'MOD'
"TCLAS = 'A'
"DIALOG_MODE = '0'
"NOCOMMIT =
"VIEW_IDENTIFIER =
"SECONDARY_RECORD =
IMPORTING
return = l_bapireturn
key = bapipakey_tab
Regards,
Brijesh PatelHi,
Check this code once
Read Infotype9004 Record for the personnel No
CALL FUNCTION 'HR_READ_INFOTYPE'
EXPORTING
tclas = A
pernr = pernr
infty = 9004
IMPORTING
subrc = v_subrc
TABLES
infty_tab = it_pa9004
EXCEPTIONS
infty_not_found = 1
OTHERS = 2.
Read it_pa9004 into wa_pa9004 with some condition.
if sy-subrc eq 0.
Lock the employee for processing infotype 9004
CALL FUNCTION 'HR_EMPLOYEE_ENQUEUE'
EXPORTING
number = wa_pa9004-pernr.
v_begda = wa_9004-begda.
v_endda = wa_9004-endda.
CALL FUNCTION 'HR_INFOTYPE_OPERATION'
EXPORTING
infty = c_9004
number = wa_9004-pernr
subtype = c_0001
validityend = v_endda
validitybegin = v_begda
record = wa_9004
operation = c_mod
tclas = c_a
dialog_mode = c_0
dialog_mode = '2'
IMPORTING
return = wa_return.
CALL FUNCTION 'HR_EMPLOYEE_DEQUEUE'
EXPORTING
number = wa_pa9004-pernr.
endif.
reward the points if it is helpful.
Regards,
Srilatha -
HR ABAP : Custom Infotype updations
Hi All,
I am new to HR ABAP. Actually, I want to update the custom infotype 3 fields as per my user inputs. I am fetching the data from the PA table acoording to sy-datum falling in the begda, enda limitations. now I am changing the field with new values in the work area. And pass with the following data to the FM.
But I am getting the error 'No data stored for 9008 in the selected period'. I had seen prvious therads, but could not get how they solved the issue.
Please provide the inpus for the following code. I had also passed the validity start and end.
CALL FUNCTION 'HR_INFOTYPE_OPERATION'
EXPORTING
infty = '9008'
number = pernr
SUBTYPE =
OBJECTID =
LOCKINDICATOR =
VALIDITYEND =
VALIDITYBEGIN =
RECORDNUMBER =
record = wa_pa9008
operation = 'MOD'
TCLAS = 'A'
DIALOG_MODE = '0'
NOCOMMIT =
VIEW_IDENTIFIER =
SECONDARY_RECORD =
IMPORTING
return = l_bapireturn
key = bapipakey_tab
Regards,
Brijesh PatelHi Remi,
I have done the same thing. Please see the code. data is also available in the database. But the output is the error message. Please give some inputs on this.
***Updation of the PA9003 Infoty pe with the LTA amount and Medical Amount
SELECT SINGLE endda
begda
FROM pa0001
INTO (endda, begda)
WHERE pernr EQ pernr
AND endda GE sy-datum
AND begda LE sy-datum.
SELECT SINGLE *
FROM pa9003
INTO lwa_pa9003
WHERE pernr EQ pernr
AND endda >= sy-datum
AND begda <= sy-datum.
wa_pa9003 = lwa_pa9003.
wa_pa9003-zzallw = zzallw.
wa_pa9003-zzlta = zzlta.
wa_pa9003-zzmed = zzmed.
ADD 1 TO wa_pa9003-seqnr.
***Locking the object
CALL FUNCTION 'ENQUEUE_EPPRELE'
EXPORTING
pernr = pernr
EXCEPTIONS
foreign_lock = 1
system_failure = 2
OTHERS = 3.
CALL FUNCTION 'HR_INFOTYPE_OPERATION'
EXPORTING
infty = '9003'
number = pernr
subtype = wa_pa9003-subty
objectid = wa_pa9003-objps
lockindicator = wa_pa9003-sprps
validityend = wa_pa9003-endda
validitybegin = wa_pa9003-begda
recordnumber = wa_pa9003-seqnr
record = wa_pa9003
operation = 'MOD'
TCLAS = 'A'
DIALOG_MODE = '0'
nocommit = space
VIEW_IDENTIFIER =
SECONDARY_RECORD =
IMPORTING
return = l_bapireturn
key = bapipakey_tab
***Unlocking the object
CALL FUNCTION 'DEQUEUE_EPPRELE'
EXPORTING
pernr = pernr.
Regards,
Brijesh Patel -
Regarding Updation of Custom info type fields
Hi All,
I am new to HR ABAP. Actually, I want to update the custom infotype 3 fields as per my user inputs. I am fetching the data from the PA table acoording to sy-datum falling in the begda, enda limitations. now I am changing the field with new values in the work area. And pass with the following data to the FM.
But I am getting the error 'No data stored for 9008 in the selected period'. I had seen prvious therads, but could not get how they solved the issue.
Please provide the inpus for the following code. I had also passed the validity start and end.
CALL FUNCTION 'HR_INFOTYPE_OPERATION'
EXPORTING
infty = '9008'
number = pernr
SUBTYPE =
OBJECTID =
LOCKINDICATOR =
VALIDITYEND =
VALIDITYBEGIN =
RECORDNUMBER =
record = wa_pa9008
operation = 'MOD'
TCLAS = 'A'
DIALOG_MODE = '0'
NOCOMMIT =
VIEW_IDENTIFIER =
SECONDARY_RECORD =
IMPORTING
return = l_bapireturn
key = bapipakey_tab
Regards,
Brijesh PatelCan anyone please provide inputs on this???
-
Custom Infotypes and Change History
HR Gurus,
I am being told that with custom infotypes, we can not track change history.
THe scenario I have is that I need to be ableto capture Address Changes (Address Line 1, Address Line 2, City, State and Zip) and send a Delta for the changed address.
In my unique situation, I have been told that if Address Line 2 is deleted, than the change histiry can not capture the fact that it was deleted and all change history regarding its prior existnace will be deleted if the Address Line2 is removed.
I am not entirely sure=, but I wanted to ask you guys anyway if I woukd be able to track Change history.
-FerozHi Feroz,
Do not believe everything you hear. You can view changed and deleted information from custom infotypes and fields.
First, I am not sure why you need a custom infotype for addresses when IT0006 is available to you. You can more easily create a custom subtype if the supplied ones do not meet your needs.
But for any PA infotype including custom infotypes, you can use the Logged Changes to infotype Data report (RPUAUD00). You have to set up the infotype to be logged in the IMG: Personnel Management --> Personnel Administration --> Tools --> Revision --> Set Up Change Document. In the first section, you list the infotypes you want to track changes for including your custom infotype. In the second step you list the fields you want to track. "*" means any change to any field. And in the third step you indicate whether the information is kept as a long term or short term document.
When you run the report, you can enter the infotype and period you want and the first list will be all changes to that infotype. Select one to view the details and you will see each field listed with the original data and the new data. If a field is deleted, it will appear blank in the new area, but you can still see the old entry in the previous data column.
Also, if an individual deletes a entry in an infotype by using Copy and enters in a new start date, the old record will be delimited, but still be available for viewing. Also, every infotype records who made changes and the date of the change.
Paul -
Search help on custom infotype
Hi Experts,
I create custom infotype with field PLANS and others.
I have problem on search help (F4) on field PLANS,
I want to get structural list of position ( like attach file example2.png), not like this in attached file example1.png.
Could you please help me resolve this problem.
Thank you, MijaHi Mija,
The following FM will return you the hierarchical list of any HR Object type that you specify.
CALL FUNCTION 'RH_OBJID_REQUEST_46A'
EXPORTING
plvar = '01'
otype = 'S'
IMPORTING
sel_object = ls_objec
EXCEPTIONS
cancelled = 1
wrong_condition = 2
nothing_found = 3
illegal_mode = 4
internal_error = 5
OTHERS = 6.
I use this for 'F4 Help' in the selection screens of my report programs. But, to have it at the table level, you need to create a Search help and attach it to the particular field of the Custom Infotype table. -
Pop up message in custom infotype screen
Hi Expert,
I have one custom infotype with field zzdest ( destination airport) which show all destination airport like mumbai,delhi etc.this
airpot are mainatin in an ztable ZR_HR_DES. while user selecting destination some name will be wrong like mumbay instead of mumbai in the custom table at that time it should show the pop up message that please select mumbai instead of mumbay.
can any one suggest me how to do this.
Regards,
MdadduWhen user give a text that is not in your table, you may try to fill an internal table with similar text and then use this internal table in a popup select FM like REUSE_ALV_POPUP_TO_SELECT.
Some way to fill the internal table
- with leftmost part of the name removing rightmost character until you get some records (remove right most character and add wildcard til select returns some records) (will identify incomplete text or error at rightmost characters)
- converting erroneous input to a range replacing every character by a wildcard (DO length(str)/replace sy-tabix character by wildcard and append to a range) (identify a single mistake on a character)
- wait til SAP implements a [Levenshtein distance|http://en.wikipedia.org/wiki/Levenshtein_distance] rule in SQL...
Remarks: why don't you use an "official" airport code like ICAO or IATA to identify an airport, a text like "Bombay", "Mumbai", "Sahar" or even "Chhatrapati Shivaji" can refer to the same airport, and many cities have more than one airport (eg. Juhu for small private aircraft)
Regards,
Raymond -
Who's who Infoset : Adding a custom infotype
Dear Experts,
I am in need of your valuable input on Who's who.
Can we include custom infotype (9000) fields to the infoset (by coping into a custom infoset)?
What is configuration needs to be done on portal side to enable the additional fields.
I know to add / remove the fields which are already provided ( from infotype 0,1,2,105 and 32)
Awaiting your response.
Cheers
JayHi,
Yes you can surely include your custom Infotypes in the Infoset for Who's Who.
There is no need for doing any Java customization unless you want to have a hyperlink and other kind of things for the additional fields.
If you want to show some content from the custom infotype and have a hyperlink to take you to some other location or application in that case you need to do the Java changes.
In all other cases change in the config will suffice.
In the ECC system go to t.code SPRO
Navigate to Personnel Management - Employee Self-Service - Service-Specific Settings - Address book - Who's Who - Who's Who (ESS) : Selection and Output - select the country and replace the standard Infoset with your custom infoset.
Hope this helps.
Cheers-
Pramod -
Calling a custom Infotype field in Time Management PCR
Dear All,
I need to read a custom Infotype field in TM PCR to read the individual leave entitlement. In my organization there is no employee group wise or Personnel Area wise fixed entitlements for leave. Leave entitlement varies individual to individual based on the contract. We are planning to maintain the individual annual entitlement in a custom infotype n then call this information in PCR to accrue the prorated quota each month.
Is there any standard operation available which can be used to read a custom infotype field or do we need to create a custom operation or function. If so, kindly let me know how to create them.
Appreciate your early response.
Thanks & Regards
SyedSyed,
I am not really sure about it. What I can tell you is that there is standar operation TABLE that is use to read fields from infotype. You may use that operation as a base or maybe just create some enhancement on it (I really don´t if that is possible). Check with your ABAP and have a look on operation table.
Regards,
Edoardo
Maybe you are looking for
-
Mac OS X10.8.5 Firefox crashes- Not responding
Hello. Firefox accessed from doc & from Finder is not responding. Toolbar & FF (Firefox) browser window slowly opens to white unaccessible browser screen. Must force quit to close FF. Tested FF with different user on same computer and it works fine.
-
I tried to search through Apple's website for Mac Mini's installed Bluetooth Specifications but couldn't find the information I need. Can someone help to answer the following questions? 1)Does the installed BT card support Bluetooth 2.0 + EDR? If not
-
I downloaded a data usage file from my cell carrier website. Instead of being a spreadsheet fie it had the suffix action. What is that? When I clicked it Automator wanted to know if I wanted to install it. I clicked install and it crashed. I ope
-
Similar to MS Office, one can position all the menu bars in any order, top down or sideways as required. I find that with ver 4, the tabs on the top line , the search, home buttons etc are not intuitive and are quite annoying with their positional ch
-
Using forall and bulkcollect together
Hey group, I am trying to use bulk collect and forall together. i have bulk collect on 3 columns and insert is on more than 3 columns.can anybody tell me how to reference those collection objects in bulk collect statement. you can see the procedure,i