Closed chenminghua8 closed 1 month ago
I want to add a check that columns[0] must be a BinaryColumn in the StringFunctions::substring method. This will prevent BE crashes when passing exception types to the StringFunctions::substring method.
Thanks for your feedback. I think you can just restrict this type of table creation from being supported on FE.
One problem is to validate such illegal table statements. Another problem is that StringFunctions::substring allows non-BinaryColumn to be passed in without validation, causing BE to crash. This case is just one of the abnormal calls to substring. There are other abnormal calls to substring method, so substring method should be validated to avoid BE crash.
@Astralidea Assign the task to me. I will restrict the creation of such tables on FE.
@Astralidea Please help review the code.
Steps to reproduce the behavior (Required)
Expected behavior (Required)
Returns an error when calling the substr function with the wrong argument type.
Real behavior (Required)
BE service process crashes.
StarRocks version (Required)
2.5 3.0 3.1 3.2 3.3