Relative Content

Tag Archive for amazon-redshift

Unable to match WHERE condition on a calculated field of a View in AWS Redshift

When I include a column in WHERE condition from a view it does not match the value. Instead, when i use TRIM(column) in where condition it works fine. The data does not include any trailing spaces as its a calculated field created by me. The view is fetching data from other views.
Here are the steps to recreate the issue on your side.

Redshift query optimization issue

I am trying to improve the performance of one of our pipelines via redefining the distkey and sortkey on the primary source table. I was able to get a factor of 5 speed increase on the select and insert queries but am getting the inverse on our update queries and can’t figure out why.

Redshift Managed VPC Endpoint

I am trying to create Redshift-managed VPC Endpoint, but on the screen I can simply not select my cluster id, infact, the list is empty.

Redshift serverless materialized view not showing stale after rows added

On a redshift serverless, I’m adding rows to a table from within a stored procedure. I check row count before and after calling the proc, see the new rows. But the auto incrementing mat view i created joining this table with some others, doesn’t show as stale in svv_mv_info, and says no changes when i call refresh on it. If I then insert or delete 1 row manually from the table it’ll correctly show stale… anyone ever experience this, mat views not showing stale even though new data’s come into one of their tables?

Will help in any way locking a table before upserting on Redshift?

I got into this code while reviewing some repos, I know what lock does, know also that Redshift has a way of maintaining a current version of a table between queries using snapshots.
So the question is, does that lock at the begin of the transaction make any sense?
I think that it’s bringing more issues locking users than solutions.
Thanks!