private SqlString ToString(SqlDateTime dateTime) { if (dateTime.IsNull) { return(SqlString.Null); } if (TypeCode == SqlTypeCode.Date) { return(dateTime.ToDateString()); } if (TypeCode == SqlTypeCode.Time) { return(dateTime.ToTimeString()); } if (TypeCode == SqlTypeCode.TimeStamp) { return(dateTime.ToTimeStampString()); } return(SqlString.Null); }
private SqlString ToString(SqlDateTime dateTime) { if (dateTime.IsNull) return SqlString.Null; if (TypeCode == SqlTypeCode.Date) return dateTime.ToDateString(); if (TypeCode == SqlTypeCode.Time) return dateTime.ToTimeString(); if (TypeCode == SqlTypeCode.TimeStamp) return dateTime.ToTimeStampString(); return SqlString.Null; }