Fuel\Core\Database_Exception [ 42S22 (1054) ]:
SQLSTATE[42S22]: Column not found: 1054 Unknown column 'Year("t0.created_at")' in 'where clause' with query: "SELECT COUNT(DISTINCT `t0`.`id`) AS count_result FROM `interview` AS `t0` LEFT JOIN `small_category` AS `t1_through` ON (`t0`.`small_category_id` = `t1_through`.`id`) LEFT JOIN `large_category` AS `t1` ON (`t1_through`.`large_category_id` = `t1`.`id`) WHERE `Year("t0`.`created_at")` = '2017' AND (`t0`.`display_flag` = '0' AND `t1`.`display_flag` = '0' AND `t1_through`.`display_flag` = '0') ORDER BY `t0`.`created_at` DESC, `t0`.`id` DESC"
218 else 219 { 220 $error_code = 0; 221 } 222 223 throw new \Database_Exception($e->getMessage().' with query: "'.$sql.'"', $e->getCode(), $e, $error_code); 224 } 225 } 226 227 // no more attempts left, bail out 228 else
308 catch (\CacheNotFoundException $e) {} 309 } 310 311 // Execute the query 312 \DB::$query_count++; 313 $result = $db->query($this->_type, $sql, $this->_as_object); 314 315 // Cache the result if needed 316 if (isset($cache) and ($this->_cache_all or $result->count())) 317 { 318 $cache->set_expiration($this->_lifetime)->set_contents($result->as_array())->set();
1671 // Set from view or table 1672 $query->from(array($this->_table(), $this->alias)); 1673 1674 $tmp = $this->build_query($query, $columns, 'count'); 1675 $query = $tmp['query']; 1676 $count = $query->execute($this->connection)->get('count_result'); 1677 1678 // Database_Result::get('count_result') returns a string | null 1679 if ($count === null) 1680 { 1681 return false;
330 ->and_where_close() 331 ->order_by("created_at","desc") 332 ->order_by("id","desc"); 333 334 $disp = 10; 335 $total = $orm->count(); 336 $pager = new Pager($total,'/aladdin/interview/year/'.$year, $disp); 337 $orm->rows_limit($disp)->rows_offset($pager->getOffset()); 338 $ret = $orm->get(); 339 340 $for_pankuzu = $year."年";
161 { 162 Session::set('side', 'period'); 163 164 $year = $this->param("year"); 165 166 $interview_array = Model_Interview::getYearData($year); 167 168 $this->_title = $interview_array[1] . " | シェアハウス経営ならオークハウス"; 169 170 // meta 171 $this->_pankuzu = array(
478 // fire any controller started events 479 \Event::instance()->has_events('controller_started') and \Event::instance()->trigger('controller_started', '', 'none'); 480 481 $class->hasMethod('before') and $class->getMethod('before')->invoke($this->controller_instance); 482 483 $response = $action->invokeArgs($this->controller_instance, $this->method_params); 484 485 $class->hasMethod('after') and $response = $class->getMethod('after')->invoke($this->controller_instance, $response); 486 487 // fire any controller finished events 488 \Event::instance()->has_events('controller_finished') and \Event::instance()->trigger('controller_finished', '', 'none');
76myRedirect::do_redirect(); 77 78// Generate the request, execute it and send the output. 79try 80{ 81 $response = Request::forge()->execute()->response(); 82} 83catch (HttpNotFoundException $e) 84{ 85 \Request::reset_request(true); 86