Top 20 Mysql Interview Questions and Answers
Q1. Mysql - Speed Of Delete Queries ?
If you have any desire to erase all lines in the table, you ought to utilize TRUNCATE TABLE table_name. An opportunity to erase a record is precisely corresponding to the quantity of files. To erase records all the more rapidly, you can build the size of the file store.
Q2. What Happens If A Table Has One Column Defined As Timestamp?
That field gets the current timestamp at whatever point the column gets adjusted.
Q3. How Would You Change A Column From Varchar(10) To Varchar(50)?
Modify TABLE techpreparation_questions CHANGE techpreparation_content techpreparation_CONTENT VARCHAR(50).
Q4. How Do You Control The Max Size Of A Heap Table?
MySQL config variable max_heap_table_size.
Q5. What Are Enums Used For In Mysql?
You can restrict the potential qualities that go into the table. Make TABLE months (month ENUM 'January', 'February', 'Walk',… ); INSERT months VALUES ('April');
Q6. Why Sql Is A Database Management System?
A data set is an organized assortment of information. It very well might be anything from a basic shopping rundown to an image display or the huge measures of data in a corporate organization. To add, access, and cycle information put away in a PC data set, you really want a data set administration framework like MySQL. Since PCs are truly adept at dealing with a lot of information, data set administration assumes a focal part in figuring, as independent utilities, or as parts of different applications.
Q7. Make sense of The Difference Between Bool, Tinyint And Bit. ?
Before MySQL 5.0.3: those are equivalents. After MySQL 5.0.3: BIT information type can store 8 bytes of information and ought to be utilized for twofold information.
Q8. Why Use Mysql?
MySQL is extremely quick, solid, and simple to utilize. In the event that that is the thing you are searching for, you ought to check it out. MySQL likewise has an extremely down to earth set of highlights created in exceptionally close participation with our clients. You can find a presentation correlation of MySQL to some other data set directors on our benchmark page. See segment 12.7 Using Your Own Benchmarks. MySQL was initially evolved to deal with extremely huge data sets a lot quicker than existing arrangements and has been effectively utilized in exceptionally requesting creation conditions for quite some time. However under consistent turn of events, MySQL today offers a rich and extremely valuable arrangement of capacities. The availability, speed, and security make MySQL profoundly appropriate for getting to information bases on the Internet.
Q9. How Would You Change A Table To Innodb?
Modify TABLE techpreparation_questions ENGINE innodb;
Q10. How Do You Start And Stop Mysql On Windows?
net beginning MySQL, net stop MySQL
Q11. Assuming You Specify The Data Type As Decimal (5,2), What's The Range Of Values That Can Go In This Table?
999.99 to - 99.9@Note that with the negative number the short sign is viewed as one of the digits.
Q12. Make sense of The Difference Between Myisam Static And Myisam Dynamic. ?
In MyISAM static every one of the fields have fixed width. The Dynamic MyISAM table would incorporate fields like TEXT, BLOB, and so on to oblige the information types with different lengths. MyISAM Static would be simpler to reestablish if there should be an occurrence of debasement, since despite the fact that you could lose a few information, you know precisely where to search for the start of the following record.
Q13. What Is Primary Key?
An essential key is a solitary section or various segments characterized to have exceptional qualities that can be utilized as column IDs.
Q14. Might You at any point Save Your Connection Settings To A Conf File?
Indeed, and name it ~/.my.conf. You should change the consents on the document to 600, so that it's not discernible by others.
Q15. Make sense of The Difference Between Float, Double And Real. ?
FLOATs store drifting point numbers with 8 spot exactness and take up 4 bytes.
Duplicates store drifting point numbers with 16 spot exactness and take up 8 bytes.
Genuine is an equivalent word of FLOAT until further notice.
Q16. What Does - I'm a-faker Flag To Do When Starting Mysql?
Makes the MySQL motor deny UPDATE and DELETE orders where the WHERE proviso is absent.
Q17. What Does Tee Command Do In Mysql?
tee followed by a filename turns on MySQL logging to a predefined record. It tends to be come by order note.
Q18. How Do You Start Mysql On Linux?
/and so forth/init.d/mysql start
Q19. What Is Csv?
CSV (Comma Separated Values) is a document design used to store data set table items, where one table column is put away as one line in the record, and every information field is isolated with comma.
Q20. How Might You See All Indexes Defined For A Table?
SHOW INDEX FROM techpreparation_questions;
