Mysql left(string,x) not working for me

wappler 6.6.2, php, docker

I have a custom query that uses a left(string,char) to get certain length of data.

this works just fine in workbench, i get the expected results, see screenshot below

but in wappler i get no results for the notes column

any idea why?

also, if i change it so its not using left, but just gets me the full column data, in the query i then shows no column returned in the results set, but, in my web client i get the data.... but thats another bug.

thanks

You should post a screenshot of your Parameters tab

In addition to @Apple's suggestion,
have you tested your api on a browser, with real data?
You can't fully test your query from within the wappler query builder...

here is the param tab

the sql works as i have tested it in sql workbench as per the screenshot above, so the sql works, which is the exact same query (except i took out the :p1 and replaced with the value required, and i get the correct data set, but not in wappler. in the browser when i look at the recordset it doesnt containt the notes part at all, its like wappler is ignoring the left().

has anyone any insight into why in wappler the left(xxx, 10) type thing doesnt work, yet the sql works in sql workbench so is correct.

thanks

just figured it out actually, the left(sdsds, 10) wants to be an AS something

i.e left(note.notes,10) as Note

then it works