Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

ASP.NET Forum


You are currently viewing our ASP.NET Forum as a guest. Please register to participate.
Login



Reply
how we can empty the table or database in ASP
Old 12-12-2005, 03:37 AM how we can empty the table or database in ASP
faisalzafar's Avatar
Experienced Talker

Posts: 41
Location: Pakistan
Trades: 0
Hi dear,

I have one application in ASP with Access database and i want to empty the database, can i do that ??


Regards
Faisal Zafar
__________________
[COLOR=Pink]Faisal Zafar[/COLOR]
faisalzafar is offline
Reply With Quote
View Public Profile Visit faisalzafar's homepage!
 
 
Register now for full access!
Old 12-12-2005, 04:24 AM
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,517
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
empty the entire db or empty the tables ?
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 12-12-2005, 09:08 AM
faisalzafar's Avatar
Experienced Talker

Posts: 41
Location: Pakistan
Trades: 0
any one ? i want the tables and also empty the database , can u plz define both ways
Regrads
__________________
[COLOR=Pink]Faisal Zafar[/COLOR]
faisalzafar is offline
Reply With Quote
View Public Profile Visit faisalzafar's homepage!
 
Old 12-12-2005, 11:07 AM
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,517
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
you can't empty the database but keep the tables, emptying the database would remove all the tables

I'll assume you want to keep the tables and the db structures intact but just remove the records.

To remove all records from a table you use;

Code:
TRUNCATE TABLE table_name
this will also set any autonumbers back to the initial value

you can also use
Code:
DELETE FROM table_name
to empty the database use;

Code:
DROP TABLE table_name
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Reply     « Reply to how we can empty the table or database in ASP
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.27522 seconds with 12 queries