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 - 2006-08-29 : 09:35:53
|
Raj writes "how do I rewrite left(annotation_2,12) to say if isNull then use related_correction_number, otherwise use left(annotation_2,12) if (source_security_type_cd ="Option" and base_currency_cd <> "USD", annotation_3, ( if ( source_security_type_cd = "Option" and pos ( alt_transaction_ref_number , "+") > 0, mid ( alt_transaction_ref_number , 1, ( pos ( alt_transaction_ref_number , "+", 1) -1)) + right( alt_transaction_ref_number , (len( alt_transaction_ref_number ) - (pos ( alt_transaction_ref_number , "+",1) )) ), (if(((upper(base_currency_cd)<> "USD") or left(upper( source_security_type_cd),4)="BOND"), left(annotation_2,12) , related_correction_number )))))Thanks,Raj Singh" |
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2006-08-29 : 09:59:04
|
Case when col is NULL then related_number else left(annotation_2,12) ENDAre you using SQL Server?MadhivananFailing to plan is Planning to fail |
|
|
Srinika
Master Smack Fu Yak Hacker
1378 Posts |
Posted - 2006-08-29 : 11:00:28
|
quote: Originally posted by madhivananAre you using SQL Server?
Looks like AccessSrinika |
|
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2006-08-29 : 12:02:07
|
Access supports IIFMadhivananFailing to plan is Planning to fail |
|
|
|
|
|
|
|