*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.493 2006/07/29 03:02:56 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.494 2006/08/04 18:53:46 momjian Exp $
*
* NOTES
* this is the "main" module of the postgres backend and
if (log_statement == LOGSTMT_ALL)
ereport(LOG,
- (errmsg("statement: [protocol] PREPARE %s AS %s",
- (*stmt_name != '\0') ? stmt_name : "<unnamed>",
+ (errmsg("statement: <protocol> PREPARE %s AS %s",
+ *stmt_name ? stmt_name : "<unnamed>",
query_string)));
/*
/* We need to output the parameter values someday */
if (log_statement == LOGSTMT_ALL)
ereport(LOG,
- (errmsg("statement: [protocol] <BIND> %s", portal_name)));
+ (errmsg("statement: <protocol> <BIND> %s [PREPARE: %s]",
+ *portal_name ? portal_name : "<unnamed>",
+ portal->sourceText ? portal->sourceText : "")));
/*
* Fetch parameters, if any, and store in the portal's memory context.
if (log_statement == LOGSTMT_ALL)
/* We have the portal, so output the source query. */
ereport(LOG,
- (errmsg("statement: [protocol] %sEXECUTE %s [PREPARE: %s]",
+ (errmsg("statement: <protocol> %sEXECUTE %s [PREPARE: %s]",
execute_is_fetch ? "FETCH from " : "",
- (*portal_name) ? portal_name : "<unnamed>",
+ *portal_name ? portal_name : "<unnamed>",
portal->sourceText ? portal->sourceText : "")));
BeginCommand(portal->commandTag, dest);
secs, msecs)));
else
ereport(LOG,
- (errmsg("duration: %ld.%03d ms statement: [protocol] %sEXECUTE %s [PREPARE: %s]",
+ (errmsg("duration: %ld.%03d ms statement: <protocol> %sEXECUTE %s [PREPARE: %s]",
secs, msecs,
execute_is_fetch ? "FETCH from " : "",
- (*portal_name) ? portal_name : "<unnamed>",
- portal->sourceText ? portal->sourceText : "")));
+ *portal_name ? portal_name : "<unnamed>",
+ portal->sourceText ? portal->sourceText : "")));
}
}