Re: [gnome-db] Prepared Statements



	I was thinking about the API for prepared statements because when
you create a new GdaParameter you have to specify the GdaValueType and I
don'k understand why. It can be relationed with the GdaValue class,
because you can create a GdaValue without a type, and then you'd need to
pass the type to gda_parameter_new().

	I don't know if the provider would need the type of the value to
set it to null. If this doesn't happen everything is OK, but if does, I
think that the GdaValue class must encapsulate the real type and not
GDA_VALUE_TYPE_NULL because I think it's a bit ugly to pass the type to
gda_parameter_new(), so my idea is that gda_paramenter_new() could get the
real type calling gda_value_get_type(). 

	 I don't know what happens when you, for instance, create a
GdaValue with an int, and then you put it to null with set null, does it
keep the real type? If this happens everything would be easy, because to
create a null GdaValue, only gda_value_new_null() would have to be changed
to get the GdaValueType.

	What's your opinion?

	Bye!




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]