ORACLE:
Familiar with system time: Select sysdate from dual time type acquisition;
Select to_char (sysdate, 'yyyy-mm-dd hh24: MI: ss') from dual; obtained in string form
DB2:
Select current timestamp from sysibm. sysdummy1 get system time
And
Select current date from sysibm. sysdummy1; get the date
Select current time from sysibm. sysdummy1; obtain the time
SQL Server:
Use getdate ()
SQL Server has very powerful date functions:
Select convert (varchar (100), getdate (), 0): 05 16 2008 AM
Select convert (varchar (100), getdate (), 1): 05/16/08
Select convert (varchar (100), getdate (), 2): 08.05.16
Select convert (varchar (100), getdate (), 3): 16/05/08
Select convert (varchar (100), getdate (), 4): 16.05.08
Select convert (varchar (100), getdate (), 5): 16-05-08
Select convert (varchar (100), getdate (), 6): 16 05 08
Select convert (varchar (100), getdate (), 7): 05 16, 08
Select convert (varchar (100), getdate (), 8): 10:57:46
Select convert (varchar (100), getdate (), 9): 05 16 2008 10: 57: 46: 827am
Select convert (varchar (100), getdate (), 10): 05-16-08
Select convert (varchar (100), getdate (), 11): 08/05/16
Select convert (varchar (100), getdate (), 12): 080516
Select convert (varchar (100), getdate (), 13): 16 05 2008 10: 57: 46: 937
Select convert (varchar (100), getdate (), 14): 10: 57: 46: 967
Select convert (varchar (100), getdate (), 20): 10:57:47
Select convert (varchar (100), getdate (), 21): 10:57:47. 157
Select convert (varchar (100), getdate (), 22): 05/16/08 10:57:47 AM
Select convert (varchar (100), getdate (), 23 ):
Select convert (varchar (100), getdate (), 24): 10:57:47
Select convert (varchar (100), getdate (), 25): 10:57:47. 250
Select convert (varchar (100), getdate (), 100): 05 16 2008 AM
Select convert (varchar (100), getdate (), 101): 05/16/2008
Select convert (varchar (100), getdate (), 102): 2008.05.16
Select convert (varchar (100), getdate (), 103): 16/05/2008
Select convert (varchar (100), getdate (), 104): 16.05.2008
Select convert (varchar (100), getdate (), 105): 16-05-2008
Select convert (varchar (100), getdate (), 106): 16 05 2008
Select convert (varchar (100), getdate (), 107): 05 16,200 8
Select convert (varchar (100), getdate (), 108): 10:57:49
Select convert (varchar (100), getdate (), 109): 05 16 2008
10: 57: 49: 437am ......
MySQL:
Select now ();
Output 09-12-25