Note: This was originally posted by an inactive account. Content was preserved by moving under an admin account.
Originally posted by: leekennettI have the following code in a filter to output a calculated field.
CMPDT = if (NUM_DAY > 0)
then (if (weekday('CRIS_Service_Order.INPUT_DATE') == 5)
then (addDate(addDate('CRIS_Service_Order.INPUT_DATE',1 ),NUM_DAY))
else if (weekday('CRIS_Service_Order.INPUT_DATE') == 4)
then (addDate(addDate('CRIS_Service_Order.INPUT_DATE',2 ),NUM_DAY))
else (addDate('CRIS_Service_Order.INPUT_DATE',NUM_DAY)) )
else (addDate('CRIS_Service_Order.INPUT_DATE',NUM_DAY))
When I try to run the filter it errors out saying :
ERROR initializing expert output:
unrecognized token: 'weekday'
Installing log (01/22/2010 17:35:11) ...
2010-01-22 17:35:11; Level: 2; Type: 0; Desc: "unrecognized token: 'weekday'"; File: "./../code/source/expert/Expr.cpp"; Line: 125; Context: "Salmon::NED::Expr::tryParseCombination()"
2010-01-22 17:35:11; Level: 2; Type: 0; Desc: "...in expression starting on line 243"; File: "./../code/source/expert/Expr.cpp"; Line: 89; Context: "Expr::parseExpr()"
2010-01-22 17:35:11; Level: 2; Type: 0; Desc: "...in expression starting on line 243"; File: "./../code/source/expert/Expr.cpp"; Line: 89; Context: "Expr::parseExpr()"
2010-01-22 17:35:11; Level: 2; Type: 0; Desc: "...in expression starting on line 243"; File: "./../code/source/expert/Expr.cpp"; Line: 89; Context: "Expr::parseExpr()"
2010-01-22 17:35:11; Level: 2; Type: 0; Desc: "...in expression starting on line 242"; File: "./../code/source/expert/Expr.cpp"; Line: 89; Context: "Expr::parseExpr()"
2010-01-22 17:35:11; Level: 2; Type: 0; Desc: "...in statement starting on line 242"; File: "./../code/source/expert/ExprStatement.cpp"; Line: 158; Context: "Salmon::NED::Statement_Expr::tryParseStatemen t()"
2010-01-22 17:35:11; Level: 2; Type: 0; Desc: "...in expression starting on line 242"; File: "./../code/source/expert/Expr.cpp"; Line: 89; Context: "Expr::parseExpr()"
2010-01-22 17:35:11; Level: 2; Type: 0; Desc: "...handling expression #12 in file"; File: "./../code/source/brain/ExprTableIo.cpp"; Line: 86; Context: "Salmon::NED::ExprTableIo::initialize()"
2010-01-22 17:35:11; Level: 2; Type: 0; Desc: "...exception seen"; File: "./../code/source/brain/NodeControl.cpp"; Line: 1057; Context: "Salmon::NED::NodeControl::initializeExpert()"
Uninstalling log (01/22/2010 17:35:11) ...
Any suggestions?