Sidebar

What causes: NoResultsException: Unable to find columns in table or columns not unique. in at line number 29

0 votes
449 views
asked Jul 9, 2013 by rich-c-2789 (16,240 points)
What causes: NoResultsException: Unable to find columns in table or columns not unique. in at line number
commented Jul 11, 2013 by ron-s-6919 (4,480 points)
This error message has been replaced to more clearly identify the problem (see bug #518).  Error will now be reported as one of the following:

VariableNotFoundException: Unable to find column 'wrongTarget' in variable 'testTable4'.

VariableNotFoundException: Unable to find column 'wrongSource' in variable 'testTable4'.

NoResultsException: Column 'target' in variable 'testTable4' cannot be specified as both the target and source column.

1 Answer

+1 vote
 
Best answer

There are at least two things that cause this error.

The examples use a Table System Varible like this:

fruitTable
Id Name Code
1 Apple 123
2 Grape 456

 

Example1:

Invalid column name:

var result = qie.doTableLookup('2', '', 'fruitTable', 'Id', 'Type');

Example 2:

Target column cannot be the same as one of the source columns:

var result = qie.doTableLookup(['Apple', '123'], '', 'fruitTable', ['Name','Code'], 'Code');

Note: The second example also demonstrates a multi column lookup.

answered Jul 9, 2013 by rich-c-2789 (16,240 points)
selected Jul 11, 2013 by ron-s-6919
...