v1-0002-Return-empty-string-if-search_path-not-found.patch

application/octet-stream

Filename: v1-0002-Return-empty-string-if-search_path-not-found.patch
Type: application/octet-stream
Part: 1
Message: Re: Feature: psql - display current search_path in prompt
From 413ddcac18e32578c81831c4d54d4ed75fc3e1e2 Mon Sep 17 00:00:00 2001
From: Florents Tselai <florents.tselai@gmail.com>
Date: Tue, 10 Jun 2025 14:15:13 +0300
Subject: [PATCH v1 2/2] Return empty string if search_path not found

---
 src/bin/psql/common.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/bin/psql/common.c b/src/bin/psql/common.c
index 35b9066738a..343f7c74db6 100644
--- a/src/bin/psql/common.c
+++ b/src/bin/psql/common.c
@@ -2674,5 +2674,5 @@ session_search_path(void)
 	if (val)
 		return val;
 	else
-		return PQuser(pset.db);
+		return "";
 }
-- 
2.49.0