Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hive parameters not settable #93

Closed
bijzz opened this issue Jan 28, 2023 · 2 comments
Closed

hive parameters not settable #93

bijzz opened this issue Jan 28, 2023 · 2 comments

Comments

@bijzz
Copy link

bijzz commented Jan 28, 2023

Is it possible to set hive parameters like set hive.tez.container.size=8192 for all connections or per model?

I added the statement in a dbt macro like


{% macro hive_settings() %}

{% set sql %}
    set hive.tez.container.size=8192
{% endset %}

{% do run_query(sql) %}

{% do log("Hive settings applied", info=True) %}
{% endmacro %}

But runnning it dbt run-operation hive_settings ends in

Running with dbt=1.3.2
Hive settings applied
Encountered an error while running operation: Runtime Error
Runtime Error
Unable to establish connection to Hive server: Error while compiling statement: FAILED: ParseException line4:8 cannot recognize input near 'set' 'hive' '.' in statement

Additionally, it would be nice to set them via profiles.yml similiar to the server_side_parameters in the dbt-spark module, see https://docs.getdbt.com/reference/warehouse-setups/spark-setup#odbc.

@tovganesh
Copy link
Contributor

@bijzz please see this #85

You can use pre-hooks to use hive parameters.

@bijzz
Copy link
Author

bijzz commented Jan 30, 2023

Thanks, pre-hooks work after building the package from latest source.

@bijzz bijzz closed this as completed Jan 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants