code: func getExpressionFsp(ctx sessionctx.Context, expression Expression) (int, error) {
  	constExp, isConstant := expression.(*Constant)
  	if isConstant && types.IsString(expression.GetType().Tp) && !isTemporalColumn(expression) {
  		str, isNil, err := constExp.EvalString(ctx, chunk.Row{})
  		if isNil || err != nil {
  			return 0, err
  		}
  		return types.GetFsp(str), nil
  	}
  	return mathutil.Min(expression.GetType().Decimal, types.MaxFsp), nil
  }
docs: // getExpressionFsp calculates the fsp from given expression.