Ads were blocked - no problem. But keep in mind that developing HeidiSQL, user support and hosting takes time and money. You may want to send a donation instead.

PostgreSql - search_path

Koszyk's profile image Koszyk posted 2 months ago in General Permalink

Hi!

Heidi changes search_path when I click on schema. Is it possible to set up search_path value for every schema in DB? F.e. I would like to have:

set search_path = "$user", public

insead of

regards

ansgar's profile image ansgar posted 2 months ago Permalink

What exactly means $user in this case?

If that makes sense for everyone I would of course change that command in HeidiSQL.

Koszyk's profile image Koszyk posted 2 months ago Permalink

Schema "$user" means schema with the same name as user name. It is seached at first, then public schema. In the application I use I have many schemas and some global functions are not availeble in default HeidiSql behavior. But I added this command to startup script and my issue has ben solved.

Ads were blocked - no problem. But keep in mind that developing HeidiSQL, user support and hosting takes time and money. You may want to send a donation instead.
ansgar's profile image ansgar posted 2 months ago Permalink

So I guess I get it right if I say $user is useful for all other users as well. I should change that search path command in the base HeidiSQL code.

Code modification/commit 56474ea from Ansgar Becker <anse@heidisql.com>, 2 months ago, revision 5688
Get schema with the same name as user name in search path. See https://www.heidisql.com/forum.php?t=34558
ansgar's profile image ansgar posted 2 months ago Permalink

Next build should have that.

Koszyk's profile image Koszyk posted 2 months ago Permalink

Thanks! My problem has ben solved. Current behavior may be interesting for others. I think It could be an option.

Please login to leave a reply, or register at first.