This doesn't look like a Visual FoxPro BUG. Visual FoxPro does pass values from MEMO fields a little bit different, but it doesn't do string substitution as Fabio claims.
Why write you this?
I have not never written that VFP changes the replaced value,
I have written that VFP uses two various ways to replace the parameter.
When VFP replaces a VFP memo parameter ,
it executes a
substitution of the parameter with the value of the parameter
within
the original SQL string, and it sendes it the commando exactly.
Explain with code:
SQLEXEC(H,"SELECT ?vfp.amemoexpression")
vfp send this:
SQLEXEC(H,STRTRAN("SELECT ?vfp.amemoexpression","?vfp.amemoexpression","'"+vfp.amemoexpression+"'"))
When the VFP parameter is of type "C",
VFP changes the command to "EXEC sp_sqlexecute.." with a parameter @P1 and send this SQL parameter string; the expression value is send with the ODBC parameter binding.
Fabio