Database question


#1

I have a quick question about linking tables,

How would link all my tables so that when I add one object in one it just keeps adding to the id # . (ie if I have 6 objects in table one, 1,2,3,4,5,6 and I add new object to table 2 automatically it will look in the other tables and just add the next # in the id field ?)

Not sure if I made myself clear.

Thanks


#2

No. Not clear at all.

Use the term records or rows for databases, not objects.


#3

Although it is unclear, I am going take stab at this one…I think you would be talking about auto_increment. This is in an attribute that can be set in your MySQL table.

Example:

CREATE TABLE my_tbl (
my_id int(16) auto_increment
);