gocom / danpu

Optimized MySQL dump library written in PHP
MIT License
62 stars 15 forks source link

Add support for better excaping of different MySQL data types. #21

Closed vojtabiberle closed 5 years ago

vojtabiberle commented 9 years ago

I made this change because Export made all integer data for ENUM unescapated. And this means position of value in ENUM definition and not a data.

Example: columnname enum('0', '1', '2') ...

insert into tablename (columnname) value (0) ... means error, becouse 0 here is integer and MySQL means, it is position 0 in ENUM, but positions in ENUM are indexed from 1. Right: insert into tablename (columnname) value ('0') ...