[SR-Dev] git:janakj/postgres: - sync debug messages with recent work in db_mysql

Jan Janak jan at iptel.org
Wed Feb 18 01:26:20 CET 2009


Module: sip-router
Branch: janakj/postgres
Commit: fc12f10e710956dc85153c1be9271dd6d7d86d80
URL:    http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=fc12f10e710956dc85153c1be9271dd6d7d86d80

Author: Henning Westerholt <henning.westerholt at 1und1.de>
Committer: Henning Westerholt <henning.westerholt at 1und1.de>
Date:   Thu Apr 17 16:22:07 2008 +0000

- sync debug messages with recent work in db_mysql


git-svn-id: https://openser.svn.sourceforge.net/svnroot/openser/trunk@4039 689a6050-402a-0410-94f2-e92a70836424

---

 modules/db_postgres/km_db_res.c |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)

diff --git a/modules/db_postgres/km_db_res.c b/modules/db_postgres/km_db_res.c
index 7cdec54..5ba3eed 100644
--- a/modules/db_postgres/km_db_res.c
+++ b/modules/db_postgres/km_db_res.c
@@ -132,18 +132,21 @@ int db_postgres_get_columns(const db_con_t* _h, db_res_t* _r)
 			case INT2OID:
 			case INT4OID:
 			case INT8OID:
+				LM_DBG("use DB_INT result type");
 				RES_TYPES(_r)[col] = DB_INT;
 			break;
 
 			case FLOAT4OID:
 			case FLOAT8OID:
 			case NUMERICOID:
+				LM_DBG("use DB_DOUBLE result type");
 				RES_TYPES(_r)[col] = DB_DOUBLE;
 			break;
 
 			case DATEOID:
 			case TIMESTAMPOID:
 			case TIMESTAMPTZOID:
+				LM_DBG("use DB_DATETIME result type");
 				RES_TYPES(_r)[col] = DB_DATETIME;
 			break;
 
@@ -152,21 +155,24 @@ int db_postgres_get_columns(const db_con_t* _h, db_res_t* _r)
 			case VARCHAROID:
 			case BPCHAROID:
 			case TEXTOID:
+				LM_DBG("use DB_STRING result type");
 				RES_TYPES(_r)[col] = DB_STRING;
 			break;
 
 			case BYTEAOID:
+				LM_DBG("use DB_BLOB result type");
 				RES_TYPES(_r)[col] = DB_BLOB;
 			break;
 
 			case BITOID:
 			case VARBITOID:
+				LM_DBG("use DB_BITMAP result type");
 				RES_TYPES(_r)[col] = DB_BITMAP;
 			break;
 				
 			default:
 				LM_WARN("unhandled data type column (%.*s) type id (%d), "
-						"use STRING as default\n", RES_NAMES(_r)[col]->len,
+						"use DB_STRING as default\n", RES_NAMES(_r)[col]->len,
 						RES_NAMES(_r)[col]->s, datatype);
 				RES_TYPES(_r)[col] = DB_STRING;
 			break;




More information about the sr-dev mailing list