June 10, 2019

Srikaanth

EPAM Systems MySQL Interview Questions Answers

EPAM Systems Most Frequently Asked Latest MySQL Interview Questions Answers

What Is The Difference Between Heap Table And Temporary Table?

Heap tables:

Heap tables are found in memory. They are used for high speed storage on temporary basis. They do not allow BLOB or TEXT fields.
Heap tables do not support AUTO_INCREMENT.
Indexes should be NOT NULL.
Temporary tables:

The temporary tables are used to keep the temporary data. Sometimes it is very useful in cases to keep temporary data. Temporary table is deleted after current client session terminates.
Main differences:

The heap tables are shared among clients while temporary tables are not shared.
Heap tables are just another storage engine, while for temporary tables you need a special privilege (create temporary table).

What Is The Difference Between Float And Double?


FLOAT stores floating point numbers with accuracy up to 8 places and allocates 4 bytes, on the other hand DOUBLE stores floating point numbers with accuracy up to 18 places and allocates 8 bytes.
EPAM Systems Most Frequently Asked Latest MySQL Interview Questions Answers
EPAM Systems Most Frequently Asked Latest MySQL Interview Questions Answers

What Are The Advantages Of Mysql In Comparison To Oracle?

MySQL is a free, fast, reliable, open source relational database while Oracle is expensive, although they have provided Oracle free edition to attract MySQL users.
MySQL uses only just under 1 MB of RAM on your laptop while Oracle 9i installation uses 128 MB.
MySQL is great for database enabled websites while Oracle is made for enterprises.
MySQL is portable.

What Are The Disadvantages Of Mysql?


MySQL is not so efficient for large scale databases.
It does not support COMMIT and STORED PROCEDURES functions version less than 5.0.
Transactions are not handled very efficiently.

What Is The Difference Between Mysql_connect And Mysql_pconnect?


Mysql_connect:

It opens a new connection to the database.
Every time you need to open and close database connection, depending on the request.
Opens page every time when it loaded.
Mysql_pconnect:

In Mysql_pconnect, "p" stands for persistent connection so it opens the persistent connection.
the database connection can not be closed.
it is more useful if your site has more traffic because there is no need to open and close connection frequently and every time when page is loaded.

Which Command Is Used To View The Content Of The Table In Mysql?

The SELECT command is used to view the content of the table in MySQL.

What Is The Usage Of I-am-a-dummy Flag In Mysql?

In MySQL, the i-am-a-dummy flag makes the MySQL engine to deny the UPDATE and DELETE commands unless the WHERE clause is present.

What Is The Usage Of Regular Expressions In Mysql?

In MySQL, regular expressions are used in queries for searching a pattern in a string.

* Matches 0 more instances of the string preceding it.
+ matches 1 more instances of the string preceding it.
? Matches 0 or 1 instances of the string preceding it.
. Matches a single character.
[abc] matches a or b or z
| separates strings
^ anchors the match from the start.
"." Can be used to match any single character. "|" can be used to match either of the two strings
REGEXP can be used to match the input characters with the database.
Example:
The following statement retrieves all rows where column employee_name contains the text 1000 (example salary):

Select employee_name
From employee
Where employee_name REGEXP '1000'
Order by employee_name

How Do You Determine The Location Of Mysql Data Directory?


The default location of MySQL data directory in windows is C:mysqldata or C:Program FilesMySQLMySQL Server 5.0 data.

What Is Mysql Data Directory?

MySQL data directory is a place where MySQL stores its data. Each subdirectory under this data dictionary represents a MySQL database. By default the information managed my MySQL = server mysqld is stored in data directory.

What Is The Use Of Mysql_close()?

Mysql_close() cannot be used to close the persistent connection. Though it can be used to close connection opened by mysql_connect().

How Is Myisam Table Stored?

MyISAM table is stored on disk in three formats.

'.frm' file : storing the table definition
'.MYD' (MYData): data file
'.MYI' (MYIndex): index file

What Is The Usage Of Enums In Mysql?


ENUMs are used to limit the possible values that go in the table:

For example: CREATE TABLE months (month ENUM 'January', 'February', 'March'); INSERT months VALUES ('April').

What are ENUMs used for in MySQL?

ENUM is used to limit the possible values and store it together. It is a function that can be created to store the similar values together. It is used in creation of table.

The syntax of it is as follows:
CREATE TABLE months (month ENUM “January”, “February”, “March”,…);
INSERT months VALUES (“April”);

What is the purpose of -> in the MySQL terminal?

-> prompt in the command of MySQL indicates that a single statement is being entered across multiple lines. From this prompt MySQL interprets that you haven’t finished entering the statements. It has no impact of enter which you might press to go to the next line. MySQL will execute the statement only when you will insert the semicolon in the end which it recognizes.

How to find the unique values if the value in the column is repeated?

If the values in the column of a table are repeating and a unique value has to be found then the following command can be used in the query:
SELECT DISTINCT user_firstname FROM users;

There is another command which can be used to find the command to see the distinct values as:
SELECT COUNT (DISTINCT user_firstname) FROM users;

https://mytecbooks.blogspot.com/2018/10/epam-systems-most-frequently-asked.html
Subscribe to get more Posts :