|
1 | | -/* $PostgreSQL: pgsql/src/interfaces/ecpg/preproc/preproc.y,v 1.302 2004/12/06 20:35:35 meskes Exp $*/ |
| 1 | +/* $PostgreSQL: pgsql/src/interfaces/ecpg/preproc/preproc.y,v 1.303 2005/01/10 12:58:30 meskes Exp $*/ |
2 | 2 |
|
3 | 3 | /* Copyright comment*/ |
4 | 4 | %{ |
@@ -231,12 +231,12 @@ adjust_informix(struct arguments *list) |
231 | 231 | original_var = ptr->variable->name; |
232 | 232 | sprintf(temp,"%d))", ecpg_informix_var); |
233 | 233 |
|
234 | | -if ((ptr->variable->type->type != ECPGt_char && ptr->variable->type->type != ECPGt_unsigned_char) &&atoi(ptr->variable->type->size) >1) |
| 234 | +if ((ptr->variable->type->type !=ECPGt_varchar && ptr->variable->type->type !=ECPGt_char && ptr->variable->type->type != ECPGt_unsigned_char) &&atoi(ptr->variable->type->size) >1) |
235 | 235 | { |
236 | 236 | ptr->variable =new_variable(cat_str(4,make_str("("),mm_strdup(ECPGtype_name(ptr->variable->type->u.element->type)),make_str(" *)(ECPG_informix_get_var("),mm_strdup(temp)),ECPGmake_array_type(ECPGmake_simple_type(ptr->variable->type->u.element->type,make_str("1")), ptr->variable->type->size),0); |
237 | 237 | sprintf(temp,"%d, (", ecpg_informix_var++); |
238 | 238 | } |
239 | | -elseif ((ptr->variable->type->type == ECPGt_char || ptr->variable->type->type == ECPGt_unsigned_char) &&atoi(ptr->variable->type->size) >1) |
| 239 | +elseif ((ptr->variable->type->type ==ECPGt_varchar || ptr->variable->type->type ==ECPGt_char || ptr->variable->type->type == ECPGt_unsigned_char) &&atoi(ptr->variable->type->size) >1) |
240 | 240 | { |
241 | 241 | ptr->variable =new_variable(cat_str(4,make_str("("),mm_strdup(ECPGtype_name(ptr->variable->type->type)),make_str(" *)(ECPG_informix_get_var("),mm_strdup(temp)),ECPGmake_simple_type(ptr->variable->type->type, ptr->variable->type->size),0); |
242 | 242 | sprintf(temp,"%d, (", ecpg_informix_var++); |
|