|
|
 |
Re: FN-FORUM: What's the best development platform for creating Web 2.0 business applications?
date posted 21st November 2007 19:34
> I'm sorry, I've read that several times and I can't make head nor tail
> of it.
I don't quite understand either.
The purpose of an unique id, is that it MAKES the record unique. Why
guess which column will stay unique when you can guarantee one will.
Username's may be unique when you start the database design, and then
when you find they're not at a later stage you have to redo lots of things.
Obviously, the way some people create database tables and automatically
create a auto_inc ID column when they don't really need one should be
avoided. Not quite sure how it could create problems though, it's just
unnecessary database bloat surely!?
And for the person earlier that avoided timestamps as they auto update
(as they're supposed to), you can get around that by doing: "update
table set timestamp = timestamp". That will update the timestamp field
with the timestamp currently in that record, not now() - in essence
keeping the timestamp that was already there.
However, unless you're using the timestamp for what it's designed for,
you're better using DATETIME.
Tom
|
 |
|