ThinkPHP data error 1064 I added a field to the database
Slice. when it is added to 30 columns, the system reports an error.
However, if you delete one column and 29 columns, the system will be able to display the data normally.
PS: No matter how many bits are in the column, you can get the data to the database, that is, when the number of bits is greater than or equal to 30, the data obtained cannot be displayed on the page, and an error is reported, please help me to see how it ends.
Reply to discussion (solution)
It should be your SQL error. paste the SQL statement you executed
Use getLastsql () to print the SQL statement.
It should be your SQL error. paste the SQL statement you executed
Errors may occur in three locations.
Case 'submit ': $ this-> assign ("folder_name", 'committed'); $ map ['User _ id'] = array ('EQ ', $ user_id); $ map ['step'] = array ('GT ', 10), array ('EQ', 0), or '); break; case 'save': $ this-> assign ("folder_name", 'approved '); $ FlowLog = M ("FlowLog "); $ where ['emp_no'] = $ emp_no; $ where ['is _ Del'] = 0; $ where ['_ string'] = "result is not null"; $ log_list = $ FlowLog-> where ($ where)-> field ('flow _ id ') -> select (); $ log _ List = rotate ($ log_list); if (! Empty ($ log_list) {$ map ['id'] = array ('in', $ log_list ['flow _ id']);} else {$ map ['_ string'] = '1 = 2';} break; case 'confirm': $ this-> assign ("folder_name ", 'to be reviewed'); $ FlowLog = M ("FlowLog"); $ where ['emp _ no'] = $ emp_no; $ where ['is _ del '] = 0; $ where [' _ string'] = "result is null"; $ log_list = $ FlowLog-> where ($ where) -> field ('flow _ id')-> select (); $ log_list = rotate ($ log_list); if (! Empty ($ log_list) {$ map ['id'] = array ('in', $ log_list ['flow _ id']);} else {$ map ['_ string'] = '1 = 2';} break;
The poster, you paste the code and paste the SQL execution statement.
$plugin['date'] = true;$this -> assign("plugin", $plugin);$emp_no = get_emp_no();$user_id = get_user_id();$flow_type_where['is_del'] = array('eq', 0);$flow_type_list = M("FlowType") -> where($flow_type_where) -> getField("id,name");$this -> assign("flow_type_list", $flow_type_list);$map = $this -> _search();if (method_exists($this, '_search_filter')) {$this -> _search_filter($map);}$folder = $fid;$this -> assign("folder", $folder);$this -> _flow_auth_filter($folder, $map);$model = D("FlowView");if (I('mode') == 'export') {$this -> _folder_export($model, $map);} else {$this -> _list($model, $map, 'id desc');}$this -> display();