1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-27 12:41:57 +03:00

Implement current_query(), that shows the currently executing query.

At the same time remove dblink/dblink_current_query() as it is no longer
necessary
*BACKWARD COMPATIBILITY ISSUE* for dblink

Tomas Doran
This commit is contained in:
Bruce Momjian
2008-04-04 16:57:21 +00:00
parent cfaf8b6b67
commit f96928fde9
11 changed files with 32 additions and 87 deletions

View File

@ -8,7 +8,7 @@
* Darko Prenosil <Darko.Prenosil@finteh.hr>
* Shridhar Daithankar <shridhar_daithankar@persistent.co.in>
*
* $PostgreSQL: pgsql/contrib/dblink/dblink.c,v 1.71 2008/03/26 21:10:36 alvherre Exp $
* $PostgreSQL: pgsql/contrib/dblink/dblink.c,v 1.72 2008/04/04 16:57:21 momjian Exp $
* Copyright (c) 2001-2008, PostgreSQL Global Development Group
* ALL RIGHTS RESERVED;
*
@ -1631,23 +1631,6 @@ dblink_build_sql_update(PG_FUNCTION_ARGS)
PG_RETURN_TEXT_P(cstring_to_text(sql));
}
/*
* dblink_current_query
* return the current query string
* to allow its use in (among other things)
* rewrite rules
*/
PG_FUNCTION_INFO_V1(dblink_current_query);
Datum
dblink_current_query(PG_FUNCTION_ARGS)
{
if (debug_query_string)
PG_RETURN_TEXT_P(cstring_to_text(debug_query_string));
else
PG_RETURN_NULL();
}
/*************************************************************
* internal functions
*/