Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


What is the difference between Drop and Truncate

Answers were Sorted based on User's Feedback



What is the difference between Drop and Truncate..

Answer / arjun tailor

drop command will delete the entire row also the structure
but truncate will delete the contents only not the
structure.

Is This Answer Correct ?    3 Yes 1 No

What is the difference between Drop and Truncate..

Answer / ferolin j

DROP TABLE- all the relationships with other tables will
no longer be valid, the integrity constraints will be
dropped, grant or access privileges on the table will also
be dropped, if want use the table again it has to be
recreated with the integrity constraints, access privileges
and the relationships with other tables should be
established again.

TRUNCATE TABLE- the table structure remains the same, ONLY
deletes the data.

Is This Answer Correct ?    2 Yes 0 No

What is the difference between Drop and Truncate..

Answer / agnel

* A truncate removes all rows from a tablethat operation
cant be rolled back.
* A drop command removes a table from a database all the
tables rows indexes and privilleges will also be removed.

Is This Answer Correct ?    1 Yes 0 No

What is the difference between Drop and Truncate..

Answer / meera

Drop: delete all data as well as structure.

Truncate: Delete only the data and resets the auto increment
column to 0.

Delete: Delete the selected or all rows from the table , it
doesn't reset to auto increment .

Is This Answer Correct ?    1 Yes 0 No

What is the difference between Drop and Truncate..

Answer / madhu

drop will delete the entier table content including its
structure.
but truncate will delete the datas which in the table.

it wont save the data any where so we cannot rollback those
data.

Is This Answer Correct ?    1 Yes 0 No

What is the difference between Drop and Truncate..

Answer / tamilarasan sivaraj

DROP:It is used to delete the all structure of the db and
also we cant rollback.
EXAMPLE:Drop table student;
It will show error.No table found.

TRUNCATE:It is used to delete the table of the data and
structure remains,we can able to rollback.
EXAMPLE:truncate table student;

No records found;

Is This Answer Correct ?    1 Yes 0 No

What is the difference between Drop and Truncate..

Answer / antim

both are ddl commands.Drop deletes the table with schema
and records but truncate deletes only records.Drop can be
roll back but not truncate.

Is This Answer Correct ?    7 Yes 9 No

What is the difference between Drop and Truncate..

Answer / manisha

Truncate removes data permanently while drop does not,we
can rollback in case of drop.

Triggers does not get fired , in case of truncate ,but in
drop it gets fired.
truncate is much faster than drop

Is This Answer Correct ?    4 Yes 11 No

What is the difference between Drop and Truncate..

Answer / swathi

drop will remove the entire table from the database and can
be rollbacked.

truncate will remove the content of the table and it cannot
be rollbacked.

truncate is little bit faster than drop.

Is This Answer Correct ?    4 Yes 14 No

What is the difference between Drop and Truncate..

Answer / satyanarayana

Drop and Truncate commands both are DML commands.
If we use drop command it will deletes all the table data
as well as tablestructure.But if we use truncate command it
will deletes the table data only.

Is This Answer Correct ?    24 Yes 44 No

Post New Answer

More SQL Server Interview Questions

What happens if you insert a duplicate key for the primary key column in ms sql server?

0 Answers  


What are the main differences between #temp tables and @table variables and which one is preferred?

0 Answers  


1. SELECT SUM(sal) as “Gross Salary” from EMPLOYEES; 2. SELECT MAX(sal) as “Highest Salary” from EMPLOYEES; ouput should be in table format

2 Answers  


Explain what are the events recorded in a transaction log?

0 Answers  


what is extended StoreProcedure ?

3 Answers   Satyam,


What is the difference between the 2 operating modes of database mirroring?

0 Answers  


What is the user of Primary key?

0 Answers  


What is an execution plan? How would you view the execution plan?

0 Answers  


Differentiate between sql temp table vs table variable?

0 Answers  


You have a stored procedure, which execute a lengthy batch job. This stored procedure is called from a trigger you do not want to slow the data entry process you do not want trigger to wait for this batch job to finish before it completes itself what you can do to speed up the process?

0 Answers  


How can you get @@error and @@rowcount at the same time?

9 Answers  


How to disconnect from a sql server using mssql_close()?

0 Answers  


Categories