Home » U++ Library support » U++ SQL » Possible SqlOption Problem [Solved]
Re: Possible SqlOption Problem [message #22799 is a reply to message #22792] |
Mon, 17 August 2009 15:39   |
marroyo
Messages: 8 Registered: August 2009 Location: Argentina
|
Promising Member |
|
|
Hi Mirek. I will be more explicit now.
I have a PostgreSQL table SOCIO with a activo (active) boolean field.
I've defined a window with a SqlArray object.
SqlArray show's me the boolean column as value 1.
I want edit fields, so I add a column to SqlArray by doing
socios_array.AddColumn(ACTIVO, "Activo").Edit(activo);
If I declare activo of SqlOption type, when I try to do socios_array.Query(), I get the following assertion failure:
Assertion failed in C:\uppsrc\Core/Value.h, line 417
dynamic_cast<const RichValueRep *>(p)
If I declare activo as Option type, I can't edit (or insert) rows because the SQL statement generated is
insert into SOCIO(OBJID, RAZON_SOCIAL, ACTIVO, CATEG_IVA) values (801, 'MARCELO', 1, 'C')
You can see that ACTIVO column value is an integer (not a boolean), getting a database error from PostgreSQL.
I could fix it doing a Convert from Option, but I think it is the goal of SqlOption.
Thank you.
|
|
|
 |
|
Possible SqlOption Problem [Solved]
By: rbmatt on Fri, 04 August 2006 23:58
|
 |
|
Re: Possible SqlOption Problem
By: mirek on Sat, 05 August 2006 06:54
|
 |
|
Re: Possible SqlOption Problem
By: rbmatt on Sat, 05 August 2006 07:24
|
 |
|
Re: Possible SqlOption Problem
By: marroyo on Fri, 14 August 2009 21:39
|
 |
|
Re: Possible SqlOption Problem
By: mirek on Sun, 16 August 2009 23:58
|
 |
|
Re: Possible SqlOption Problem
By: marroyo on Mon, 17 August 2009 15:39
|
 |
|
Re: Possible SqlOption Problem
By: mirek on Mon, 17 August 2009 20:18
|
 |
|
Re: Possible SqlOption Problem
By: marroyo on Tue, 18 August 2009 20:25
|
 |
|
Re: Possible SqlOption Problem
By: mirek on Fri, 21 August 2009 14:27
|
 |
|
Re: Possible SqlOption Problem
By: marroyo on Fri, 21 August 2009 19:12
|
 |
|
Re: Possible SqlOption Problem
By: marroyo on Wed, 26 August 2009 23:37
|
 |
|
Re: Possible SqlOption Problem
By: mirek on Fri, 28 August 2009 09:54
|
Goto Forum:
Current Time: Mon Apr 28 14:23:57 CEST 2025
Total time taken to generate the page: 0.00642 seconds
|