How can I insert a date into db2 in this format: yyyy-mm-dd
, using a sql query?
Consider a table:
CREATE TABLE tab (dt DATE);
Now insert a date into it as:
INSERT INTO tab VALUES ('2010-12-31');
Now on doing
SELECT * from tab;
we get:
DT
2010-12-31
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With