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 |
|
KevinC
Starting Member
4 Posts |
Posted - 2008-08-28 : 14:59:56
|
| SELECT SUBSTR(FYSTART,1,4) FROM ADUADS01.ADVTBDAT ;------+---------+---------+---------+---------+---------+---------+---------T408I SQLCODE = -171, ERROR: THE DATA TYPE, LENGTH, OR VALUE OF ARGUMENT 1 OF SUBSTR IS INVALID |
|
|
GilaMonster
Master Smack Fu Yak Hacker
4507 Posts |
Posted - 2008-08-28 : 15:09:48
|
| That doesn't look like a SQL Server error message. What DB engine are you using?--Gail ShawSQL Server MVP |
 |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2008-08-28 : 15:21:02
|
SELECT DATEPART(YEAR, FyStart)FROM Aduads01.Advtbdat E 12°55'05.25"N 56°04'39.16" |
 |
|
|
KevinC
Starting Member
4 Posts |
Posted - 2008-08-28 : 15:48:23
|
| it's DB2. Thanks for such quick replies!The 'year' function worked. Thank you so much!! |
 |
|
|
|
|
|