postgres-migrations icon indicating copy to clipboard operation
postgres-migrations copied to clipboard

Hashes mismatch issue when we use dynamic query inside migration script

Open ajishvnair-neoito opened this issue 3 years ago • 1 comments

Suppose if we added a new table to store user settings, it has some default settings so we need to do some dynamic sql script to update settings for all existing users

insert into settings ("color" , "userId")
select '${ 'red' }', "id" from users

ajishvnair-neoito avatar Nov 26 '21 11:11 ajishvnair-neoito

I'm sorry, I'm not following. Could you elaborate on the example?

ThomWright avatar Nov 28 '21 20:11 ThomWright