How can I insert a date in db2 in this format: yyyy-mm-ddusing sql query?
yyyy-mm-dd
Consider the table:
CREATE TABLE tab (dt DATE);
Now enter the date in it as:
INSERT INTO tab VALUES ('2010-12-31');
Now at execution
SELECT * from tab;
we get:
DT 2010-12-31