I want to store igbinary binary serialize data into MySQL. To improve performance is better to use TEXT or BLOB, or etc.
            Asked
            
        
        
            Active
            
        
            Viewed 850 times
        
    4
            
            
        - 
                    3use blob. text field types are subject to character set translation rules, which can/will mangle blob data. other than the charset stuff, blob and text will otherwise perform identically. – Marc B May 23 '13 at 16:01
2 Answers
3
            When I need to store binary data I always use VARBINARY format.
You can find documentation here
If you are asking what are advantagese, please look here
 
    
    
        girardengo
        
- 726
- 12
- 16
 
    
    
        zeppaman
        
- 844
- 8
- 23
2
            
            
        You should use BLOB, as BLOB stands for Binary Large OBject, if you start storing binary data as text you could start to see all sorts of unexpected results.
There is some documentation explaining the datatypes: http://dev.mysql.com/doc/refman/5.0/en/blob.html
If you really want to store as text, Base64 encoding is what you need to look into, some more details here:
 
    
    
        ThomasRedstone
        
- 379
- 1
- 4
- 13
 
    