suxiaogang223 commented on issue #5309:
URL: 
https://github.com/apache/arrow-datafusion/issues/5309#issuecomment-1435152254

   I think returning enum will be same as returning result, because the caller 
also have to handle Ambiguous and return an `Err`.
   
   Returning `Result<bool>` can also avoid str allocating in 
`field_from_name().is_err()`. The code will be like this:
   ```rust
   If schema.had_column(col)? {...}
   ```
   
   Maybe the key question is that do we need      to check 'Ambiguous error' 
each time the had_column called? Actually we can just check Ambiguous err once 
at begin.
   
   I'm not sure if my thinking is correct, need your advice @alamb 🤓


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to