I have a global table named My_table with column names Ressource_1, Ressource_2 and so on. The table values contain numbers between -1 and 10.
I want to find the minimum value of each column. I have tried something like this:
for (int j = 1; j <= My_table.numCols; j++) { string res = My_table.getColHeader(j); int min_value = Table.query("SELECT MIN($1) as Dummy FROM My_table WHERE $1 <> -1", getlabel($iter(1), res))[1][1] }
As you can see the column IS the parameter itself. In addition, I also need the WHERE statement to filter out values of -1.
I've had a look in the documentation
but I'm unable to pinpoint the syntax for my case. FlexSim simply reports that it can't parse the query.