ERROR

Array
(
    [0] => Array
        (
            [date] => 14/08/2018
            [time] => 16:09:30.1534259370.9091
            [host] => www.apollodirect.co.uk
            [request] => /
            [remoteIp] => 54.198.96.198
            [segments] => 
            [rewrittenSegments] => 
            [controllerPath] => 
            [controllerName] => default
            [method] => index
            [methodArguments] => 
            [securityObject] => default.index
            [errorType] => WARNING
            [errorCode] => 8
            [errorMessage] => Undefined property: stdClass::$AffinityId
            [errorFile] => /var/amazon/apps/amazon/application/library/general.php
            [errorLine] => 153
        )

    [1] => Array
        (
            [date] => 14/08/2018
            [time] => 16:09:30.1534259370.9092
            [host] => www.apollodirect.co.uk
            [request] => /
            [remoteIp] => 54.198.96.198
            [segments] => 
            [rewrittenSegments] => 
            [controllerPath] => 
            [controllerName] => default
            [method] => index
            [methodArguments] => 
            [securityObject] => default.index
            [errorType] => WARNING
            [errorCode] => 8
            [errorMessage] => Undefined property: stdClass::$CustomerNiceName
            [errorFile] => /var/amazon/apps/amazon/application/library/general.php
            [errorLine] => 154
        )

    [2] => Array
        (
            [date] => 14/08/2018
            [time] => 16:09:30.1534259370.9092
            [host] => www.apollodirect.co.uk
            [request] => /
            [remoteIp] => 54.198.96.198
            [segments] => 
            [rewrittenSegments] => 
            [controllerPath] => 
            [controllerName] => default
            [method] => index
            [methodArguments] => 
            [securityObject] => default.index
            [errorType] => WARNING
            [errorCode] => 8
            [errorMessage] => Undefined property: stdClass::$AffinityId
            [errorFile] => /var/amazon/apps/amazon/application/library/general.php
            [errorLine] => 155
        )

    [3] => Array
        (
            [date] => 14/08/2018
            [time] => 16:09:30.1534259370.9102
            [host] => www.apollodirect.co.uk
            [request] => /
            [remoteIp] => 54.198.96.198
            [segments] => 
            [rewrittenSegments] => 
            [controllerPath] => 
            [controllerName] => default
            [method] => index
            [methodArguments] => 
            [securityObject] => default.index
            [errorType] => WARNING
            [errorCode] => 8
            [errorMessage] => Undefined property: stdClass::$AmazonDatabase
            [errorFile] => /var/amazon/apps/amazon/application/library/general.php
            [errorLine] => 112
        )

    [4] => Array
        (
            [date] => 14/08/2018
            [time] => 16:09:30.1534259370.9102
            [host] => www.apollodirect.co.uk
            [request] => /
            [remoteIp] => 54.198.96.198
            [segments] => 
            [rewrittenSegments] => 
            [controllerPath] => 
            [controllerName] => default
            [method] => index
            [methodArguments] => 
            [securityObject] => default.index
            [errorType] => WARNING
            [errorCode] => 8
            [errorMessage] => Undefined property: stdClass::$AffinityId
            [errorFile] => /var/amazon/apps/amazon/application/library/general.php
            [errorLine] => 169
        )

    [5] => Array
        (
            [date] => 14/08/2018
            [time] => 16:09:30.1534259370.9105
            [host] => www.apollodirect.co.uk
            [request] => /
            [remoteIp] => 54.198.96.198
            [segments] => 
            [rewrittenSegments] => 
            [controllerPath] => 
            [controllerName] => default
            [method] => index
            [methodArguments] => 
            [securityObject] => default.index
            [errorType] => FATAL
            [errorCode] => 256
            [errorMessage] => Could not execute query [Native Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'WHERE AffinityId = NULL LIMIT 1' at line 1] [User Info: SELECT * FROM  WHERE AffinityId = NULL LIMIT 1] (SELECT * FROM  WHERE AffinityId = ? LIMIT 1)
            [errorFile] => /var/amazon/core/framework/database.php
            [errorLine] => 165
        )

)