Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

can I do an in-line select case statement? syntax ?

Status
Not open for further replies.

Rousseau10

Programmer
Feb 22, 2005
242
US
can I do an inline select case statement? syntax ?

I am using a table for look up that vba code is referencing.

switch([eeloca] = "AMRL", "1", [eeloca] = "ECON", "2")

1st question in this switch statement, do I need to put the [eeloca] each time. this is simplified, the problem is it is more than the field length of 255.

So therefore second question is what is syntax for inline select case statement.

TANX in Advance!!


I was the first American Soldier to put a basketball hoop up in Iraq, only to have it stolen by a soldier from different camp. Newbee - Adam
 
the problem is it is more than the field length of 255
???

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
yes

I was the first American Soldier to put a basketball hoop up in Iraq, only to have it stolen by a soldier from different camp. Newbee - Adam
 
If I understand your problem, your switch statement is over 255 characters long. Have you thought of using a domain table?

Code Value
AMRL 1
ECON 2
etc

Richard
 
Use Memo fields.

VBSlammer
redinvader3walking.gif

"You just have to know which screws to turn." - Professor Bob
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top