ServerProvider.stringToValue
gobject.value.Value stringToValue(gda.connection.Connection cnc, string string_, gobject.types.GType preferredType, out string dbmsType)Use provider to create a new #GValue from a single string representation.
The preferred_type can optionally ask provider to return a #GValue of the requested type (but if such a value can't be created from string, then null is returned); pass #G_TYPE_INVALID if any returned type is acceptable.
The returned value is either a new #GValue or null in the following cases:
- string cannot be converted to preferred_type type
- the provider does not handle preferred_type
- the provider could not make a #GValue from string
If dbms_type is not null, then if will contain a constant string representing the database type used for the conversion if the conversion was successfull, or null otherwise.
Parameters
cnc | a #GdaConnection object, or null |
string_ | the SQL string to convert to a value |
preferredType | a #GType, or #G_TYPE_INVALID |
dbmsType | place to get the actual database type used if the conversion succeeded, or null |
Returns
a new #GValue, or null