ASP 101 - Active Server Pages 101 - Web04
The Place ASP Developers Go!

Please visit our partners


Windows Technology Windows Technology
15 Seconds
4GuysFromRolla.com
ASP 101
ASP Wire
VB Forums
VB Wire
WinDrivers.com
internet.commerce internet.commerce
Partners & Affiliates














ASP 101 is an
internet.com site
ASP 101 is an internet.com site
IT
Developer
Internet News
Small Business
Personal Technology

Search internet.com
Advertise
Corporate Info
Newsletters
Tech Jobs
E-mail Offers

ASP 101 News Flash ASP 101 News Flash




Script Output:

Record id 1168744 added!

id text_field integer_field date_time_field
1168734 Tuesday 13 4/13/2010 12:56:55 PM
1168735 Tuesday 13 4/13/2010 12:57:01 PM
1168736 Tuesday 13 4/13/2010 12:57:01 PM
1168737 Tuesday 13 4/13/2010 12:57:26 PM
1168738 Tuesday 13 4/13/2010 12:57:26 PM
1168739 Tuesday 13 4/13/2010 12:57:26 PM
1168740 Tuesday 13 4/13/2010 12:57:26 PM
1168741 Tuesday 13 4/13/2010 12:57:26 PM
1168742 Tuesday 13 4/13/2010 1:20:17 PM
1168743 Tuesday 13 4/13/2010 1:35:26 PM
1168744 Tuesday 13 4/13/2010 1:51:42 PM

ASP HTML Download            FAQ

ASP.NET Version

The last record in the table above was just added when you loaded this page!

Click here to add another record to the database.


This is the first in a set of 3 database samples. The series will cover, inserting, deleting, and updating a table in a database. Being the first of the three, this one is commented the most heavily and should be read before the other two since much of the code is similar between the three. As with all our samples, these are placed here as a service to our readers and as a learning aid. They are not necessarily ready for live use on your site and you should thoroughly test them if you intend to use them on your site. This set of three especially is placed here to show you one way to accomplish the tasks covered. There are other methods which may give you better performance and scalability based upon your particular situation.

Another thing to note is that in order to keep this database reasonable, the script automatically purges old records when the database reaches about a dozen records. If you see entries disappear, appear, or change, it is most likely due to the fact that you've reached this limit. Please note that it is also likely that others may be viewing either this sample or one of the other two samples which share the same table in the database at the same time you are viewing this one. This also will cause changes to the database resulting in entries which you may not be expecting to see. Ah, the wonderful world of concurrent users!

This sample is running off of our SQL Server, but a copy of the database in Access format is available for download here.

Part 1  Part 2  Part 3


Samples

Home |  News |  Samples |  Articles |  Lessons |  Resources |  Forum |  Links |  Search |  Feedback


The Network for Technology Professionals

Search:

About Internet.com

Legal Notices, Licensing, Permissions, Privacy Policy.
Advertise | Newsletters | E-mail Offers