tlist query with replace

Hi, I am trying to run the following tlist sql sentence in a report

~[tlist_sql;
select REPLACE(s.guardianemail,';',',') mymail
from cc
join students s on cc.studentid = s.id
where cc.sectionid = ~[gpv:sectionid]
order by s.lastfirst
]~(mymail);[/tlist_sql]

The idea is to query the guardinaemail field in the Students table, replace the semi colon character by a comma and get the resulst. However, it does not produce any result. If I remove the replace function from the SELECT it works fine but I need to replace the semi colon character before displaying the information. The query is valid in Oracle

What am I doing wrong? Any help would be much appreciated.

Xavier Villafuerte

I know this is a bit old, but the issue is likely to be fixed if you replace the semi-colon reference, ';', with it's ASCII equivalent using the chr() function: chr(59)
tlist_sql has a problem with certain special characters, including colons, semi-colons, hyphens, and double quotes.

Subscribe to Comments for "tlist query with replace"