Skip to Content
0
Former Member
Nov 20, 2008 at 09:51 PM

Check last letter in a string

15 Views

Good Day All,

I have a string field that does not a Consistence length.

I want to check the last of this field and concatenate some text depending on the result.

I've tried this but does not work.

if mid({usp_wb_Reporting_AssetsUnderManagement_A2a_Main;1.account_long_name,1 Len{usp_wb_Reporting_AssetsUnderManagement_A2a_Main;1.account_long_name}-1) = "M"

then {usp_wb_Reporting_AssetsUnderManagement_A2a_Main;1.account_long_name} & " Managed"

else {usp_wb_Reporting_AssetsUnderManagement_A2a_Main;1.account_long_name} & " Unmanaged

Basically I'm check the length and if return an M it's Managed everything else is Unmanaged.

Thanks

DM