Jump to content

[SOLVED] Append String to SQL value


Recommended Posts




I have this SELECT datediff(day,1999.03.09,1999.03.19) this returns 10. I would like to append the word day to this result.


I have tried this SELECT datediff(day,1999.03.09,1999.03.19)+' '+Days but it doesn't work.


Any ideas ?

Link to comment
Share on other sites

Try this:


SELECT    { fn CONCAT(CAST(DATEDIFF(day, '1999-03-09', '1999-03-19') AS varchar(100)), ' Days') }




or just:


SELECT CAST(DATEDIFF(day, '1999-03-09', '1999-03-19') AS varchar(100))+' Days'

Link to comment
Share on other sites

  • 2 weeks later...


This topic is now archived and is closed to further replies.

  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.