I wanted to give a heads up on people using the auto-coder feature. I have a file that is keyed by RTAXED. I created a quick grid inquiry app using Auto Coder. I used RTAXED as my search field. The RPG code that was generated formatted the SQL statement to perform an UPPER on the field name RTAXED:
UPPER(RTAXED)
Because of this, the server job that serviced this app started building a temporary index on a file with over 90mil records. There was already an index by RTAXED over the PF. My research indicates that the UPPER() had something to do with the proposed index by the SQL engine.
Just wanted to give everyone a heads up in case they run into this problem. I understand the use of upper on the variables but to use UPPER on a database field may cause some problems.
UPPER(RTAXED)
Because of this, the server job that serviced this app started building a temporary index on a file with over 90mil records. There was already an index by RTAXED over the PF. My research indicates that the UPPER() had something to do with the proposed index by the SQL engine.
Just wanted to give everyone a heads up in case they run into this problem. I understand the use of upper on the variables but to use UPPER on a database field may cause some problems.
Comment