View Full Version : add, edit, and delete

01-13-2003, 09:35 PM
How do add, edit, delete a database via asp or database? A code example by chance.

01-14-2003, 12:42 AM
What you need is SQL (Structured Query Language). You might want to check out this tutorial:


That will give you the syntax you need for that, as well as a basic understanding of relational databases (sounds hard, but it's very easy).

Also, you might want to check out the basic login/registration script I wrote here:


As it has some code in the comments directly related to your question, and also uses the tool from the tutorial above as an example, i.e.

create table mytable(id autonumber, firstname text, lastname text)

update mytable set firstname = 'John', lastname = 'Smith' where id = 1

delete from mytable where id = 1

' new record
insert into mytable (firstname,lastname) values ('John','Smith')

Don't ever forget the "where blah = blah" (generally called the "where clause") on update and delete statements, since if not specified they will update ALL the records without prejudice. :eek:

I'm sure you can find plenty of SQL tutorials as well by a google search.


01-14-2003, 02:50 PM
Thank you for you assistance. I will try that.

The Wizzard
01-14-2003, 03:55 PM
This is perfect for you...