Topic: LCReturnFullHierarchy - Error
Hi Mike
I'm getting the following error when using the above function:
Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression.
I've created a copy of the function and added 'DISTINCT' to the Set @sortkey SELECT statement and to the ORG.Sort_Level < (SELECT statement which makes the problem go away.
The species that seems to be causing more than one result to be returned is Roman Snail TLIK NHMSYS0020527488 - not sure why it should be returning more than one row - is this a dictionary issue?
Ian