General information
Category:
Coding, syntax & commands
Title:
MySQL Tables have C(0) fields?
Hi,
My MySQL table has the following structure:
mysql> desc ACHKTMPL;
+------------+--------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+------------+--------------+------+-----+---------+-------+
| RECNO | int(11) | | PRI | 0 | |
| APPROVED | smallint(6) | YES | | NULL | |
| APPROVDATE | datetime | YES | | NULL | |
| APPROVTIME | varchar(8) | YES | | NULL | |
| APPROVINIT | char(3) | YES | | NULL | |
| ACHKCMT | text | YES | | NULL | |
| LASTCHANGE | datetime | YES | | NULL | |
| TEMPLATE | varchar(30) | YES | | NULL | |
| ACHKPOINT | varchar(60) | YES | | NULL | |
| SCHEDULED | datetime | YES | | NULL | |
| SCHEDINIT | char(3) | YES | | NULL | |
| ARRIVED | smallint(6) | YES | | NULL | |
| ARRIVDATE | datetime | YES | | NULL | |
| ARRIVTIME | varchar(8) | YES | | NULL | |
| ARRIVINIT | char(3) | YES | | NULL | |
| ACHKDATE1 | datetime | YES | | NULL | |
| ACHKDATE2 | datetime | YES | | NULL | |
| ACHKDATE3 | datetime | YES | | NULL | |
| ACHKCOMM1 | text | YES | | NULL | |
| ACHKCOMM2 | text | YES | | NULL | |
| ACHKCOMM3 | text | YES | | NULL | |
| ACHKCOLOR | varchar(125) | YES | | NULL | |
| ACHKCHK1 | smallint(6) | YES | | NULL | |
| ACHKCHK2 | smallint(6) | YES | | NULL | |
| ACHKCHK3 | smallint(6) | YES | | NULL | |
| ACHKCDT1 | datetime | YES | | NULL | |
| ACHKCDT2 | datetime | YES | | NULL | |
| ACHKCDT3 | datetime | YES | | NULL | |
| ACHKCINIT1 | varchar(40) | YES | | NULL | |
| ACHKCINIT2 | varchar(40) | YES | | NULL | |
| ACHKCINIT3 | varchar(40) | YES | | NULL | |
+------------+--------------+------+-----+---------+-------+
However, when i open it via ODBC SPT and do AFIELDS() on it all the for Char fields have a max length of 0.
SQLEXEC(lnHandle,"select * from ACHKTMPL")
Because of this I cant enter any data in them (it disappears when I tab out of it)
Can anyone please explain what I am doing wrong?
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only