Solved thread

This post is marked as solved. If you think the information contained on this thread must be part of the official documentation, please contribute submitting a pull request to its repository.

Keyword Group in ORM Find Query

I'm not certain this is a bug, yet I'm getting the following error:

Scanning error before 'group` = :group:...' when parsing: SELECT [UserSetting].* FROM [UserSetting] WHERE user_id = :user_id: AND `group` = :group: (89)
    $setting = \UserSetting::find([
            "user_id = :user_id: AND `group` = :group:",
            "bind" => [
                "user_id" => $this->session->get('id'),
                "group" => 'email'
            ]
        ]);

I have a table for settings where I have these columns (Three reserved keywords that should be safe by backticks):

id, user_id, group, key, value

Anyone have any Advice?



81.7k
Accepted
answer