‎2007 Feb 22 6:43 PM
Hi forum,
in my report i am calling table maintanence using function module VIEW_MAINTENANCE_CALL for a Z table which is having 2 primary keys and rest Non key fields. Now while showing it on a screen i want to hide first column which is one of mine primary key field of a table and when user creates new entry , i want to pass value of this perticular hidden column from my z program or some routine and rest fields as per user input.
I have tried writting event 01 / 21 , it is successful in a way column gets hidden but if you enter two same records and press enter there is No error or warning is displayed for duplicate records and after saving those it results in a dump.
Can you suggest where i am going wrong.
Thanks in advance.
Message was edited by:
sharad todkar
‎2007 Feb 22 6:47 PM
Hi In YOUR PAI module do validation for the Duplicate entries.. . That's must.. Ie.
Check that the primary key combination for which u r entering new value is not present already in the table...
Caution:
Use Chain Endchain and Module on chain request to validate ... otherwise values will not change...
Hope this will help u to decipher the problem...
If u think this has helped u, reward with points
‎2007 Feb 22 6:57 PM
Thanks Darshan for prompt reply.
But the problem is little bit different, suppose there are no records as of now in a database table , and at a time i enter two records with no difference at all and when i press enter i dont get any error as generally we do get an Error saying
" An entry already exists with the same key "...so i cant check with database as none of the values are there in database as yet.
Any suggestions.
thanks
‎2007 Feb 22 7:11 PM
why don't u put a different value for the field u r hiding ... some number range for each and every record...
hope this will help..
Ashwani
‎2007 Feb 23 9:29 AM
Hi Ashwini,
What will be the exact use of passing number range , the problem is if by mistake user enters same record on SM30 for new entries, it should give error message saying duplicate entries, anyhow in my table i have total 5 fields and 3 of them are making a primary key , one of these fields is Hidden other two primary keys are on Screen only for user to make an entry, so if user enters same values for these 2 primary key columns then i am expecting an error of duplicate entries as first colmn am passing same value for every record.
I Hope i could make my requirnment clear.
Thanks,