To create a view method to generate a computed column, you use some code like this:
private static server str createMySqlScript()
{
str cellName = SysComputedColumn::returnField(tableStr(MyViewName), identifierStr(MyDataSourceName), fieldStr(TableName, ColumnName));
return strFmt('LEFT(%1, 5)', cellName);
}
Works great for regular views, with regular data sources.
However, when you use a View with a query source, instead of traditional data sources, the entire thing falls apart.
On the first line: "Stack trace: The method has been called with an invalid number of parameters."
Anyone know how to call the name of a query field instead of a datasource field in a view?