Wrox Programmer Forums
|
Classic ASP Databases Discuss using ASP 3 to work with data in databases, including ASP Database Setup issues from the old P2P forum on this specific subtopic. See also the book forum Beginning ASP.NET Databases for questions specific to that book. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old March 19th, 2004, 01:02 AM
Authorized User
 
Join Date: Mar 2004
Posts: 29
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Are bookmarks commonly used to uniquely identify records? They seem to be objects, and not
exactly unique numbers. So, if I wanted to send some data using POST, such as a record ID,
I couldn't exactly send a bookmark. And it seems some recordset objects don't support them.

Do most people, in general, use a special column, to store unique IDs for records? Such
as an auto-increment column?

 
Old March 19th, 2004, 06:09 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 1,212
Thanks: 0
Thanked 1 Time in 1 Post
Default

No, bookmarks are not used to uniquely identify records, that is the job of the primary key field(s). If you need to pass info around to identify a particular record then you need to pass around the primary key value(s).

Your question "Do most people, in general, use a special column, to store unique IDs for records? Such as an auto-increment column?" can be the subject of religious wars. Some people believe in this method, others (myself included) believe in using a natural key wherever possible.

Whichever way you choose to go, the important thing is that you uniquely identify each row by some form of primary key (whether that be a natural key or a generated key), not by a record's position.

hth
Phil
 
Old March 19th, 2004, 01:46 PM
Authorized User
 
Join Date: Mar 2004
Posts: 29
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks for the info. I wasn't aware of it. :)

I was kind of forced to use the auto-increment key design because it was one of the first examples of a simple database editor I found on the web. But, natural keys seem like a better choice. Found some articles comparing the two.

 
Old March 19th, 2004, 02:02 PM
Authorized User
 
Join Date: Mar 2004
Posts: 29
Thanks: 0
Thanked 0 Times in 0 Posts
Default

That is to say, they seem to be a better choice (for my purposes). :)







Similar Threads
Thread Thread Starter Forum Replies Last Post
Search in Database????? Samora C# 2 October 10th, 2007 07:41 AM
Fastest visualization Julew .NET Framework 2.0 0 July 23rd, 2007 11:01 AM
how to search in database saif44 ASP.NET 2.0 Professional 11 March 8th, 2006 03:33 PM
need help, to Search from database vikky17 Classic ASP Basics 1 February 5th, 2006 12:35 AM
Fastest way to my book's forum? ababb Forum and Wrox.com Feedback 1 December 16th, 2004 10:38 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.