让mysql快速兼容postgresql

CREATE DEFINER=`root`@`192.168.1.%` FUNCTION `to_char`(`date` datetime,`format` VARCHAR(20)) RETURNS date
BEGIN
	#Routine body goes here...

	RETURN  date_format(date, '%Y-%m-%d');
END

猜你喜欢

转载自jadeluo.iteye.com/blog/2308075