Hi folks. I’m using 2019r1 (no $$ to update Xojo)
I’m hoping this is just a quotes issue. I’ve got an INSERT statement to add an entry into my “props” table, which includes an image. Everything works fine, except that images on the database aren’t valid. IE: they have sizes in bytes, not kilobytes.
I’ve been trying to escape the needed quotes in the LOAD portion, but keep getting the same results.
The required MySQL format seems to be:
LOAD_FILE('/path/to/image/image.jpg')
But since that also needs to be enclosed in ’ ’ I’m baffled.
Here’s my INSERT statement: (all data comes from textfields)
"INSERT into props (cat, subcat, name, icon, price, stock, discont) VALUES ('"+addprop_cat_main.Text+"', '"+addprop_cat_sub.Text+"', '"+propname.Text+"', 'LOAD_FILE("+iconpath.Text+")', '"+price.Text+"', '"+stock.Text+"', '"+newdiscont.Text+"')"
What am I not seeing? (FYI, I used to be able to do this stuff standing on my face…I’m getting old)