[DB-SIG] Again a question about the API
Michael Lorton
mlorton@microsoft.com
Tue, 30 Sep 1997 11:55:30 -0700
> From: Oliver Andrich [SMTP:andrich@fga.de]
> Sent: Monday, September 29, 1997 11:10 AM
> what do I means the following passage to me and what
> relevance has this for the API.
>
> "...Each 7-tuple contains information describing each result column:
> (name,
> type_code, display_size, internal_size, precision, scale, null_ok).
> ... Note:
> this is a bit in flux. Generelly, the first two items of the 7-tuple
> will be
> present; others may be database specific."
>
> Why do we need something like this description thing? I convert all
> the values
> returned by the database to native Python values as soon as you query
> the
> database.
>
I can tell you why we put it there and what we use it for. Say you want
to write a general-purpose table display or editing mechanism. You can
execute (but not fetch) "select * from tablename" and then use the
description to build a form, perform minor edit-checking, that sort of
thing.
M.
_______________
DB-SIG - SIG on Tabular Databases in Python
send messages to: db-sig@python.org
administrivia to: db-sig-request@python.org
_______________