‎2007 Mar 14 12:12 AM
Hi,
A table has 3 fields. One is a key and the other non-key and the other is mandt.
I maintained custom entries in a table as for ex: 'Program' and 'Report'. I wrote a custom function module to pull records from this table. I tried testing the function module to retrieve the records from this table based on a field = 'Program'. But the sy-subrc is NE 0 !
The reason: I went in debugging mode and see what's happening. Looks like the query is being done based on 'PROGRAM' even though I input 'Program'. Can you help me out on how can I do the succesful query and get exactly what I want based on the values I input instead of having problem with those CAPS?
Thanks for your input.
Message was edited by:
Krishen
Message was edited by:
Krishen
‎2007 Mar 14 12:23 AM
In SE37 there is a check box for "Uppercase/Lower case" use that. This preserves case sensitivity. During programmatic calling, this upper case conversion doesn't happen
‎2007 Mar 14 12:18 AM
Ahh... it is being converted to uppercase, yes? I would suggest entering your values in your custom table as uppercase and force this during update of the table. You can do this at the domain level, where you would not set the "Lowercase" checkbox. Program names should always be stored as uppercase since SAP makes no distinct between upper and lower case when storing program names. They are simply always stored as upper case.
Regards,
RIch Heilman
‎2007 Mar 14 12:23 AM
In SE37 there is a check box for "Uppercase/Lower case" use that. This preserves case sensitivity. During programmatic calling, this upper case conversion doesn't happen
‎2007 Mar 14 1:05 AM
Thanks friends.
In se37, that "Uppercase/Lower case" thing will work fine but not working in program.
Is there any other solution that you know?
Thanks
‎2007 Mar 14 1:08 AM
‎2007 Mar 14 1:17 AM
thanks Rich. I may be creating another FM later similar to this but that may be not for program names. In that way, is mainitaining the data in tables always in CAPS the only fix?
‎2007 Mar 14 1:20 AM
I would say yes, there is no reason to have case-sensitive data stored in your database for key fields. You will see some fields as lower-case enabled, but they are usually text fields or description fields. You shouldn't have your key fields in any table which are case-sensitive, that just makes your job harder.
Regards,
RIch Heilman