Need more, need help now?
- - - - - - - - - - - - - - - - - - pay-as-you-go support - no contract - tenth of an hour billing - expert help - fast service - no call queues
Need integration?
- - - - - - - - - - - - - - - - - - with your shipping system - website - invoicing system - crm - cms - manufacturing - order import - back to back orders..
Need a report?
- - - - - - - - - - - - - - - - - - Excel reporting that pulls data from Sage - custom layouts - layouts that change adapt to your brands and/or for drop shipping.
Want web hosting?
- - - - - - - - - - - - - - - - - - Your own domain name - email - a shop - wordpress - woo commerce - ticket systems - help desks - forums - portals

SWITCH and CASE

Report design issues and solutions.
Post Reply
wadesnj
User
User
Posts: 4
Joined: 09 Jan 2014, 13:02
Sage Version: v2014 20 UK/Europe/Africa

SWITCH and CASE

Post by wadesnj » 09 Jan 2014, 13:08

Is there anyway to use the SWITCH statement in the expression editor?
I can do this:

PURCHASE_ORDER.TAKEN_BY = "seanm" ? "Sean Maxfield" :
PURCHASE_ORDER.TAKEN_BY = "MANAGER" ? "Manager" :
PURCHASE_ORDER.TAKEN_BY = "bobh" ? "Bob Huxtable" :""

But what I want to do is this:

Switch PURCHASE_ORDER.TAKEN_BY
Case "Seanm"
? "Sean Maxfield"
Case "MANAGER"
? "Manager"
etc.
End

But this does not work, the systax is incorrect, although there is an example of this in the report designer online help!!

User avatar
brucedenney
Site Admin
Site Admin
Posts: 4619
Joined: 28 Feb 2006, 09:56
Sage Version: v28 UK/Europe/Africa

Re: SWITCH and CASE

Post by brucedenney » 09 Jan 2014, 13:29

I think in a Switch you would be using : not ?

Not sure what/how you set the values, these are normally used for formatting styles rather than setting values in conditional formatting expressions.

I might take a look later.
For just about anything Sage :- Discount subscriptions, pay-as-you-go support, application integration, reports, layouts, linked excel spreadsheets, analysis or any other help making life with sage easier/less time consuming Contact me.

wadesnj
User
User
Posts: 4
Joined: 09 Jan 2014, 13:02
Sage Version: v2014 20 UK/Europe/Africa

Re: SWITCH and CASE

Post by wadesnj » 09 Jan 2014, 14:28

Thanks Bruce, much appreciated if you get time to take a look at it, would be very useful where there are a lot of users, I have 12 in the expression above!

User avatar
brucedenney
Site Admin
Site Admin
Posts: 4619
Joined: 28 Feb 2006, 09:56
Sage Version: v28 UK/Europe/Africa

Re: SWITCH and CASE

Post by brucedenney » 14 Jan 2014, 11:02

Checked it out and I can not use them the way you are trying.
For just about anything Sage :- Discount subscriptions, pay-as-you-go support, application integration, reports, layouts, linked excel spreadsheets, analysis or any other help making life with sage easier/less time consuming Contact me.

Post Reply

Who is online

Users browsing this forum: No registered users and 15 guests