Fixed an issue where the query gets executed automatically when the query tool opened using Create Script, Schema Diff.

This commit is contained in:
Anil Sahoo 2024-09-18 07:47:20 +05:30 committed by GitHub
parent acb0eb2141
commit a361fd94ff
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -363,10 +363,11 @@ export default function QueryToolComponent({params, pgWindow, pgAdmin, selectedN
connected_once: true,
obtaining_conn: false,
});
eventBus.current.fireEvent(QUERY_TOOL_EVENTS.TRIGGER_EXECUTION, explainObject, macroSQL, executeCursor);
let msg = `${selectedConn['server_name']}/${selectedConn['database_name']} - Database connected`;
pgAdmin.Browser.notifier.success(_.escape(msg));
if(!qtState.params.is_query_tool) {
eventBus.current.fireEvent(QUERY_TOOL_EVENTS.TRIGGER_EXECUTION, explainObject, macroSQL, executeCursor);
let msg = `${selectedConn['server_name']}/${selectedConn['database_name']} - Database connected`;
pgAdmin.Browser.notifier.success(_.escape(msg));
}
}).catch((error)=>{
if(error.response?.request?.responseText?.search('Ticket expired') !== -1) {
Kerberos.fetch_ticket()