when i declare date data type in sql ,i inserted the date
22-10-2012,but my result is in different date 1894-07-11 any
one pls help me what's wrong in my query
Create table orders(od_id int,od_name varchar(10),od_date
date)
insert into orders values(1,'sai',22-10-2012) and any one
pls suggest what i can learn for 3 years real time
experenice in sql because i am looking for database field
Answer Posted / lakshmi
The default date format in sql is 'yyyy-mm-dd' but in the query that is in dd-mm-yyyy and without single quotes. Below is the insert query.
insert into orders values(1,'sai','2012-10-22');
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
How do I start and stop mysql on windows?
What do you need to connect php to mysql?
Explain what is mysql?
What is the default password for mysql?
What are Heap tables?
What is difference between mysql and mysql server?
What is the maximum number of columns per table?
How to get a list of indexes of an existing table?
What is mysql in dbms?
What data type is money?
How to create a new view in mysql?
How to Set a root password if there is on root password.
How can I create a database in mysql?
How do I clear the command in mysql?
What is sql vs mysql?