diff options
author | Michael Meskes <meskes@postgresql.org> | 2010-01-13 09:06:51 +0000 |
---|---|---|
committer | Michael Meskes <meskes@postgresql.org> | 2010-01-13 09:06:51 +0000 |
commit | b3627d1de3ec03adea8551465351bc536f12f526 (patch) | |
tree | 3b4b4e04f4f743d59fe2c15e135d771321417332 /src | |
parent | cf4d9c4772d9b8efe7d132ce6556d6b338870515 (diff) | |
download | postgresql-b3627d1de3ec03adea8551465351bc536f12f526.tar.gz postgresql-b3627d1de3ec03adea8551465351bc536f12f526.zip |
Applied Zoltan's patch to make char the default sqlda type.
Given that undefined types are handled as character strings anyway the type
translation function can simply return the correcponding ECPGt_char type.
Diffstat (limited to 'src')
-rw-r--r-- | src/interfaces/ecpg/ecpglib/typename.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/interfaces/ecpg/ecpglib/typename.c b/src/interfaces/ecpg/ecpglib/typename.c index e24124ed9aa..ff22d703bfe 100644 --- a/src/interfaces/ecpg/ecpglib/typename.c +++ b/src/interfaces/ecpg/ecpglib/typename.c @@ -1,4 +1,4 @@ -/* $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/typename.c,v 1.17 2010/01/13 08:41:48 meskes Exp $ */ +/* $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/typename.c,v 1.18 2010/01/13 09:06:51 meskes Exp $ */ #define POSTGRES_ECPG_INTERNAL #include "postgres_fe.h" @@ -136,7 +136,8 @@ sqlda_dynamic_type(Oid type, enum COMPAT_MODE compat) #ifdef HAVE_LONG_INT_64 return ECPGt_long; #endif + /* Unhandled types always return a string */ default: - return (-type); + return ECPGt_char; } } |