Returns type information for a table's attributes.
list-attribute-types table &key database owner => result
:all or a string.
list-attribute-types returns type information for the attributes in the table given by table.
database has a default value of *default-database*.
If owner is
nil, only user-owned attributes are considered. This is the default.
If owner is
:all, all attributes are considered.
If owner is a string, this denotes a username and only attributes owned by owner are considered.
result is a list in which each element is a list (attribute datatype precision scale nullable). attribute is a string denoting the attribute name. datatype is the vendor-specific type as described in attribute-type. nullable is 1 if the attribute accepts the value NULL, and 0 otherwise.
When using ODBC to connect to Access database, the nullable value is not reliable, at least on version 7.1. There seems to be a bug in the driver. Using ODBC with other DBMS works as documented.
To print the type of every attribute in the database, do
(loop for tab in
(loop for type-info in
(format t "~&Table ~S Attribute ~S Type ~S"
LispWorks User Guide and Reference Manual - 13 Feb 2015