How many ways we can we find the current date using MySQL?

Answers were Sorted based on User's Feedback



How many ways we can we find the current date using MySQL?..

Answer / ismail

SELECT CURDATE(),SELECT CURRENT_DATE(),SELECT CURTIME(),
SELECT CURRENT_TIME(),SELECT now().

Is This Answer Correct ?    23 Yes 1 No

How many ways we can we find the current date using MySQL?..

Answer / rajan vardawaj

SELECT CURDATE(); SELECT CURRENT_DATE(); SELECT CURTIME();
SELECT CURRENT_TIME();

Is This Answer Correct ?    17 Yes 1 No

How many ways we can we find the current date using MySQL?..

Answer / vikas d.k. gupta

To get the Current Date:-
1. SELECT CURDATE();
2. SELECT CURRENT_DATE();
To get the Current Time:-
1. SELECT CURTIME();
2. SELECT CURRENT_TIME();
To get both at the same time:-
1. SELECT NOW();
2. SELECT SYSDATE();

Is This Answer Correct ?    4 Yes 0 No

Post New Answer

More MySQL Interview Questions

Explain the difference between mysql and mysql interfaces in php?

1 Answers  


What is a data directory?

1 Answers  


Which one of the following is the correct way to select all columns and all rows from "vtable"? Choice 1 SELECT FROM vtable SELF JOIN vtable Choice 2 SELECT ALL COLUMNS FROM vtable WHERE ALL ROWS = * Choice 3 SELECT EVERYTHING FROM vtable Choice 4 SELECT vtable.* WHERE vtable = vtable Choice 5 SELECT * FROM vtable WHERE 1 = 1

3 Answers  


Consider you have the following three tables which have to be linked together.

1 Answers  


What is mysql database used for?

1 Answers  


How does mysql store binary data?

1 Answers  


write a command to view the content of the table

1 Answers  


Is mysql from oracle?

1 Answers  


How do I fix a crashed mysql database?

1 Answers  


How do you control the max size of a HEAP table?

1 Answers  


Can I use mariadb instead of mysql?

1 Answers  


How do I backup mysql database on linux?

1 Answers  


Categories