-
Notifications
You must be signed in to change notification settings - Fork 19
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
[Feature] affected row count #60
Comments
@Mirko-T
Documentation for
I added a log line to print
|
Hi @aosingh, Thanks for the answer. I can't find this "Affected row count" log line in my dbt.log file. I'm using: dbt version: 1.3.1 |
The new log line is local to my development branch. I added it for debugging to verify the value that is set in AdapterResponse |
Can I somehow test it on my end? |
@Mirko-T |
@Mirko-T You can install the code using the following command. The only change is a new log statement to print
|
I've installed dbt-oracle from debug/rowcount branch but I can't see any changes regarding additional Affected row count line in log file. Please reach out if you need more info from my end. |
@Mirko-T Did you add
Also, we directly use python driver's if you see this as 0 and need clarification you can also raise a question on python driver's issues page |
I don't see any line regarding affected rows. My log after table creation looks like this:
|
@Mirko-T What is the installation output of the following command ?
And the following ?
Are you working with a python virtual environment ? I am trying to understand if it is the correct environment where we are installing dbt-oracle and invoking dbt cli from I will also add this log line in the next release version of dbt-oracle which will released on PyPI soon. |
On first command I get a bunch of Requirement already satisfied messages. On second command I get /c/Users//Miniconda3/envs/dbtpoc/Scripts/dbt, I'm using Conda virtual environment. If you need more info from my side we can perhaps schedule a debugging call. |
@Mirko-T Not sure, if the package gets installed correctly from a git branch in your conda environment The first release cut v1.3.2rc1 is out. You can also test the log statement using this version.
Let me know you feedback |
@Mirko-T @geoHeil I discussed this feature request of affected rowcount with the python driver team and I will keep you posted on the resolution. Meanwhile, I will remove the log line as @geoHeil reported that the log line is too noisy and interferes with important dbt runtime information shown in the logs BTW, I recommend using the new package python-oracledb which is the new renamed interface of cx_oracle. It is already installed with dbt-oracle and you can switch it using
Read more about the new python driver on dbt docs Let me know if you have any questions |
do you have any progress @aosingh on the python driver team? |
@geoHeil @Mirko-T For dbt-oracle, you should get the expected row count using thin driver.
export ORA_PYTHON_DRIVER_TYPE=thin
dbt run ... |
While using
While using |
The think driver should also work right? @Mirko-T
does it work then for you? |
thick driver works but I'm not seeing any affected row count lines in my logs. |
@Mirko-T Please note that log line is removed because it was noisy. You will have to verify in "execution_time": 2.3757221698760986,
"adapter_response": {
"_message": "OK",
"rows_affected": 8
},
"failures": null,
"unique_id": "model.dbt_adbs_test_project.countries" With thick mode, rows_affected will be zero and we have a internal bug logged for that |
@Mirko-T the general python-oracledb solution for DPY-3015 is:
|
Describe the Feature
I would like to see a feature that shows affected row count, similar to sql%rowcount from PL/SQL. I'm aware of the variable "rows_affected" in run_results.json but currently it is always showing 0.
Describe alternatives you've considered
No response
Who will this benefit?
No response
Anything else?
No response
The text was updated successfully, but these errors were encountered: