On 1/5/2011 13:31, James Dekker wrote:
Because some sequence tables contain one to many cardinality and MySQL tables
can only have one auto_increment column...
Is there a way to do what I am trying to do (obtain max sequence id, set it to
its corresponding table, and then increment by one) in
Because some sequence tables contain one to many cardinality and MySQL tables
can only have one auto_increment column...
Is there a way to do what I am trying to do (obtain max sequence id, set it to
its corresponding table, and then increment by one) in a stored function?
Happy programming,
J
On 1/4/2011 23:23, James Dekker wrote:
Peter,
Thanks for the response!
Unfortunately, that worked but a new error arose:
check the manual that corresponds to your MySQL server version for the right
syntax to use near 'ID = (select max(CONVERT(id_field, signed)) from
my_table_t)' at line 1
I
Peter,
Thanks for the response!
Unfortunately, that worked but a new error arose:
check the manual that corresponds to your MySQL server version for the right
syntax to use near 'ID = (select max(CONVERT(id_field, signed)) from
my_table_t)' at line 1
Is there a better way to generate incremen
generate_dynamic_id('my_sequence_id_s', 'my_table_t', 'table_id', @dynamicId);
Should be:
CALL generate_dynamic_id('my_sequence_id_s', 'my_table_t', 'table_id',
@dynamicId);
PB
On 1/4/2011 9:28 PM, James Dekker wrote:
Hello there,
I am using MySQL 5 on OS X - Snow Leopard...
Have w
Hello there,
I am using MySQL 5 on OS X - Snow Leopard...
Have working code in place which obtains the highest sequence number ID from a
sequence table and then increments and assigns it to its corresponding table:
The original code's purpose is to dynamically increments a specific table's
las