This question pops up often, but the solution is not specific to MyComponents, and will work in and with any Borland dataset component (in fact, this is how you are suppose to do it in Delphi/Kylix):
the following of course also works:
or you can also use the LoadFromStream and SaveToStream methods.
NOTE: If you post blobs to a table in MySQL you should keep a couple of things in mind:
1. The blob value is sent to the MySQL using a standard SQL statement. For this purpose, the value is hexed by the dataset and thus 2 SQL characters=1 blob byte.
2. Most MySQL servers' "max_allowed_packet" variable is set to a default value of [Read more...]