Hi all,
In my model, I use a dynamic expression in a global list called: "AantalReadyPlaten".
It count the number of rows with fulfill Attribute=Attribute2.
The (basic) expression is coded as follows:
string WerkStationString=value.WerkStationString;
----------------
Table result = Table.query("SELECT COUNT() FROM GlobalList WHERE Attribute=Attribute2");
if(result.numRows==0){
returnvalue = 0;
} else {
returnvalue = result[1][1];
}
//}
return returnvalue;
-----------------------
When having the dynamic button selected and pulling with the query "ORDER BY AantalReadyPlaten DESC", it gives no result. Even with the test pull queries, it gives no result. However the global list is filled with data. It gives the error: "exception: SqlQuery - Unknown error in:"
When having the dynamic button deselected the query retrieves data and pulling the row with the highest "returnvalue". So it works fine.
Anyone an idea why the dynamic expression is not working?
Thanks in advance!
Diederik