SQL NOW

NOW function returns the date and time.

Syntax NOW function

SELECT NOW() FROM table

NOW SQL Example

Given the following table 'products'

idproductprice
1computer1200.25
2printer65.57
3keyboard10.84

If we know the prices of the products to date

SELECT product, price, NOW() AS date FROM products

The result will be:

productpricedate
computer900.2510/2/2012 10:15:42 AM
printer65.5710/2/2012 10:15:42 AM
keyboard10.8410/2/2012 10:15:42 AM