Unknown column 'user_master.roles' in 'where clause'
SELECT * FROM `user_master` WHERE `EMAIL` = 'admin@admin.com' AND `PASSWORD` = 'f925916e2754e5e03f75dd58a5733251' AND `user_master`.`roles` IN('fields:ROLE_NAME,LOGIC_NAME', 'where:`role_master`.`LOGIC_NAME`=\'ADMINISTRATION\'')
Filename: C:/xampp/htdocs/demo/system/database/DB_driver.php
Line Number: 691
How solve this error
i want check EMAIL and PASSWORD in 'user_master' table and LOGIC_NAME check in 'role_master' how check in one go.
DB Structure
user_master
CREATE TABLE `user_master` (
`USER_ID` INT(11) NOT NULL AUTO_INCREMENT,
`EMAIL` VARCHAR(100) NOT NULL,
`PASSWORD` VARCHAR(50) NOT NULL,
`ROLE_ID` INT(11) NOT NULL,
`FORGOT_PASSWORD_CODE` VARCHAR(50) NULL DEFAULT NULL,
`INACTIVE` TINYINT(1) NOT NULL DEFAULT '0',
`LOGIN_ACTIVITY` DATETIME NULL DEFAULT NULL,
`CREATED_DATE` DATETIME NULL DEFAULT CURRENT_TIMESTAMP,
`UPDATED_DATE` DATETIME NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
PRIMARY KEY (`USER_ID`),
INDEX `FK_user_master_role_master` (`ROLE_ID`),
CONSTRAINT `FK_user_master_role_master` FOREIGN KEY (`ROLE_ID`) REFERENCES `role_master` (`ROLE_ID`) ON UPDATE CASCADE ON DELETE CASCADE
)
COLLATE='utf8_general_ci'
ENGINE=InnoDB
AUTO_INCREMENT=2131
;
role_master
CREATE TABLE `role_master` (
`ROLE_ID` INT(11) NOT NULL AUTO_INCREMENT,
`ROLE_NAME` VARCHAR(50) NOT NULL,
`LOGIC_NAME` VARCHAR(50) NOT NULL,
`INACTIVE` TINYINT(1) NOT NULL DEFAULT '0',
`CREATED_DATE` DATETIME NULL DEFAULT CURRENT_TIMESTAMP,
`UPDATED_DATE` DATETIME NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
PRIMARY KEY (`ROLE_ID`)
)
COLLATE='utf8_general_ci'
ENGINE=InnoDB
AUTO_INCREMENT=4
;
Hello,
i have two table 'user_master' and 'role_master'
User_model.php
Role_model.php
Controller : Admin.php
Error
i want check EMAIL and PASSWORD in 'user_master' table and LOGIC_NAME check in 'role_master' how check in one go.
DB Structure
user_master
role_master