]
Steven Hawkins resolved TEIID-4679.
-----------------------------------
Resolution: Done
Removed locate support and changed ifnull to coalesce
PrestoDB translator - locate function - source specific function has
different order of arguments
-------------------------------------------------------------------------------------------------
Key: TEIID-4679
URL:
https://issues.jboss.org/browse/TEIID-4679
Project: Teiid
Issue Type: Bug
Components: Misc. Connectors
Affects Versions: 8.12.8.6_3
Reporter: Juraj DurĂ¡ni
Assignee: Steven Hawkins
Fix For: 9.2, 9.1.3
For PrestoDB translator, *locate(x,y)* is translated as *strpos(x,y)* - i.e.
*strpos(substring, string)*, but function has different order of arguments - from
[PrestoDB documentation|https://prestodb.io/docs/current/functions/string.html] -
*strpos(string, substring)*
{code:sql|title=Query}
SELECT StringNum, LOCATE('1', StringNum) FROM BQT1.SmallA
{code}
{code:sql|title=Source-specific command}
SELECT g_0.stringnum, strpos('1', g_0.stringnum) FROM smalla AS g_0
{code}