PDOException (42000)
SQLSTATE[42000]: Syntax error or access violation: 1055 Expression #2 of ORDER BY clause is not in GROUP BY clause and contains nonaggregated column 'apollonia_2024.treatments_names.tr_name' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by PDOException thrown with message "SQLSTATE[42000]: Syntax error or access violation: 1055 Expression #2 of ORDER BY clause is not in GROUP BY clause and contains nonaggregated column 'apollonia_2024.treatments_names.tr_name' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by" Stacktrace: #11 PDOException in /home/www/apollonia.hu/apollonia_app/vendor/envms/fluentpdo/src/Queries/Base.php:506 #10 PDOStatement:execute in /home/www/apollonia.hu/apollonia_app/vendor/envms/fluentpdo/src/Queries/Base.php:506 #9 Envms\FluentPDO\Queries\Base:executeQuery in /home/www/apollonia.hu/apollonia_app/vendor/envms/fluentpdo/src/Queries/Base.php:201 #8 Envms\FluentPDO\Queries\Base:execute in /home/www/apollonia.hu/apollonia_app/vendor/envms/fluentpdo/src/Queries/Select.php:184 #7 Envms\FluentPDO\Queries\Select:fetchAll in /home/www/apollonia.hu/apollonia_app/core/database/QueryBuilder.php:57 #6 core\database\QueryBuilder:fetchAll in /home/www/apollonia.hu/apollonia_app/core/database/Scheme.php:505 #5 core\database\Scheme:where in /home/www/apollonia.hu/apollonia_app/app/models/Treatments.php:18 #4 app\models\Treatments:getPublic in /home/www/apollonia.hu/apollonia_app/app/controllers/baseController.php:40 #3 app\controllers\baseController:beforeRouteLoad in /home/www/apollonia.hu/apollonia_app/core/http/Route.php:101 #2 core\http\Route:beforeLoad in /home/www/apollonia.hu/apollonia_app/core/http/Route.php:159 #1 core\http\Route:doRoute in /home/www/apollonia.hu/apollonia_app/core/http/Route.php:122 #0 core\http\Route:dispatch in /home/www/apollonia.hu/public_html/index.php:17
Stack frames (12)
11
PDOException
/vendor/envms/fluentpdo/src/Queries/Base.php506
10
PDOStatement execute
/vendor/envms/fluentpdo/src/Queries/Base.php506
9
Envms\FluentPDO\Queries\Base executeQuery
/vendor/envms/fluentpdo/src/Queries/Base.php201
8
Envms\FluentPDO\Queries\Base execute
/vendor/envms/fluentpdo/src/Queries/Select.php184
7
Envms\FluentPDO\Queries\Select fetchAll
/core/database/QueryBuilder.php57
6
core\database\QueryBuilder fetchAll
/core/database/Scheme.php505
5
core\database\Scheme where
/app/models/Treatments.php18
4
app\models\Treatments getPublic
/app/controllers/baseController.php40
3
app\controllers\baseController beforeRouteLoad
/core/http/Route.php101
2
core\http\Route beforeLoad
/core/http/Route.php159
1
core\http\Route doRoute
/core/http/Route.php122
0
core\http\Route dispatch
/home/www/apollonia.hu/public_html/index.php17
/home/www/apollonia.hu/apollonia_app/vendor/envms/fluentpdo/src/Queries/Base.php
        if ($this->result === false) {
            $error = $this->fluent->getPdo()->errorInfo();
            $this->message = "SQLSTATE: {$error[0]} - Driver Code: {$error[1]} - Message: {$error[2]}";
 
            if ($this->fluent->exceptionOnError === true) {
                throw new Exception($this->message);
            }
        }
    }
 
    /**
     * @param array $parameters
     * @param int   $startTime
     * @param int   $execTime
     *
     * @throws Exception
     */
    private function executeQuery($parameters, $startTime, $execTime): void
    {
        if ($this->result->execute($parameters) === true) {
            $this->executionTime = microtime(true) - $execTime;
            $this->totalTime = microtime(true) - $startTime;
        } else {
            $error = $this->result->errorInfo();
            $this->message = "SQLSTATE: {$error[0]} - Driver Code: {$error[1]} - Message: {$error[2]}";
 
            if ($this->fluent->exceptionOnError === true) {
                throw new Exception($this->message);
            }
 
            $this->result = false;
        }
    }
 
    /**
     * @param PDOStatement $result
     */
    private function setObjectFetchMode(PDOStatement $result): void
    {
        if ($this->object !== false) {
Arguments
  1. "SQLSTATE[42000]: Syntax error or access violation: 1055 Expression #2 of ORDER BY clause is not in GROUP BY clause and contains nonaggregated column 'apollonia_2024.treatments_names.tr_name' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by"
    
/home/www/apollonia.hu/apollonia_app/vendor/envms/fluentpdo/src/Queries/Base.php
        if ($this->result === false) {
            $error = $this->fluent->getPdo()->errorInfo();
            $this->message = "SQLSTATE: {$error[0]} - Driver Code: {$error[1]} - Message: {$error[2]}";
 
            if ($this->fluent->exceptionOnError === true) {
                throw new Exception($this->message);
            }
        }
    }
 
    /**
     * @param array $parameters
     * @param int   $startTime
     * @param int   $execTime
     *
     * @throws Exception
     */
    private function executeQuery($parameters, $startTime, $execTime): void
    {
        if ($this->result->execute($parameters) === true) {
            $this->executionTime = microtime(true) - $execTime;
            $this->totalTime = microtime(true) - $startTime;
        } else {
            $error = $this->result->errorInfo();
            $this->message = "SQLSTATE: {$error[0]} - Driver Code: {$error[1]} - Message: {$error[2]}";
 
            if ($this->fluent->exceptionOnError === true) {
                throw new Exception($this->message);
            }
 
            $this->result = false;
        }
    }
 
    /**
     * @param PDOStatement $result
     */
    private function setObjectFetchMode(PDOStatement $result): void
    {
        if ($this->object !== false) {
/home/www/apollonia.hu/apollonia_app/vendor/envms/fluentpdo/src/Queries/Base.php
     *
     * @return PDOStatement
     *
     * @throws Exception
     */
    public function execute()
    {
        $startTime = microtime(true);
 
        $query = $this->buildQuery();
        $parameters = $this->buildParameters();
 
        $this->prepareQuery($query);
 
        if ($this->result !== false) {
            $this->setObjectFetchMode($this->result);
 
            $execTime = microtime(true);
 
            $this->executeQuery($parameters, $startTime, $execTime);
            $this->debug();
        }
 
        return $this->result;
    }
 
    /**
     * @return Structure
     */
    protected function getStructure(): Structure
    {
        return $this->fluent->getStructure();
    }
 
    /**
     * Get PDOStatement result
     *
     * @return ?PDOStatement
     */
    public function getResult(): ?PDOStatement
/home/www/apollonia.hu/apollonia_app/vendor/envms/fluentpdo/src/Queries/Select.php
     * @throws Exception
     *
     * @return array|bool -  fetched rows
     */
    public function fetchAll($index = '', $selectOnly = '')
    {
        $indexAsArray = strpos($index, '[]');
 
        if ($indexAsArray !== false) {
            $index = str_replace('[]', '', $index);
        }
 
        if ($selectOnly) {
            $this->select($index . ', ' . $selectOnly, true);
        }
 
        if ($index) {
            return $this->buildSelectData($index, $indexAsArray);
        } else {
            if (($result = $this->execute()) !== false) {
                if ($this->fluent->convertRead === true) {
                    return Utilities::stringToNumeric($result, $result->fetchAll());
                } else {
                    return $result->fetchAll();
                }
            }
 
            return false;
        }
    }
 
    /**
     * \Countable interface doesn't break current select query
     *
     * @throws Exception
     *
     * @return int
     */
    public function count()
    {
/home/www/apollonia.hu/apollonia_app/core/database/QueryBuilder.php
 
    public function select($fields=null) {
        $this->instance = $this->instance->select($fields);
        return $this;
    }
    public function limit($limit=null,$offset=null) {
        if ($offset) {
            $this->instance = $this->instance->limit($limit)->offset($offset);
        } else {
            $this->instance = $this->instance->limit($limit);
        }
        
        return $this;
    }
    public function offset($offset=null) {
        $this->instance = $this->instance->offset($offset);
        return $this;
    }
    public function fetchAll() {
        return $this->instance->fetchAll();
        
    }
 
    public function getQuery() {
        return $this->instance->getQuery();
    }
}
 
/home/www/apollonia.hu/apollonia_app/core/database/Scheme.php
            $query = $query->leftJoin("{$this->translatable} ON {$this->translatable}.{$this->table}_id = $this->table.{$this->primary_key}");
            $query = $query->groupBy("{$this->primary_key}");
        }
   foreach ($arr as $key => $value) {
            $query = $query->where($key, $value);
        }
        foreach ($orderby as $value) {
            $query = $query->orderBy([$value]);
        }
 
 
        if ($limit) {
            if (is_array($limit)) {
                $query = $query->limit($limit[0], $limit[1]);
            } else {
                $query = $query->limit($limit);
            }
        }
 
        $lines = $query->fetchAll();
 
        if (app('Config')->get('debug')) {
 
            error_log("# SQL QUERY START: " . $query->getQuery());
        }
 
        $currs = [];
        if ($this->prices) {
            $currs = Currency::getAll();
        }
 
        $lines = array_map(
            function ($line) use ($currs, $select) {
 
                if (logged_in()) {
                    $line["admin"] = [
                        "id_field" => $this->getIDField(),
                        "scheme" => $this->name
                    ];
                }
/home/www/apollonia.hu/apollonia_app/app/models/Treatments.php
<?php
 
 
namespace app\models;
 
use core\database\Mysql;
use app\schemes\TreatmentsScheme;
use PDO;
 
class Treatments  extends TreatmentsScheme
{
 
 
    public static function getPublic()
    {
        
        $trs = new Treatments();
        $data = $trs->where(["tr_parent_id" => 0,"deleted"=>"no"],["list_order, tr_name"]);
        foreach ($data as $key=>$value) {
            $value["has_many"]["Treatments"] = self::findByParentID($value["tr_id"]);
            $data[$key] = $value;
        }
        return $data;
    }
    public static function findByParentID($parent_id) {
        $trs = new Treatments();
        return $trs->where(["tr_parent_id" => $parent_id,"deleted"=>"no"],["list_order, tr_name"]);
    }
    public static function findID($id) {
        $trs = new Treatments();
        return $trs->where(["tr_id" =>$id,"deleted"=>"no"])[0];
    }
    public static function getKezeles($url)
    {
        $trs = new Treatments();
        $lang = app("Language");
        $item = $trs->where(["website_url" => $url, "tr_parent_id" => 0, "lang_id" => $lang->current(),"deleted"=>"no"]);
        
        return isset($item[0]) ? $item[0] : null;
    }
/home/www/apollonia.hu/apollonia_app/app/controllers/baseController.php
    {
 
        $lang = app("Language");
 
        $isprod = app('Config')->get("environment") === 'production';
        View::setVar([
            "seo" => [
                "website_canonical" => "",
                "website_title" => "",
                "website_desc" => "",
                "website_keyword" => "",
                "website_image" => "",
                "website_url" => "",
            ]
        ]);
 
        $session = app("Session");
 
        View::setVar([
            "kezelesek_menu" => Treatments::getPublic(),
            "szolgaltatasok_menu" => Services::getPublic(),
            "whyus" => WhyUs::getPublic()
        ]);
 
        if (app('Domain')->defaultLang() != $lang->currentName()) {
            redirect("/");
            exit;
        }
        View::setVar(
 
            array(
                "domain" => app('Domain')->getUrl(),
                "version" => 23,
                "page_id" => '',
                "session" => $session,
                "lang" => $lang->current(),
                "lang_name" => $lang->currentName(),
                "logged_user" => app('Auth')->getUserData(),
                "is_logged" => app('Auth')->logged() == "LOGGED_IN" ? 1 : 0,
                "env" => app('Config')->get("environment"),
/home/www/apollonia.hu/apollonia_app/core/http/Route.php
    private function saveRoute($method, $route, $opts, $func = null) {
 
        array_push($this->routes, ['method' => $method, 'route' => $route, 'opts' => $opts, 'func' => $func, 'group_opts' => $this->currentgroup_middleware]);
 
        // app("Error")->print("Duplikált elérés", "$path | $method többször van felvéve", array("ellenőrízd az /app/routes.php fájlban"));
        // exit();
 
    }
    private function beforeLoad() {
        $beforeload = array("app\controllers\baseController", "beforeRouteLoad");
 
        if (!class_exists($beforeload[0])) {
            app("Error")->print("$class nem találhato", null, array("ellenőrízd, hogy a $folder.$class megtalálható", "helyesen van megadva a class név", "helyesen van megadva a namespace"));
            exit;
        }
 
        if (method_exists($beforeload[0], $beforeload[1])) {
 
            $inintedclass = dic("app\controllers\baseController");
            $inintedclass->beforeRouteLoad($this->params);
 
        }
    }
    private function afterLoad() {
        $beforeload = array("app\controllers\baseController", "afterRouteLoad");
 
        if (!class_exists($beforeload[0])) {
            app("Error")->print("$class nem találhato", null, array("ellenőrízd, hogy a $folder.$class megtalálható", "helyesen van megadva a class név", "helyesen van megadva a namespace"));
            exit;
        }
 
        if (method_exists($beforeload[0], $beforeload[1])) {
 
            $inintedclass = dic("app\controllers\baseController");
            $inintedclass->afterRouteLoad($this->params);
 
        }
    }
    public function dispatch() {
        foreach ($this->routes as $route) {
/home/www/apollonia.hu/apollonia_app/core/http/Route.php
 
                $this->urlfound = true;
 
                $middlewares = array();
 
                if (is_array($opts)) {
                    $middlewares = array_merge($opts, $middlewares);
                } else {
                    $func = $opts;
                }
 
                if (is_array($group_opts)) {
                    $middlewares = array_merge($group_opts, $middlewares);
                }
 
                if (count($middlewares) > 0) {
                    $this->middlewares($middlewares);
                }
 
                $this->beforeLoad();
 
                if (is_callable($func)) {
                    View::setJsVar(["current_route" => join("/", $route)]);
 
                    call_user_func_array($func, $this->params);
                } else {
                    $class = explode('@', $func)[0];
                    $function = explode('@', $func)[1];
 
                    $folder = "app\controllers\\";
                    $action = array($folder . $class, $function);
                    $beforeaction = array($folder . $class, "beforeLoad");
 
                    if (!class_exists($beforeaction[0])) {
                        app("Error")->print("$class nem találhato", null, array("ellenőrízd, hogy a $folder.$class megtalálható", "helyesen van megadva a class név", "helyesen van megadva a namespace"));
                        exit;
                    }
 
                    if (method_exists(($folder . $class), "beforeLoad")) {
                        call_user_func_array($beforeaction, $this->params);
/home/www/apollonia.hu/apollonia_app/core/http/Route.php
        }
    }
    private function afterLoad() {
        $beforeload = array("app\controllers\baseController", "afterRouteLoad");
 
        if (!class_exists($beforeload[0])) {
            app("Error")->print("$class nem találhato", null, array("ellenőrízd, hogy a $folder.$class megtalálható", "helyesen van megadva a class név", "helyesen van megadva a namespace"));
            exit;
        }
 
        if (method_exists($beforeload[0], $beforeload[1])) {
 
            $inintedclass = dic("app\controllers\baseController");
            $inintedclass->afterRouteLoad($this->params);
 
        }
    }
    public function dispatch() {
        foreach ($this->routes as $route) {
            $this->doRoute($route["method"], $route["route"], $route["opts"], $route["func"], $route["group_opts"]);
        }
 
        if (!$this->urlfound) {
            $this->beforeLoad();
            View::notfound();
        } else {
            $this->afterLoad();
        }
 
        
    }
 
    private function doRoute($method, $route, $opts, $func = null, $group_opts = null) {
        if (($_SERVER['REQUEST_METHOD'] == $method || $method == "ALL") && !$this->urlfound) {
 
            $route = $this->urlDiffs($route);
            if ($this->url == $route) {
 
                $this->urlfound = true;
 
/home/www/apollonia.hu/public_html/index.php
<?php
 
require_once __DIR__ . "/../apollonia_app/bootstrap.php";
 
$app = \core\system\Container::getInstance();
$app->setProviders($app_config["providers"]);
 
$app->singleton('core\http\Route', function () {
    return new core\http\Route($_SERVER["REQUEST_URI"]);
});
 
$Route = $app->load('core\http\Route');
 
require_once CORE_DIR . "system/CoreRoutes.php";
require_once APP_DIR . "routes.php";
 
$Route->dispatch();
 

Environment & details:

empty
empty
empty
empty
Key Value
honeypot
"ZWY5ZWE1MDYyZmQ4YTc1MmVjNmExZjgzNzc4ZGVhNGNmMjg3Zjc0NQ=="
Key Value
REDIRECT_HTTPS
"on"
REDIRECT_SSL_TLS_SNI
"apollonia.project.szentivanyi.dev"
REDIRECT_STATUS
"200"
HTTPS
"on"
SSL_TLS_SNI
"apollonia.project.szentivanyi.dev"
HTTP_ACCEPT
"*/*"
HTTP_USER_AGENT
"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)"
HTTP_ACCEPT_ENCODING
"gzip, br, zstd, deflate"
HTTP_HOST
"apollonia.project.szentivanyi.dev"
PATH
"/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin"
SERVER_SIGNATURE
"<address>Apache/2.4.52 (Ubuntu) Server at apollonia.project.szentivanyi.dev Port 443</address>\n"
SERVER_SOFTWARE
"Apache/2.4.52 (Ubuntu)"
SERVER_NAME
"apollonia.project.szentivanyi.dev"
SERVER_ADDR
"128.140.77.195"
SERVER_PORT
"443"
REMOTE_ADDR
"216.73.216.186"
DOCUMENT_ROOT
"/home/www/apollonia.hu/public_html"
REQUEST_SCHEME
"https"
CONTEXT_PREFIX
""
CONTEXT_DOCUMENT_ROOT
"/home/www/apollonia.hu/public_html"
SERVER_ADMIN
"szentivanyi.andras92@gmail.com"
SCRIPT_FILENAME
"/home/www/apollonia.hu/public_html/index.php"
REMOTE_PORT
"31247"
REDIRECT_URL
"/sitemap.xml"
GATEWAY_INTERFACE
"CGI/1.1"
SERVER_PROTOCOL
"HTTP/1.1"
REQUEST_METHOD
"GET"
QUERY_STRING
""
REQUEST_URI
"/sitemap.xml"
SCRIPT_NAME
"/index.php"
PHP_SELF
"/index.php"
REQUEST_TIME_FLOAT
1755613559.47
REQUEST_TIME
1755613559
empty
0. Whoops\Handler\CallbackHandler
1. Whoops\Handler\PrettyPageHandler
2. core\helper\PrettyErrorLogger