alamb commented on code in PR #7944:
URL: https://github.com/apache/arrow-datafusion/pull/7944#discussion_r1373834408


##########
datafusion/common/src/dfschema.rs:
##########
@@ -33,17 +33,36 @@ use crate::{
 
 use arrow::compute::can_cast_types;
 use arrow::datatypes::{DataType, Field, FieldRef, Fields, Schema, SchemaRef};
+use sqlparser::ast::Table;
 
 /// A reference-counted reference to a `DFSchema`.
 pub type DFSchemaRef = Arc<DFSchema>;
 
 /// DFSchema wraps an Arrow schema and adds relation names
+///
+/// # Example
+/// ```
+/// Creating a DF schema from an arrow schema
+/// ```
+///
+/// ```
+/// Converting from DF schema to arrow schema
+/// ```
+///
+/// ```
+/// Iterating over qualified fields
+/// ```
 #[derive(Debug, Clone, PartialEq, Eq)]
 pub struct DFSchema {
-    /// Fields
-    fields: Vec<DFField>,
-    /// Additional metadata in form of key value pairs
-    metadata: HashMap<String, String>,
+    /// Inner arrow schema
+    inner: SchemaRef,
+
+    /// Optional qualifiers for each column in this schema. In the same order 
as

Review Comment:
   This is the key design --remove `DFField` and simply wrap an inner arrow 
Schema ref. 



-- 
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