Advertisement
S_Madanska

datetime

Oct 21st, 2020
140
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. CREATE TABLE DATES
  2. (
  3.     Column_for_dates DATETIME NOT NULL
  4. )
  5.  
  6. INSERT INTO DATES(Column_for_dates) VALUES ('21-10-2020 10:30' )
  7.  
  8. SELECT * FROM DATES
  9.  
  10. SELECT GETDATE()
  11.  
  12. INSERT INTO DATES(Column_for_dates) VALUES ('2020-10-22 10:30')
  13. INSERT INTO DATES(Column_for_dates) VALUES (CONVERT (DATETIME, '21-10-2020 10:30', 105))
Advertisement
RAW Paste Data Copied
Advertisement