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 |
|
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2002-03-11 : 00:42:46
|
vidya writes "The following sql statement works fine in access....Please help me with the SQL equivalentUpdate aset a.asig=(left(a.asig,0) + abs(a.fk_Institution ='as') + replicate('2',4)) from a WHERE ( ( a.fk_Institution Is Not Null ) )Now using the ABS ---abs(a.fk_Institution ='as') is giving problem in MS SQL Server where as works fine in accessAny cluesThanks" |
|
|
Nazim
A custom title
1408 Posts |
Posted - 2002-03-11 : 02:12:24
|
| the way you are using Abs , it will give error in Ms Access too.Abs is used to get a absolute value .if you can tell us what you want the update to do with some sample data and results. we should be able to help you.--------------------------------------------------------------Edited by - Nazim on 03/11/2002 02:18:41 |
 |
|
|
Arnold Fribble
Yak-finder General
1961 Posts |
Posted - 2002-03-11 : 04:21:30
|
| It's difficult to tell, but perhaps you want this sort of thing:(left(a.asig,0) + case when a.fk_Institution ='as' then '1' else '0' end + replicate('2',4)) |
 |
|
|
|
|
|