What is the difference between a heap table and temporary table?



What is the difference between a heap table and temporary table?..

Answer / Shikha Kushwaha

A heap table is an unordered table in MySQL that stores data without any specific order. Heap tables do not have a clustered index, so the data is organized only by its physical location. A temporary table, on the other hand, is created for the lifetime of a connection or a single query execution and exists solely to store intermediate results during query processing. Temporary tables are typically sorted and indexed, improving query performance.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More MySQL Interview Questions

Is mysql a backend?

1 Answers  


What is an index? How can an index be declared in mysql?

1 Answers  


What is the limit of mysql database?

1 Answers  


What does blob mean in mysql?

1 Answers  


How do you start MySQL on Linux?

3 Answers  


How we can get distinct columns values in mysql?

1 Answers  


How to see the create table statement of an existing table?

1 Answers  


Write a query to create a database and a table?

1 Answers  


Where MyISAM table will be stored and also give their formats of storage?

1 Answers  


SQL is not case sensitive. DELETE is the same as delete. State Whether True or False?

1 Answers  


The structure of table view buyers is as follows: +----------------+-------------+------+-----+---------+----- -----------+ | Field | Type | Null | Key | Default | Extra | +----------------+-------------+------+-----+---------+----- -----------+ | user_pri_id | int(15) | | PRI | NULL | auto_increment | | userid | varchar(10) | YES | | NULL | | +----------------+-------------+------+-----+---------+----- -----------+ the value of user_pri_id the last row 2345 then What will happen in the following conditions? Condition1: Delete all the rows and insert another row then. What is the starting value for this auto incremented field user_pri_id , Condition2: Delete the last row(having the field value 2345) and insert another row then. What is the value for this auto incremented field user_pri_id

2 Answers  


Why do we write stored procedures?

1 Answers  


Categories