andygrove opened a new issue, #2319:
URL: https://github.com/apache/arrow-datafusion/issues/2319
**Is your feature request related to a problem or challenge? Please describe
what you are trying to do.**
I have a simple schema containing a column with the qualified name `df.a`:
``` rust
let schema = DFSchema::new_with_metadata(vec![
DFField::new(Some("df"), "a", DataType::Int64, false),
], HashMap::new())?;
```
If I attempt to look this up using `schema.index_of("df.a")` I get the very
confusing error `No field named 'df.a'. Valid fields are 'df.a'.`.
There is an `index_of_column_by_name(&self, qualifier: Option<&str>, name:
&str)` which would be a better API to call and this works as expected but it is
not public.
As a workaround I have to use
`index_of_column(&Column::from_qualified_name("df.a"))` instead, creating a
temporary data structure and invoking a tokenizer which seems heavyweight.
**Describe the solution you'd like**
My proposal would be:
- Deprecate `index_of(&self, name: &str)` and also have it return an error
if passed a qualified name
- Make `index_of_column_by_name` public
**Describe alternatives you've considered**
None
**Additional context**
None
--
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]