alamb commented on issue #17466:
URL: https://github.com/apache/datafusion/issues/17466#issuecomment-3270675171

   We already use `describe foo` for table schema
   
   ```
   DataFusion CLI v49.0.2
   > create table foo (x int) as values (1);
   0 row(s) fetched.
   Elapsed 0.033 seconds.
   
   > describe foo;
   +-------------+-----------+-------------+
   | column_name | data_type | is_nullable |
   +-------------+-----------+-------------+
   | x           | Int32     | YES         |
   +-------------+-----------+-------------+
   1 row(s) fetched.
   Elapsed 0.006 seconds.
   ```
   
   Describe appears to be an alias of explain:
   
   ```sql
   > describe  select x+1 from foo;
   +---------------+-------------------------------+
   | plan_type     | plan                          |
   +---------------+-------------------------------+
   | physical_plan | ┌───────────────────────────┐ |
   |               | │       ProjectionExec      │ |
   |               | │    --------------------   │ |
   |               | │     foo.x + Int64(1):     │ |
   |               | │    CAST(x AS Int64) + 1   │ |
   |               | └─────────────┬─────────────┘ |
   |               | ┌─────────────┴─────────────┐ |
   |               | │       DataSourceExec      │ |
   |               | │    --------------------   │ |
   |               | │         bytes: 112        │ |
   |               | │       format: memory      │ |
   |               | │          rows: 1          │ |
   |               | └───────────────────────────┘ |
   |               |                               |
   +---------------+-------------------------------+
   1 row(s) fetched.
   Elapsed 0.001 seconds.
   ```
   
   Maybe we can follow the model of whatever system that comes from 🤔 
   


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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to