Skip to content

Commit

Permalink
Remove parentheses from create view logic (#172)
Browse files Browse the repository at this point in the history
### Summary

Remove parentheses from view materialization to optimize VDSs in Dremio.

### Description

Before:
```
(
   select * from table
)
```
After:
```
select * from table
```

### Test Results

All functional tests pass. 

### Changelog

-   [ ] Added a summary of what this PR accomplishes to CHANGELOG.md

### Related Issue
#167
  • Loading branch information
ravjotbrar authored Jul 14, 2023
1 parent 8143c81 commit 388f540
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
5 changes: 4 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,17 @@
## Under the Hood

- [#199](https://github.com/dremio/dbt-dremio/issues/199) Populate PyPI's `long_description` with contents of `README.md`
- [#167](https://github.com/dremio/dbt-dremio/issues/167) Remove parentheses surrounding views in the create_view_as macro. In more complex queries, the parentheses cause performance issues.


# dbt-dremio 1.5.0 - release June 22, 2023


## Features

## Fixes

## Under the Hood

- [#179](https://github.com/dremio/dbt-dremio/issues/179) Upgrade to support dbt-core v1.5.0.
- Add support for Python 3.11.
- Add support for relevant Tests:
Expand All @@ -27,6 +29,7 @@
- Upgrade dbt-tests-adapter to 1.5.0.
- Upgrade Requests to 2.31.0. [#183](https://github.com/dremio/dbt-dremio/issues/183).


# dbt-dremio 1.4.5 - release March 23, 2023

## Features
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ limitations under the License.*/

{{ sql_header if sql_header is not none }}

create or replace view {{ relation }} as (
{{ sql }}
)
create or replace view {{ relation }} as {{ sql }}

{%- endmacro %}

0 comments on commit 388f540

Please sign in to comment.