AutoIncFields are not set automaticly

AutoIncFields are not set automaticly

Postby trying » Sun 19 Feb 2006 10:59

Hello,

I am still testing MyDAC.

I C++Builder 6 pro + MySQL 4.1.16
I have a master key:

INTEGER + AUTOINCREMENT and when I use fields editor for retrieve all fields in table this key is set with TIntegerField.

Regards
trying
 

Postby Antaeus » Mon 20 Feb 2006 09:16

It is normal behaviour. Because AUTO_INCREMENT keyword doesn't determine field data type at all, it only means that default value for the field will be calculated and set by the server. Note that MySQL Server allows setting values of the fields, defined as AUTO_INCREMENT, manually.
Antaeus
 
Posts: 2098
Joined: Tue 14 Feb 2006 10:14

Postby trying » Mon 20 Feb 2006 09:20

Ok.

I set this field to autoincfield manually and works well.

Regards
trying
 

Postby GEswin » Mon 20 Feb 2006 21:48

Another good solution is RefreshRecord after a post.
GEswin
 
Posts: 186
Joined: Wed 03 Nov 2004 16:57
Location: Spain


Return to MySQL Data Access Components