pboin has asked for the wisdom of the Perl Monks concerning the following question:
I'm working on a web interface to do some rather simple DB maintenance. Low volume SELECTs & UPDATEs mostly.
The form will have a handful of simple records displayed from a few tables. For purposes of discussion, let's say we have 5 records from each of two tables. Also, let's say that I'm displaying the PKey read-only, and I have form inputs for the other fields. Each set of records is followed by a new blank row, in case the user wants to INSERT a new record.
Which what mechanism would you recommend I keep track of what data has been offered and returned? (Specifically, so I can build my SQL.) Right now, I have generated fieldnames that hold the table and the rowID, but this is grossly, horribly insecure, and I know that. TMTOWTDI, and this is a *poor* way.
Secondly and less importantly, can you recommend a mechanism that will help me know when my data is 'dirty'? That way, I can minimize my transactions to those that are neccessary. I could roll my own with standard comparison, but this is one of those cases where I feel I'm about to poorly re-implement the proverbial wheel.
Thank you Monks.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Tracking records to change/insert during CGI
by salvix (Pilgrim) on Oct 17, 2005 at 18:58 UTC | |
|
Re: Tracking records to change/insert during CGI
by InfiniteSilence (Curate) on Oct 17, 2005 at 17:34 UTC | |
by pboin (Deacon) on Oct 17, 2005 at 17:52 UTC | |
by ryantate (Friar) on Oct 17, 2005 at 21:10 UTC | |
by kiat (Vicar) on Oct 18, 2005 at 16:11 UTC | |
|
Re: Tracking records to change/insert during CGI
by shemp (Deacon) on Oct 17, 2005 at 17:46 UTC | |
|
Re: Tracking records to change/insert during CGI
by shiza (Hermit) on Oct 17, 2005 at 23:02 UTC |