Re: Question about BLOB

2005-08-03 Thread Philippe Poelvoorde

Gelu Gogancea wrote:

Hi,
Is not the first time when i read this this page.
So, the conclusion is that until MySQL version 5.0.3 the empty spaces are 
remove if i wish to store the binary data in a table.
Is not any other solutions?Because for the moment i convert the binary data 
into ASCII(printing ASCII) string,i add slashes after each converted character 
and after all this i store in the BLOB field on the table.And i wish to avoid 
this procedure...wasting a lot of time.
Thanks,


the story for the trailing spaces only apply for varchar, so for blob it 
does not matter as long as you properly escape the data. (you don't need 
the ascii conversion, just the escaping)


--
Philippe Poelvoorde
COS Trading Ltd.

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



RE: Question about BLOB

2005-08-03 Thread Gelu Gogancea
I use mysql C API and for *escaping* the data i use the 
mysql_real_escape_string()the mysql native function.
Thanks,

_
G.NET SOFTWARE COMPANY
SYSTEM INTEGRATOR - AUTOMATION  SOFTWARE DEVELOPER
http://www.gonetsoftware.com

Permanent e-mail address :
[EMAIL PROTECTED]
[EMAIL PROTECTED]


-Original Message-
From: Philippe Poelvoorde [mailto:[EMAIL PROTECTED]
Sent: Wednesday, 03 August, 2005 9:58 AM
To: 'mysql@lists.mysql.com '
Subject: Re: Question about BLOB


Gelu Gogancea wrote:
 Hi,
 Is not the first time when i read this this page.
 So, the conclusion is that until MySQL version 5.0.3 the empty spaces are 
 remove if i wish to store the binary data in a table.
 Is not any other solutions?Because for the moment i convert the binary data 
 into ASCII(printing ASCII) string,i add slashes after each converted 
 character and after all this i store in the BLOB field on the table.And i 
 wish to avoid this procedure...wasting a lot of time.
 Thanks,

the story for the trailing spaces only apply for varchar, so for blob it 
does not matter as long as you properly escape the data. (you don't need 
the ascii conversion, just the escaping)

-- 
Philippe Poelvoorde
COS Trading Ltd.

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] 

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Question about BLOB

2005-08-03 Thread Philippe Poelvoorde

Gelu Gogancea wrote:

I use mysql C API and for *escaping* the data i use the 
mysql_real_escape_string()the mysql native function.
Thanks,


Make sure to use mysql_real_query with the right length.
because mysql_query is a macro for mysql_real_query with an additionnal 
parameters given by strlen(query_string); which culd lead to the broken 
result.


http://dev.mysql.com/doc/mysql/en/mysql-real-query.html

--
Philippe Poelvoorde
COS Trading Ltd.

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



RE: Question about BLOB

2005-08-02 Thread Gelu Gogancea
Hi,
Is not the first time when i read this this page.
So, the conclusion is that until MySQL version 5.0.3 the empty spaces are 
remove if i wish to store the binary data in a table.
Is not any other solutions?Because for the moment i convert the binary data 
into ASCII(printing ASCII) string,i add slashes after each converted character 
and after all this i store in the BLOB field on the table.And i wish to avoid 
this procedure...wasting a lot of time.
Thanks,

_
G.NET SOFTWARE COMPANY
SYSTEM INTEGRATOR - AUTOMATION  SOFTWARE DEVELOPER
http://www.gonetsoftware.com

Permanent e-mail address :
[EMAIL PROTECTED]
[EMAIL PROTECTED]


