IB - Developer Center    Forums  Hop To Forum Categories  FOCUS/WebFOCUS    HOW TO USE IF-ELSE STATEMENT IN FOCUS
Go
New
Search
Notify
Tools
Reply
  
-star Rating Rate It!  Login/Join 
Member
Posted
Hi;

Here is my attempt:

DEFINE TABLE MYTABLE
..
..
IF 0 THEN
MYLINE1/A225='ORG1 ORG2 '|
'ORG3 ORG4';
ELSE
MYLINE1/A225='NEW1 NEW2 '|
'NEW3 NEW4';

END

but it throws me a syntax error. Any sugguestion?
Note: I put zero as condition coz I want to test if it goes to else part

waiting for help,

new focuser
 
Posts: 13 | Registered: March 17, 2004Reply With QuoteEdit or Delete MessageReport This Post
Platinum Member
Posted Hide Post
Try this:

DEFINE FILE MYTABLE
MYLINE/A225 = IF 1 EQ 0 THEN 'ORG1 ORG2 '| 'ORG3 ORG4'
ELSE 'NEW1 NEW2 '| 'NEW3 NEW4';
END
Doc.Ref.: Writing Conditional Expressions.

Regards,
Mikel

This message has been edited. Last edited by: <Mabel>,
 
Posts: 164 | Location: Madrid, Spain | Registered: May 09, 2003Reply With QuoteEdit or Delete MessageReport This Post
Member
Posted Hide Post
Thank you very much for your help.
It took me a few hours to figure that out ~> Frowner

I'll be visiting this site with more questions soon.

See you all again.

Big Grin
 
Posts: 13 | Registered: March 17, 2004Reply With QuoteEdit or Delete MessageReport This Post
 Previous Topic | Next Topic powered by eve community  
 

IB - Developer Center    Forums  Hop To Forum Categories  FOCUS/WebFOCUS    HOW TO USE IF-ELSE STATEMENT IN FOCUS

Copyright © 1996-2008 Information Builders, leaders in enterprise business intelligence.