[Gambas-user] Blob management

Benoît Minisini gambas at ...1...
Fri Jun 26 18:04:27 CEST 2009


> Hi, first of all thanks to Benoit, Ron and Wener for help me.
>
> Just to be clear if someone reads this in the future, these statementst are
> correct:
>
>   DIM hResultado AS Result
>
>   IF NOT Exist("/tmp/mas") THEN MKDIR "/tmp/mas"
>   hResultado = $hConn.Exec("SELECT * FROM `Imagenes`")
>   File.Save("/tmp/mas/1.jpg", hResultado["Imagen"].Data)
>
>
>
> The problem is that gambas espect a longblob and my field is mediumblob, if
> I change the datatype to longblob the statements above work fine.
>
> So, I think this was the problem, BUT, the problem is that the pictures I
> want to storage are not that big, so I will waste some space, Bonoit, can
> you (actualy you) change this interpretation of the Gambas database
> component? to use more optimal datatypes? Maybe for Gambas3?
>
> Regards
>
>
> --
> David
>
>

I don't think you will waste any space by using longblob (or longtext) instead 
of mediumblob (or mediumtext). Why do you think that?

-- 
Benoît




More information about the User mailing list