How Do I Fix the DLI.0005 Error When Using EL Expressions to Create a Table in a Flink SQL Job?
Symptom
DLI.0005: AnalysisException: t_user_message_input_#{date_format(date_sub(current_date(), 1), 'yyyymmddhhmmss')} is not a valid name for tables/databases. Valid names only contain alphabet characters, numbers and _.
Solution
Replace the number sign (#) in the table name to the dollar sign ($). The format of the EL expression used in DLI should be ${expr}.
Before modification:
t_user_message_input_#{date_format(date_sub(current_date(), 1), 'yyyymmddhhmmss')}
After modification:
t_user_message_input_${date_format(date_sub(current_date(), 1), 'yyyymmddhhmmss')}
After the modification, the Flink SQL job can correctly parse table names and dynamically generate table names based on EL expressions.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot