This chapter provides an overview of these data types, a more detailed description of the properties of the types in each category, and a summary of the data type storage requirements. For a multiple-row insert, LAST_INSERT_ ID () and mysql _insert_ id () actually return the AUTO_INCREMENT key from the first of the inserted rows. This enables multiple-row inserts to be reproduced correctly on other servers in a replication setup.
I know there is no such thing as a perfect answer, but there must be some sort of common convention for commonly used fields such as these. How do I change the data type for a column in. Updating an existing AUTO_INCREMENT column value also resets the AUTO_INCREMENT sequence. You can retrieve the most recent automatically generated AUTO_INCREMENT value with the LAST_INSERT_ ID () SQL function or the mysql _insert_ id () C API function.
These functions are connection-specific, so their return values are not affected by another. Let us now discuss them in detail. Even though id _text is a virtual column, it is possible, as above, to add an index on it (in that case, the index does occupy disk space).
These types include the exact numeric data types (INTEGER, SMALLINT, DECIMAL, and NUMERIC), as well as the approximate numeric data types (FLOAT, REAL, and DOUBLE PRECISION).