如题

解决方案 »

  1.   

    Date functionReturns the current date.DateDelta constantSpecifies the correction factor when computing the difference between two date and time types that do not begin in the same year.DateTimeToFileDate functionConverts a TDateTime object to a DOS date-and-time value.DateTimeToStr functionConverts a TDateTime value to a string.DateTimeToString procedureConverts a TDateTime value to a string using a specified Format.DateTimeToSystemTime procedureConverts a TDateTime value into the Win32 API's TSystemTime type.DateTimeToTimeStamp functionConverts a TDateTime value into the corresponding TTimeStamp value.DateToStr functionConverts a TDateTime value to a string.DayOfWeek functionReturns the day of the week for a specified date.DecodeDate procedureReturns Year, Month, and Day values for a TDateTime value.DecodeTime procedureBreaks a TDateTime value into hours, minutes, seconds, and milliseconds.EncodeDate functionReturns a TDateTime value that represents a specified Year, Month, and Day.EncodeTime functionReturns a TDateTime value for a specified Hour, Min, Sec, and MSec.FormatDateTime functionFormats a TDateTime value.IncMonth functionReturns a date shifted by a specified number of months.IsLeapYear functionIndicates whether a specified year is a leap year.MSecsPerDay constantSpecifies the number of milliseconds per day.MSecsToTimeStamp functionConverts a specified number of milliseconds into a TTimeStamp value.Now functionReturns the current date and time.ReplaceDate procedureReplaces the date portion of a TDateTime value with a specified date.ReplaceTime procedureReplaces the time portion of a TDateTime value with a specified time.SecsPerDay constantIndicates the number of seconds per day.StrToDate functionConverts a string to a TDateTime value.StrToDateTime functionConverts a string to a TDateTime value.StrToTime functionConverts a string to a TDateTime value.SystemTimeToDateTime functionConverts a TSystemTime value into a TDateTime value.Time functionReturns the current time.TimeStampToDateTime functionConverts a TTimeStamp value into the corresponding TDateTime value.TimeStampToMSecs functionConverts a TTimeStamp value into an absolute number of milliseconds.TimeToStr functionReturns a string that represents a TDateTime value.
      

  2.   

    delphi:  formatdatetime('yyyy-mm-dd',now) ;
       SQL:  getdate();  or convert(char(10),getdate(),20)