Re: [gnome-db] Gda Column question.





2008/10/1 Daniel Espinosa <esodan gmail com>
In V4 you have GdaMetaStore to get columns and others db objects information. In order to get that information you have to do:

- Get a GdaMetaStore from a GdaConnnection using gda_connection_get_meta_store
- Update meta information gda_connection_update_meta_store
- Get columns information using gda_meta_store_extract and use GdaDataModel API to access to the required information

The required SQL to do it could be:

SELECT *  FROM _columns WHERE table_schema = ##schema::string AND table_catalog = ##catalog::string AND table_name = ##table::string

For gda_column_get_scale you can use numeric_scale column; sorry but don't know about defined_size.

You can use the numeric_precision or numeric_scale columns, with both these columns you should have all the characteristics of a column.
Now, this was to get meta data information. I agree that I've been a bit too quick in simplifying the GdaColumn API and I should bring back the API which handles numeric presicion and scale, but probably not as it was. Let me think about it.

Cheers,

Vivien
 



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