OK, I'll bet you guys get a lot of this one, but I can't seem to find
the answer in the archives.
I have binary data that I want to store in a longblob. This is just
byte data.... null bytes are possible. So, I use mysql_real_query.
How do I format the char* query string?
Here's the way my format looks:
sprintf(queryString,"update images set imageData=%p where imageID=\'%s
\'",imageData,[imageID cString]);
and then I do the query:
result = mysql_real_query(theConnection,queryString,strlen(theDBData)
+nBytes);
where strlen(theDBData)+nBytes gives the total byte count for
queryString. Well, I get an error message saying that I have an
error in my syntax. How do I format this properly?
Thanks,
Eric