‎2014 Oct 08 6:09 PM
Hi,
A field type has changed from NUMC(3) to NUMC(4) in an active database table with data already.
Now coexits boths values with and without leading 0. Example: 101 and 0101.
How is it possible?
Already adjust the table but with no effect.
I suppose that just one value was possible: 0101!
Can you explain please?
Thanks.
Regards,
Maria João Rocha
‎2014 Oct 09 7:52 AM
Hi Maria,
try SE14 with Menu Extras -> Force Conversion
Regards,
Klaus
‎2014 Oct 08 7:43 PM
Hi Maria
I am expecting that the data base table was adjusted using the database utility (SE14).
Once that is done, the old values remain (in your case 101) and you can enter new values (0101). They both are treated differently.
As we use conversion exists to add/remove additional characters on the field to fetch them from the table.
Hope this helps.
Harsh
‎2014 Oct 09 9:21 AM
Hi,
As I said, the adjut was made (SE14), but the old entries (without the leading 0) persist.
Regards,
Maria João Rocha.
‎2014 Oct 08 9:45 PM
Hi Maria,
Please write one time program to convert the old value without leading zero's to with leading zeroes. This once time program is must necessary in this cases. I would advice just pick all the entries and add leading zeroes and that's it. You are consistent again and your query shall work fine.
Thanks,
Abhishek
‎2014 Oct 09 6:41 AM
HI Maria,
In the domain you can create the conversion routine and assign it to the domain.
in this you can create the two fm conversion_exit_XXXX_Input , conversion_exit_XXXX_output and assign to it domain.
In the settings of your databrowser select user parameters and activate the Check Conversion Exits for the table.
I hope this will be helpful.
Thanks & Regards,
Raghunadh Kodali.
‎2014 Oct 09 7:35 AM
Dear
you have to adjust the database table through se14 then new value will be fectched
and check the indexes also
Regards
‎2014 Oct 09 7:40 AM
NUMC is a character type basically.
So, 101 is 3 chars while 0101 is 4 chars thus making them different.
‎2014 Oct 09 7:52 AM
Hi Maria,
try SE14 with Menu Extras -> Force Conversion
Regards,
Klaus
‎2014 Oct 09 9:29 AM
Hi,
Thanks.
That field is the only key of the table (unique key). Let's say fieldkey. So I have 2 fields at the table, the key and one field for the description.
' 101' - Description old
'0101'- Description.new
Using that SE14 option (force conversion) wich entry will persist?
I know that it is possible to do a conversion program, but that is the situation that I encontoured... Also that table is external key from other...
Just want to understand SAP behaviour... as the field is numc thought that it was not possible to have entries without the leading 0!
Regards,
Maria João Rocha
‎2014 Oct 09 10:32 AM
Hi Maria,
sorry, I didn't know that the field is a key field.
In this case I would suggest to use a program for table entry conversion:
Alternatively you can create a new database table of the same structure, fill the new table from the old (with correct key and without duplicates) and rename the tables after that. So you can keep the old table as a copy with the original entries.
Regards,
Klaus
‎2014 Oct 09 10:42 AM
Hi,
But if SAP says that the numc it's a character string that may only contais digits (help at the dictionary), how is it possible to have a numc with leading space?
Regards,
Maria João Rocha
‎2014 Oct 09 11:33 AM
Hi Maria,
I think that is a keyfield issue. If you had a nonkey field to be changed. SAP would have adjusted it automatically with SE14. But for keyfields I think that isn't possible because of database restrictions.
Regards,
Klaus
‎2014 Oct 09 11:39 AM
Hi,
Also thought the same.. but it was nice to have
Regards,
Maria João Rocha
‎2014 Oct 09 12:02 PM