Page 1 of 1
EscapeAndQuoteStr no longer public
Posted: Mon 18 Apr 2011 18:37
by davidmarcus
Version 4.40 had a public EscapeAndQuoteStr function, but it is not public in 5.55. Is there a reason for this? I was using it.
(I know I'm a bit behind with versions, but I'm trying to catch up.)
Posted: Tue 19 Apr 2011 09:02
by AndreyZ
Hello,
Please describe why you need this function.
EscapeAndQuoteStr no longer public
Posted: Tue 19 Apr 2011 12:45
by davidmarcus
I've been constructing my own SQL statements and assigning them to the TMyQuery.SQL and TMyScript.SQL properties. Then I do Execute. When I use PHP on my Web server to do similar things, I use the mysql_real_escape_string function. In Delphi, I was using EscapeAndQuoteStr. I know I could use parameters, but at the time, it seemed simpler to just construct the SQL myself.
After thinking about it, I suppose the EscapeAndQuoteStr function is no longer public because it doesn't check what character set the connection is using. Since I know the character set I'm using for the connection, I can just write my own EscapeAndQuoteStr function.
Posted: Tue 19 Apr 2011 13:01
by AndreyZ
Ok, this function will be public in the next MyDAC build.
EscapeAndQuoteStr no longer public
Posted: Tue 19 Apr 2011 14:41
by davidmarcus
Thank you.