-Original Message-
From: Jay Blanchard [mailto:[EMAIL PROTECTED]
Sent: Monday, 01 August, 2005 8:41 PM
To: Gelu Gogancea; MySQL mailing list
Subject: RE: Question about BLOB


[snip]
I have a table with a MEDIUMBLOB field and i wish to store a
picture(.BMP) which the size is 10622 bytes.But when i look into the
table i see only 9582 bytes.
Please, i wish to know for what reason on the table are few bytes than
original.
I use MySQL 5.0 - Fedora Core 3 
[/snip]

Have a look here, 
http://dev.mysql.com/doc/mysql/en/blob.html 

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Question about BLOB

2005-08-02 Thread Octavian Rasnita
Hi,

I think that I have seen many times the advice not to store the images in
MySQL, but to store them on the hard disk while putting the path to them in
the database.
They could be accessed much faster this way.

Teddy


- Original Message - 
From: Gelu Gogancea [EMAIL PROTECTED]
To: Jay Blanchard [EMAIL PROTECTED]; MySQL mailing
list mysql@lists.mysql.com
Sent: Tuesday, August 02, 2005 13:50 PM
Subject: RE: Question about BLOB


Hi,
Is not the first time when i read this this page.
So, the conclusion is that until MySQL version 5.0.3 the empty spaces are
remove if i wish to store the binary data in a table.
Is not any other solutions?Because for the moment i convert the binary data
into ASCII(printing ASCII) string,i add slashes after each converted
character and after all this i store in the BLOB field on the table.And i
wish to avoid this procedure...wasting a lot of time.
Thanks,

_
G.NET SOFTWARE COMPANY
SYSTEM INTEGRATOR - AUTOMATION  SOFTWARE DEVELOPER
http://www.gonetsoftware.com

Permanent e-mail address :
[EMAIL PROTECTED]
[EMAIL PROTECTED]


-Original Message-
From: Jay Blanchard [mailto:[EMAIL PROTECTED]
Sent: Monday, 01 August, 2005 8:41 PM
To: Gelu Gogancea; MySQL mailing list
Subject: RE: Question about BLOB


[snip]
I have a table with a MEDIUMBLOB field and i wish to store a
picture(.BMP) which the size is 10622 bytes.But when i look into the
table i see only 9582 bytes.
Please, i wish to know for what reason on the table are few bytes than
original.
I use MySQL 5.0 - Fedora Core 3
[/snip]

Have a look here,
http://dev.mysql.com/doc/mysql/en/blob.html

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Question about BLOB

2005-08-02 Thread Andy Hilton
In my data structure I have many BLOBs which are not images - so I am hoping
that MySQL can indeed deal with BLOBs ok ?

Andy

On 8/2/05 12:14 PM, Octavian Rasnita [EMAIL PROTECTED] wrote:

 Hi,
 
 I think that I have seen many times the advice not to store the images in
 MySQL, but to store them on the hard disk while putting the path to them in
 the database.
 They could be accessed much faster this way.
 
 Teddy
 
 
 - Original Message -
 From: Gelu Gogancea [EMAIL PROTECTED]
 To: Jay Blanchard [EMAIL PROTECTED]; MySQL mailing
 list mysql@lists.mysql.com
 Sent: Tuesday, August 02, 2005 13:50 PM
 Subject: RE: Question about BLOB
 
 
 Hi,
 Is not the first time when i read this this page.
 So, the conclusion is that until MySQL version 5.0.3 the empty spaces are
 remove if i wish to store the binary data in a table.
 Is not any other solutions?Because for the moment i convert the binary data
 into ASCII(printing ASCII) string,i add slashes after each converted
 character and after all this i store in the BLOB field on the table.And i
 wish to avoid this procedure...wasting a lot of time.
 Thanks,
 
 _
 G.NET SOFTWARE COMPANY
 SYSTEM INTEGRATOR - AUTOMATION  SOFTWARE DEVELOPER
 http://www.gonetsoftware.com
 
 Permanent e-mail address :
 [EMAIL PROTECTED]
 [EMAIL PROTECTED]
 
 
 -Original Message-
 From: Jay Blanchard [mailto:[EMAIL PROTECTED]
 Sent: Monday, 01 August, 2005 8:41 PM
 To: Gelu Gogancea; MySQL mailing list
 Subject: RE: Question about BLOB
 
 
 [snip]
 I have a table with a MEDIUMBLOB field and i wish to store a
 picture(.BMP) which the size is 10622 bytes.But when i look into the
 table i see only 9582 bytes.
 Please, i wish to know for what reason on the table are few bytes than
 original.
 I use MySQL 5.0 - Fedora Core 3
 [/snip]
 
 Have a look here,
 http://dev.mysql.com/doc/mysql/en/blob.html


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Question about BLOB

2005-08-02 Thread Jason Pyeron
I have never had a problem storing BLOBs in MySQL or any other DB for that 
fact.


I have on many occasions forgot to use the proper methods for send a BLOB 
to the db. That means proper escaping, etc.




On Tue, 2 Aug 2005, Andy Hilton wrote:


In my data structure I have many BLOBs which are not images - so I am hoping
that MySQL can indeed deal with BLOBs ok ?

Andy


--
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
-   -
- Jason Pyeron  PD Inc. http://www.pdinc.us -
- Partner  Sr. Manager 7 West 24th Street #100 -
- +1 (443) 921-0381 Baltimore, Maryland 21218   -
-   -
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

This message is for the designated recipient only and may contain 
privileged, proprietary, or otherwise private information. If you 
have received it in error, purge the message from your system and 
notify the sender immediately.  Any other use of the email by you 
is prohibited.


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Question about BLOB

2005-08-02 Thread Jason Pyeron

But then replication would not work.
On Tue, 2 Aug 2005, Octavian Rasnita wrote:


Hi,

I think that I have seen many times the advice not to store the images in
MySQL, but to store them on the hard disk while putting the path to them in
the database.
They could be accessed much faster this way.

Teddy


- Original Message -
From: Gelu Gogancea [EMAIL PROTECTED]
To: Jay Blanchard [EMAIL PROTECTED]; MySQL mailing
list mysql@lists.mysql.com
Sent: Tuesday, August 02, 2005 13:50 PM
Subject: RE: Question about BLOB


Hi,
Is not the first time when i read this this page.
So, the conclusion is that until MySQL version 5.0.3 the empty spaces are
remove if i wish to store the binary data in a table.
Is not any other solutions?Because for the moment i convert the binary data
into ASCII(printing ASCII) string,i add slashes after each converted
character and after all this i store in the BLOB field on the table.And i
wish to avoid this procedure...wasting a lot of time.
Thanks,

_
G.NET SOFTWARE COMPANY
SYSTEM INTEGRATOR - AUTOMATION  SOFTWARE DEVELOPER
http://www.gonetsoftware.com

Permanent e-mail address :
[EMAIL PROTECTED]
[EMAIL PROTECTED]


-Original Message-
From: Jay Blanchard [mailto:[EMAIL PROTECTED]
Sent: Monday, 01 August, 2005 8:41 PM
To: Gelu Gogancea; MySQL mailing list
Subject: RE: Question about BLOB


[snip]
I have a table with a MEDIUMBLOB field and i wish to store a
picture(.BMP) which the size is 10622 bytes.But when i look into the
table i see only 9582 bytes.
Please, i wish to know for what reason on the table are few bytes than
original.
I use MySQL 5.0 - Fedora Core 3
[/snip]

Have a look here,
http://dev.mysql.com/doc/mysql/en/blob.html




--
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
-   -
- Jason Pyeron  PD Inc. http://www.pdinc.us -
- Partner  Sr. Manager 7 West 24th Street #100 -
- +1 (443) 921-0381 Baltimore, Maryland 21218   -
-   -
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

This message is for the designated recipient only and may contain 
privileged, proprietary, or otherwise private information. If you 
have received it in error, purge the message from your system and 
notify the sender immediately.  Any other use of the email by you 
is prohibited.


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Question about BLOB

2005-08-01 Thread Gelu Gogancea
Hi,
I have a table with a MEDIUMBLOB field and i wish to store a picture(.BMP) 
which the size is 10622 bytes.But when i look into the table i see only 9582 
bytes.
Please, i wish to know for what reason on the table are few bytes than original.
I use MySQL 5.0 - Fedora Core 3 
Thanks,

_
G.NET SOFTWARE COMPANY
SYSTEM INTEGRATOR - AUTOMATION  SOFTWARE DEVELOPER
http://www.gonetsoftware.com

Permanent e-mail address :
[EMAIL PROTECTED]
[EMAIL PROTECTED]


-Original Message-
From: Heikki Tuuri [mailto:[EMAIL PROTECTED]
Sent: Monday, 01 August, 2005 7:08 PM
To: Spill Support; MySQL mailing list
Cc: [EMAIL PROTECTED]
Subject: Re: mysql bug 9670 OPTIMIZE TABLE crashes


Matthis,

unfortunately, the bug fix was never made to 4.0. It is only in 4.1.12 and 
later.

Regards,

Heikki

- Alkuperäinen viesti - 
Lähettäjä: Matthijs van der Klip [EMAIL PROTECTED]
Vastaanottaja: MySQL mailing list mysql@lists.mysql.com
Kopio: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Lähetetty: Monday, August 01, 2005 5:08 PM
Aihe: mysql bug 9670 OPTIMIZE TABLE crashes


 Hi,

 I am experiencing assertion failures described in the following bugreport:

 http://bugs.mysql.com/bug.php?id=9670


 The bug has been closed, but I'm running the most current 4.0.25 version
 of MySQL. The report mentions downgrading to 4.0.23 or upgrading to 4.1.
 Is this really neccessary or should this bug already be fixed in 4.0.25?


 Best regards,

 -- 
 Matthijs van der Klip
 System Administrator
 Spill E-Projects
 The Netherlands

 


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] 

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



RE: Question about BLOB

2005-08-01 Thread Jay Blanchard
[snip]
I have a table with a MEDIUMBLOB field and i wish to store a
picture(.BMP) which the size is 10622 bytes.But when i look into the
table i see only 9582 bytes.
Please, i wish to know for what reason on the table are few bytes than
original.
I use MySQL 5.0 - Fedora Core 3 
[/snip]

Have a look here, 
http://dev.mysql.com/doc/mysql/en/blob.html

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Newbie question about blob data types ie. Storing .xls in blob

2004-09-27 Thread Jack Taffar

Is it possible to store an excel file into a blob field in mysql?  If so how
do I go about importing the file into the blob field, and get it back out
into an .xls file?


Thanks in advnace

Jack Taffar
AOG





-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Newbie question about blob data types ie. Storing .xls in blob

2004-09-27 Thread DreamWerx
Good binary storage article w/ sample code:

http://php.dreamwerx.net/forums/viewtopic.php?t=6


On Mon, 27 Sep 2004 16:47:37 -0500, Jack Taffar [EMAIL PROTECTED] wrote:
 
 Is it possible to store an excel file into a blob field in mysql?  If so how
 do I go about importing the file into the blob field, and get it back out
 into an .xls file?
 
 Thanks in advnace
 
 Jack Taffar
 AOG
 
 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
 


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]