You are here: Re: on input form showing error message for duplicate entry. « All PHP « IT news, forums, messages
Re: on input form showing error message for duplicate entry.

Posted by Steve on 10/18/06 13:55

".:[ ikciu ]:." <no@mail.com> wrote in message
news:eh3ism$32b$1@news.dialog.net.pl...
| Hmm Steve <no.one@example.com> wrote:
| > whatever, dude. do you NOT get that prior to the insert of NEW DATA,
| > there IS NO FUCKING ID TO AUTOINCREMENT. dumbass. and when you EDIT a
|
| THERE SHOULD BE in "almost" every table in DB
|
| > record, do you not see that YOUR SUGGESTION DOES NOTHING to prevent
| > data overwrites?
|
| ofc it is, you have id and you update data where id = this what you have,
if
| error duplicate entry, then handle and info for user, nameID is taken (ID
| numeric is autoincrement)

try to understand...i'll explain one more time. i think you've missed the
following two points simply because you HAVEN'T listened to the op or anyone
else here. that, or you just don't understand the english.

if i submit a new records for php to insert into a db, neither php NOR the
db have an id for the record. the record has NOT been created yet.
auto-increment does not prevent us from submitting that same data again and
again, each time getting a new id for each record being inserted. however,
EVER submission after the FIRST is a DUPLICATION.

second, if i have an auto-incrementing field, it's use is to merely be a
record identifier. if i'm creating records with product codes/id's or users
with user names, each can be OVERWRITTEN without effecting the record's id
IN THE LEAST. if jblow is a user defined in a users table and i change the
user name of jrancher to jblow, i have effectively overwritten the data of
jblow. i have compromised both the integrity of data AND potentially opened
a wide security hole in the system. auto-incrementing id's has done NOTHING
to prevent it.

had you actually read or understood my code example, you'd have quickly seen
that BOTH of these issues were handled. you knit-picked every part of that
example (even though the 'problems' reloved around your lack of
understanding) yet missed that KEY FUNCTIONALITY. as you say, 'for me, that
won't do'.

when you grow up, perhaps you'll learn to read something more substancial
than 'dick-and-jane' level code. if you think you are STILL solving
anything, then POST YOUR SOLUTION HERE.

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация