You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "berkaysynnada (via GitHub)" <gi...@apache.org> on 2023/04/28 07:15:24 UTC
[GitHub] [arrow-datafusion] berkaysynnada opened a new issue, #6148: SELECT INTO Support
berkaysynnada opened a new issue, #6148:
URL: https://github.com/apache/arrow-datafusion/issues/6148
### Is your feature request related to a problem or challenge?
Add support for queries in the form of
```
SELECT ts
INTO table2
FROM table1
```
### Describe the solution you'd like
SELECT ... INTO and CREATE TABLE ... AS gives the same results AFAIK, like:
```
CREATE TABLE orders_summary AS
SELECT c.customer_id, c.first_name, c.last_name, COUNT(o.order_id) AS total_orders, SUM(o.order_total) AS total_order_value
FROM customers c
JOIN orders o ON c.customer_id = o.customer_id
GROUP BY c.customer_id;
SELECT * FROM orders_summary;
```
```
SELECT c.customer_id, c.first_name, c.last_name, COUNT(o.order_id) AS total_orders, SUM(o.order_total) AS total_order_value
INTO orders_summary
FROM customers c
JOIN orders o ON c.customer_id = o.customer_id
GROUP BY c.customer_id;
SELECT * FROM orders_summary;
```
SELECT INTO can construct the same statement as CREATE TABLE AS.
### Describe alternatives you've considered
_No response_
### Additional context
_No response_
--
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: github-unsubscribe@arrow.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-datafusion] mustafasrepo closed issue #6148: SELECT INTO Support
Posted by "mustafasrepo (via GitHub)" <gi...@apache.org>.
mustafasrepo closed issue #6148: SELECT INTO Support
URL: https://github.com/apache/arrow-datafusion/issues/6148
--
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: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org