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 |
|
jpockets
Starting Member
45 Posts |
Posted - 2007-07-02 : 12:19:48
|
I'm trying to get month/year from column X_POLICY_EFCTV_DT, i tried thisConcat(month(rr.X_POLICY_EFCTV_DT),year(rr.X_POLICY_EFCTV_DT)) But i'm getting an error concat is not a recognized function nameis there a better way to get month/year from that column? |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2007-07-02 : 12:22:39
|
| select stuff(convert(char(5), rr.X_POLICY_EFCTV_DT, 103), 3, 1, '')Peter LarssonHelsingborg, Sweden |
 |
|
|
DonAtWork
Master Smack Fu Yak Hacker
2167 Posts |
Posted - 2007-07-02 : 12:24:46
|
Don't think there is such a function as Concat in T-SQL. Maybe you want cast(month(rr.X_POLICY_EFCTV_DT) as varchar(2))+ cast(year(rr.X_POLICY_EFCTV_DT) as varchar(4)) yuk [Signature]For fast help, follow this link:http://weblogs.sqlteam.com/brettk/archive/2005/05/25.aspxLearn SQLhttp://www.sql-tutorial.net/ http://www.firstsql.com/tutor.htm http://www.w3schools.com/sql/default.asp |
 |
|
|
|
|
|