PB 2017R2, using Query Mode for retrieval. I need to change a where clause to use "like" instead of "=".
Code from retrieval event:
ls_sql = this.GetSQLSelect()
if pos(ls_sql, "S%") > 0 then
ls_sql = Replace(ls_sql, pos(ls_sql, "mtk_nb_document ="), 17, "mtk_nb_document like")
li_sql = this.SetSQLSelect(ls_sql)
end if
The Replace command generates the correct SQL, but SetSQLSelect generates this SQL:
and (((mtk_nb_document like '099479S%'))) and (((mtk_nb_document = '099479S%')))
Should I be changing the SQL in another event?
Any help is appreciated.
Pete
If you plan on using powerserver2021, then you can still do what you want, but it is a lot more involved.