An SQLPLAN error might occur when you use an inline view
An SQLPLAN error might occur when you query a database management system (DBMS) table via a LIBNAME engine and the following conditions exist in your SQL procedure query:
An inline view
LENGTH= modifier
A new variable is being created in the inline view that is a constant
To work around the issue, do one of the following: