Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
werseyjersey
Starting Member
47 Posts |
Posted - 2008-09-10 : 09:25:06
|
I have a stored procedure that pulls in a datetime and I am trying to convert it to time ONLY I have tried the following but it doesn't seem to like it. I have tried other versions of this also but can't seem to get it to work your help will be appreciated:SELECT DISTINCT PayrollMaster.PayrollEnd = (CONVERT(VarChar(10), PayrollMaster.PayrollEnd, 101))FROM lu_payrolltype INNER JOIN PayrollMaster ON lu_payrolltype.CCC = PayrollMaster.CCC INNER JOIN lu_ftereporttype ON lu_payrolltype.ftereporttypeid = lu_ftereporttype.ftereporttypeidWHERE lu_payrolltype.ftereporttypeid = '1' Thanks for the help!werseyjersey |
|
werseyjersey
Starting Member
47 Posts |
Posted - 2008-09-10 : 09:35:38
|
GOT it thanks: SELECT CONVERT(VarChar(10), ADP_PayrollMaster.PayrollEnd, 101) AS PEDEndDt FROM lu_payrolltype INNER JOIN ADP_PayrollMaster ON lu_payrolltype.CCC = ADP_PayrollMaster.CCC INNER JOIN lu_ftereporttype ON lu_payrolltype.ftereporttypeid = lu_ftereporttype.ftereporttypeid WHERE lu_payrolltype.ftereporttypeid = @FTEReportType AND ADP_PayrollMaster.PayrollEnd >= @PEDStDt GROUP BY ADP_PayrollMaster.PayrollEndwerseyjersey |
|
|
|
|
|