I have a lot of tables which has bit fields. For ex:
CREATE TABLE `users` (
`id` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
`email` VARCHAR(150) NULL DEFAULT NULL,
`password` VARCHAR(32) NULL DEFAULT NULL,
`name` VARCHAR(100) NULL DEFAULT NULL,
`surname` VARCHAR(100) NULL DEFAULT NULL,
`gsm` VARCHAR(20) NULL DEFAULT NULL,
`citizen_id` VARCHAR(20) NULL DEFAULT NULL,
`is_driver` BIT(1) NULL DEFAULT b'0',
`is_activated` BIT(1) NULL DEFAULT b'0',
`is_deleted` BIT(1) NULL DEFAULT b'0',
PRIMARY KEY (`id`)
)
COLLATE='utf8_general_ci'
ENGINE=InnoDB
At localhost is_activated comes as string(1) "1"
but at my hosting string(1) ""
. I already found it's need to read with ord. But i do not want to change all files for this. I throught there is a way to doing this but couldnt found yet.
My local:
PDO Driver for MySQL:
mysqlnd 5.0.12-dev - 20150407 - $Id:241ae00989d1995ffcbbf63d579943635faf9972 $
MySQL:
5.7.12
Hosting
Client API version:
5.5.50
MySQL:
5.5.0