Monday, October 6, 2014

Linux Interview Question and Answer - Mysql part 1

12:45 PM



1. State some of the features of MYSQL?

Some of the features presented by MYSQL are
Multiple storage engines, Native storage engines, Partner developed storage engines, custom storage engines, community developed storage engines and commit grouping.
Some of these features present in MYSQL are not present in most popular RDBMS.


2. State some of the disadvantages present in MYSQL?

MYSQL standard has diverted on the standards of implementation of Null and default values. Arithmetic operations are susceptible to integer over flow. Mode of operation of SQL is set to unusual tolerant state which developers hate.

3. What happens when we don’t use Console option?

If console option is not present or used during the start of MYSQL then all the output will be written to the error log file. It is always better to use the console option because it reduces problem on the server. Error log file will be stored with an extension .err. Any text editor can read this file.

4. How to create MYSQL new users?

There are many different ways to establish users and privileges in MYSQL. Client and GRANT command assure you about a safe connection. The syntax for establishing new users and privileges is as follows
GRANT privileges ON database.* TO
‘username’@’hostname’ This can be identified by the password. Privileges can be assigned one by one or by specifying all.


5. Explain about the rules which should be followed while assigning a username?

A username has a maximum length of 16 characters. Spaces should be avoided while creating username because they are case sensitive. Hostname will be the computer from which you are going to connect. The best way to specify a username is to connect through a local host.

6. Explain about a security flaw which is present while creating a username?

Naming MYSQL databases has to be very careful because any database starting with the test name can be accessed by every one on the network. Make sure that you don’t start the databases naming with test. It should be used only for experimental purposes only.

7. State some security recommendations while using MYSQL?

Some of the security recommendations which should be followed while using MYSQL are as follows: -
1) Minimal privileges to users in the network.
2) Super and process privileges should be granted minimally.
3) File privileges should be granted minimally to administrators.
4) Validation of data and queries should be thoroughly checked.


8. Explain about database design?

Database design is also called as Data modeling. It is used for long-term management of database. This process is used to store information and to keep data for long term. Creating an efficient structure helps you to channelize information into good channels.

9. Explain about creating database?    

CREATE DATABASE command will create you a database with the assigned name by the user. This is an optional statement but when you actually assign a name it checks for similarity and gives error if it encounters one. CREATE DATABASE models help you to create classic models.

10. Explain about primary keys?

MYSQL allows only one primary key. This primary key can be used on multiple tables. There are many rules which should be followed such as it shouldn’t be null and it can never change. Primary key assigned should be unique it cannot be matched with any other keys.

11. Explain about normalization?

Applying specific rules (normal forms) to the database is the primary process. These rules should be applied in the order specified starting with the first normal form. These rules should be adhered by every database they are
1) Each column should have only one value
2) Repeating columns of data cannot be done.


12.  State two considerations which can improve the performance of MYSQL?

Two considerations which can improve the performance of MYSQL are as follows: -
1) Fixed length fields take up more space than variable length fields but they are a bit faster.
2) Size of the field should be restricted to the smallest possible value based upon the largest input value.


13. Explain about the time stamp field?

TIMESTAMP filed occurs when an INSERT and UPDATE field occurs when there is no value specified for the field. There are many behaviors for TIMESTAMP field and it depends upon the version of MYSQL.

14. Explain about MyISAM table?

This feature is a default type for tables. This table is not so much considered for transactions because it is not considered as safe but this kind of table is very fast in execution. The maximum key length is 1024 bytes and 64 keys per table. Size of this table entirely depends upon the operating system.

15. Explain about HEAP table?

 This type of table is stored in the memory. Speed of execution of this table is very commendable. There are associated disadvantages associated with this table the primary one being loss of stored memory which occurs when there is power failure and can cause the server to run out of memory. Columns with AUTO_INCREMENT, TEXT characteristics and BLOB are not supported.

Written by

0 comments :

Post a Comment

 

© 2014 Linux Storages | Updated . All rights resevered. Designed by Templateism