RedBean_Exception_SQL Object
(
    [sqlState:RedBean_Exception_SQL:private] => 42000
    [message:protected] => SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'OR content.id = 2474 OR content.id = 2473 OR content.id = 2472 OR content.id ...' at line 81
    [string:Exception:private] => 
    [code:protected] => 0
    [file:protected] => /var/www/vhosts/dev.decades.com/framework/libs/rb.php
    [line:protected] => 286
    [trace:Exception:private] => Array
        (
            [0] => Array
                (
                    [file] => /var/www/vhosts/dev.decades.com/framework/libs/rb.php
                    [line] => 419
                    [function] => runQuery
                    [class] => RedBean_Driver_PDO
                    [type] => ->
                    [args] => Array
                        (
                            [0] => SELECT content.*,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.published
                      WHEN 'lists' THEN lists.published
                      WHEN 'blog' THEN blog.published
                      ELSE '2015-06-01 00:00:00'
                    END as published,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.active
                      WHEN 'lists' THEN lists.active
                      WHEN 'blog' THEN blog.active
                      ELSE 'no'
                    END as active,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.banner_url
                      WHEN 'lists' THEN lists.header_url
                      WHEN 'blog' THEN blog.og_image
                      ELSE ''
                    END as header_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.tile_image
                      WHEN 'lists' THEN lists.tile_image
                      WHEN 'blog' THEN blog.tile_image
                      ELSE ''
                    END as tile_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.related_image
                      WHEN 'lists' THEN lists.related_image
                      WHEN 'blog' THEN blog.related_image
                      ELSE ''
                    END as related_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.thumbnail_image
                      WHEN 'lists' THEN lists.thumbnail_image
                      WHEN 'blog' THEN blog.thumbnail_image
                      ELSE ''
                    END as thumbnail_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.name
                      WHEN 'lists' THEN lists.name
                      WHEN 'blog' THEN blog.title
                      ELSE ''
                    END as title,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.display_title
                      WHEN 'lists' THEN lists.display_title
                      WHEN 'blog' THEN blog.display_title
                      ELSE ''
                    END as display_title,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.display_description
                      WHEN 'lists' THEN lists.display_description
                      WHEN 'blog' THEN blog.display_description
                      ELSE ''
                    END as display_description,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.description
                      WHEN 'lists' THEN lists.description
                      WHEN 'blog' THEN blog.excerpt
                      ELSE ''
                    END as description,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.tags
                      WHEN 'lists' THEN lists.tags
                      WHEN 'blog' THEN blog.tags
                      ELSE ''
                    END as tags,
                    CASE content.type
                      WHEN 'lists' THEN lists.type
                      ELSE -1
                    END as listtype,
                    CASE content.type
                      WHEN 'blog' THEN blog.is_special
                      ELSE -1
                    END as isspecial
                    /*** any other fields for listing content on homepage ****/
                FROM content
                LEFT JOIN quizzes ON quizzes.id = content.parent_id AND content.type = 'quizzes'
                LEFT JOIN lists ON lists.id = content.parent_id AND content.type = 'lists'
                LEFT JOIN blog ON blog.id = content.parent_id AND content.type = 'blog'
              WHERE (content.id = 1880 OR content.id = 1879 OR content.id = 1856 OR content.id = 1855 OR content.id = 1853 OR content.id = 1850 OR content.id = 1831 OR content.id = 1820 OR content.id = 1819 OR content.id = 1810 OR content.id =  OR content.id = 2474 OR content.id = 2473 OR content.id = 2472 OR content.id = 2471)  
              HAVING active = 'yes' AND (tile_image IS NOT NULL) AND listtype <> 3 AND listtype <> 4 AND isspecial <> 'yes'
              AND published < (NOW() - INTERVAL 1 HOUR)
              
            ORDER BY FIELD(content.id, 1880,1879,1856,1855,1853,1850,1831,1820,1819,1810,,2474,2473,2472,2471) LIMIT 15
                            [1] => Array
                                (
                                )

                        )

                )

            [1] => Array
                (
                    [file] => /var/www/vhosts/dev.decades.com/framework/libs/rb.php
                    [line] => 2308
                    [function] => GetAll
                    [class] => RedBean_Driver_PDO
                    [type] => ->
                    [args] => Array
                        (
                            [0] => SELECT content.*,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.published
                      WHEN 'lists' THEN lists.published
                      WHEN 'blog' THEN blog.published
                      ELSE '2015-06-01 00:00:00'
                    END as published,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.active
                      WHEN 'lists' THEN lists.active
                      WHEN 'blog' THEN blog.active
                      ELSE 'no'
                    END as active,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.banner_url
                      WHEN 'lists' THEN lists.header_url
                      WHEN 'blog' THEN blog.og_image
                      ELSE ''
                    END as header_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.tile_image
                      WHEN 'lists' THEN lists.tile_image
                      WHEN 'blog' THEN blog.tile_image
                      ELSE ''
                    END as tile_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.related_image
                      WHEN 'lists' THEN lists.related_image
                      WHEN 'blog' THEN blog.related_image
                      ELSE ''
                    END as related_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.thumbnail_image
                      WHEN 'lists' THEN lists.thumbnail_image
                      WHEN 'blog' THEN blog.thumbnail_image
                      ELSE ''
                    END as thumbnail_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.name
                      WHEN 'lists' THEN lists.name
                      WHEN 'blog' THEN blog.title
                      ELSE ''
                    END as title,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.display_title
                      WHEN 'lists' THEN lists.display_title
                      WHEN 'blog' THEN blog.display_title
                      ELSE ''
                    END as display_title,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.display_description
                      WHEN 'lists' THEN lists.display_description
                      WHEN 'blog' THEN blog.display_description
                      ELSE ''
                    END as display_description,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.description
                      WHEN 'lists' THEN lists.description
                      WHEN 'blog' THEN blog.excerpt
                      ELSE ''
                    END as description,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.tags
                      WHEN 'lists' THEN lists.tags
                      WHEN 'blog' THEN blog.tags
                      ELSE ''
                    END as tags,
                    CASE content.type
                      WHEN 'lists' THEN lists.type
                      ELSE -1
                    END as listtype,
                    CASE content.type
                      WHEN 'blog' THEN blog.is_special
                      ELSE -1
                    END as isspecial
                    /*** any other fields for listing content on homepage ****/
                FROM content
                LEFT JOIN quizzes ON quizzes.id = content.parent_id AND content.type = 'quizzes'
                LEFT JOIN lists ON lists.id = content.parent_id AND content.type = 'lists'
                LEFT JOIN blog ON blog.id = content.parent_id AND content.type = 'blog'
              WHERE (content.id = 1880 OR content.id = 1879 OR content.id = 1856 OR content.id = 1855 OR content.id = 1853 OR content.id = 1850 OR content.id = 1831 OR content.id = 1820 OR content.id = 1819 OR content.id = 1810 OR content.id =  OR content.id = 2474 OR content.id = 2473 OR content.id = 2472 OR content.id = 2471)  
              HAVING active = 'yes' AND (tile_image IS NOT NULL) AND listtype <> 3 AND listtype <> 4 AND isspecial <> 'yes'
              AND published < (NOW() - INTERVAL 1 HOUR)
              
            ORDER BY FIELD(content.id, 1880,1879,1856,1855,1853,1850,1831,1820,1819,1810,,2474,2473,2472,2471) LIMIT 15
                            [1] => Array
                                (
                                )

                        )

                )

            [2] => Array
                (
                    [file] => /var/www/vhosts/dev.decades.com/framework/libs/rb.php
                    [line] => 9504
                    [function] => get
                    [class] => RedBean_Adapter_DBAdapter
                    [type] => ->
                    [args] => Array
                        (
                            [0] => SELECT content.*,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.published
                      WHEN 'lists' THEN lists.published
                      WHEN 'blog' THEN blog.published
                      ELSE '2015-06-01 00:00:00'
                    END as published,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.active
                      WHEN 'lists' THEN lists.active
                      WHEN 'blog' THEN blog.active
                      ELSE 'no'
                    END as active,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.banner_url
                      WHEN 'lists' THEN lists.header_url
                      WHEN 'blog' THEN blog.og_image
                      ELSE ''
                    END as header_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.tile_image
                      WHEN 'lists' THEN lists.tile_image
                      WHEN 'blog' THEN blog.tile_image
                      ELSE ''
                    END as tile_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.related_image
                      WHEN 'lists' THEN lists.related_image
                      WHEN 'blog' THEN blog.related_image
                      ELSE ''
                    END as related_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.thumbnail_image
                      WHEN 'lists' THEN lists.thumbnail_image
                      WHEN 'blog' THEN blog.thumbnail_image
                      ELSE ''
                    END as thumbnail_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.name
                      WHEN 'lists' THEN lists.name
                      WHEN 'blog' THEN blog.title
                      ELSE ''
                    END as title,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.display_title
                      WHEN 'lists' THEN lists.display_title
                      WHEN 'blog' THEN blog.display_title
                      ELSE ''
                    END as display_title,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.display_description
                      WHEN 'lists' THEN lists.display_description
                      WHEN 'blog' THEN blog.display_description
                      ELSE ''
                    END as display_description,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.description
                      WHEN 'lists' THEN lists.description
                      WHEN 'blog' THEN blog.excerpt
                      ELSE ''
                    END as description,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.tags
                      WHEN 'lists' THEN lists.tags
                      WHEN 'blog' THEN blog.tags
                      ELSE ''
                    END as tags,
                    CASE content.type
                      WHEN 'lists' THEN lists.type
                      ELSE -1
                    END as listtype,
                    CASE content.type
                      WHEN 'blog' THEN blog.is_special
                      ELSE -1
                    END as isspecial
                    /*** any other fields for listing content on homepage ****/
                FROM content
                LEFT JOIN quizzes ON quizzes.id = content.parent_id AND content.type = 'quizzes'
                LEFT JOIN lists ON lists.id = content.parent_id AND content.type = 'lists'
                LEFT JOIN blog ON blog.id = content.parent_id AND content.type = 'blog'
              WHERE (content.id = 1880 OR content.id = 1879 OR content.id = 1856 OR content.id = 1855 OR content.id = 1853 OR content.id = 1850 OR content.id = 1831 OR content.id = 1820 OR content.id = 1819 OR content.id = 1810 OR content.id =  OR content.id = 2474 OR content.id = 2473 OR content.id = 2472 OR content.id = 2471)  
              HAVING active = 'yes' AND (tile_image IS NOT NULL) AND listtype <> 3 AND listtype <> 4 AND isspecial <> 'yes'
              AND published < (NOW() - INTERVAL 1 HOUR)
              
            ORDER BY FIELD(content.id, 1880,1879,1856,1855,1853,1850,1831,1820,1819,1810,,2474,2473,2472,2471) LIMIT 15
                            [1] => Array
                                (
                                )

                        )

                )

            [3] => Array
                (
                    [file] => /var/www/vhosts/dev.decades.com/framework/libs/rb.php
                    [line] => 10295
                    [function] => query
                    [class] => RedBean_Facade
                    [type] => ::
                    [args] => Array
                        (
                            [0] => get
                            [1] => SELECT content.*,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.published
                      WHEN 'lists' THEN lists.published
                      WHEN 'blog' THEN blog.published
                      ELSE '2015-06-01 00:00:00'
                    END as published,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.active
                      WHEN 'lists' THEN lists.active
                      WHEN 'blog' THEN blog.active
                      ELSE 'no'
                    END as active,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.banner_url
                      WHEN 'lists' THEN lists.header_url
                      WHEN 'blog' THEN blog.og_image
                      ELSE ''
                    END as header_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.tile_image
                      WHEN 'lists' THEN lists.tile_image
                      WHEN 'blog' THEN blog.tile_image
                      ELSE ''
                    END as tile_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.related_image
                      WHEN 'lists' THEN lists.related_image
                      WHEN 'blog' THEN blog.related_image
                      ELSE ''
                    END as related_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.thumbnail_image
                      WHEN 'lists' THEN lists.thumbnail_image
                      WHEN 'blog' THEN blog.thumbnail_image
                      ELSE ''
                    END as thumbnail_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.name
                      WHEN 'lists' THEN lists.name
                      WHEN 'blog' THEN blog.title
                      ELSE ''
                    END as title,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.display_title
                      WHEN 'lists' THEN lists.display_title
                      WHEN 'blog' THEN blog.display_title
                      ELSE ''
                    END as display_title,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.display_description
                      WHEN 'lists' THEN lists.display_description
                      WHEN 'blog' THEN blog.display_description
                      ELSE ''
                    END as display_description,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.description
                      WHEN 'lists' THEN lists.description
                      WHEN 'blog' THEN blog.excerpt
                      ELSE ''
                    END as description,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.tags
                      WHEN 'lists' THEN lists.tags
                      WHEN 'blog' THEN blog.tags
                      ELSE ''
                    END as tags,
                    CASE content.type
                      WHEN 'lists' THEN lists.type
                      ELSE -1
                    END as listtype,
                    CASE content.type
                      WHEN 'blog' THEN blog.is_special
                      ELSE -1
                    END as isspecial
                    /*** any other fields for listing content on homepage ****/
                FROM content
                LEFT JOIN quizzes ON quizzes.id = content.parent_id AND content.type = 'quizzes'
                LEFT JOIN lists ON lists.id = content.parent_id AND content.type = 'lists'
                LEFT JOIN blog ON blog.id = content.parent_id AND content.type = 'blog'
              WHERE (content.id = 1880 OR content.id = 1879 OR content.id = 1856 OR content.id = 1855 OR content.id = 1853 OR content.id = 1850 OR content.id = 1831 OR content.id = 1820 OR content.id = 1819 OR content.id = 1810 OR content.id =  OR content.id = 2474 OR content.id = 2473 OR content.id = 2472 OR content.id = 2471)  
              HAVING active = 'yes' AND (tile_image IS NOT NULL) AND listtype <> 3 AND listtype <> 4 AND isspecial <> 'yes'
              AND published < (NOW() - INTERVAL 1 HOUR)
              
            ORDER BY FIELD(content.id, 1880,1879,1856,1855,1853,1850,1831,1820,1819,1810,,2474,2473,2472,2471) LIMIT 15
                            [2] => Array
                                (
                                )

                        )

                )

            [4] => Array
                (
                    [file] => /var/www/vhosts/dev.decades.com/framework/models/model_content.php
                    [line] => 136
                    [function] => getAll
                    [class] => RedBean_Facade
                    [type] => ::
                    [args] => Array
                        (
                            [0] => SELECT content.*,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.published
                      WHEN 'lists' THEN lists.published
                      WHEN 'blog' THEN blog.published
                      ELSE '2015-06-01 00:00:00'
                    END as published,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.active
                      WHEN 'lists' THEN lists.active
                      WHEN 'blog' THEN blog.active
                      ELSE 'no'
                    END as active,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.banner_url
                      WHEN 'lists' THEN lists.header_url
                      WHEN 'blog' THEN blog.og_image
                      ELSE ''
                    END as header_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.tile_image
                      WHEN 'lists' THEN lists.tile_image
                      WHEN 'blog' THEN blog.tile_image
                      ELSE ''
                    END as tile_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.related_image
                      WHEN 'lists' THEN lists.related_image
                      WHEN 'blog' THEN blog.related_image
                      ELSE ''
                    END as related_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.thumbnail_image
                      WHEN 'lists' THEN lists.thumbnail_image
                      WHEN 'blog' THEN blog.thumbnail_image
                      ELSE ''
                    END as thumbnail_image,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.name
                      WHEN 'lists' THEN lists.name
                      WHEN 'blog' THEN blog.title
                      ELSE ''
                    END as title,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.display_title
                      WHEN 'lists' THEN lists.display_title
                      WHEN 'blog' THEN blog.display_title
                      ELSE ''
                    END as display_title,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.display_description
                      WHEN 'lists' THEN lists.display_description
                      WHEN 'blog' THEN blog.display_description
                      ELSE ''
                    END as display_description,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.description
                      WHEN 'lists' THEN lists.description
                      WHEN 'blog' THEN blog.excerpt
                      ELSE ''
                    END as description,
                    CASE content.type
                      WHEN 'quizzes' THEN quizzes.tags
                      WHEN 'lists' THEN lists.tags
                      WHEN 'blog' THEN blog.tags
                      ELSE ''
                    END as tags,
                    CASE content.type
                      WHEN 'lists' THEN lists.type
                      ELSE -1
                    END as listtype,
                    CASE content.type
                      WHEN 'blog' THEN blog.is_special
                      ELSE -1
                    END as isspecial
                    /*** any other fields for listing content on homepage ****/
                FROM content
                LEFT JOIN quizzes ON quizzes.id = content.parent_id AND content.type = 'quizzes'
                LEFT JOIN lists ON lists.id = content.parent_id AND content.type = 'lists'
                LEFT JOIN blog ON blog.id = content.parent_id AND content.type = 'blog'
              WHERE (content.id = 1880 OR content.id = 1879 OR content.id = 1856 OR content.id = 1855 OR content.id = 1853 OR content.id = 1850 OR content.id = 1831 OR content.id = 1820 OR content.id = 1819 OR content.id = 1810 OR content.id =  OR content.id = 2474 OR content.id = 2473 OR content.id = 2472 OR content.id = 2471)  
              HAVING active = 'yes' AND (tile_image IS NOT NULL) AND listtype <> 3 AND listtype <> 4 AND isspecial <> 'yes'
              AND published < (NOW() - INTERVAL 1 HOUR)
              
            ORDER BY FIELD(content.id, 1880,1879,1856,1855,1853,1850,1831,1820,1819,1810,,2474,2473,2472,2471) LIMIT 15
                        )

                )

            [5] => Array
                (
                    [file] => /var/www/vhosts/dev.decades.com/framework/models/model_content.php
                    [line] => 536
                    [function] => get_all_content
                    [class] => Model_Content
                    [type] => ::
                    [args] => Array
                        (
                            [0] => Array
                                (
                                    [0] => 1880
                                    [1] => 1879
                                    [2] => 1856
                                    [3] => 1855
                                    [4] => 1853
                                    [5] => 1850
                                    [6] => 1831
                                    [7] => 1820
                                    [8] => 1819
                                    [9] => 1810
                                    [10] => 
                                    [11] => 2474
                                    [12] => 2473
                                    [13] => 2472
                                    [14] => 2471
                                )

                            [1] => 15
                            [2] => 
                            [3] => ORDER BY FIELD(content.id, 1880,1879,1856,1855,1853,1850,1831,1820,1819,1810,,2474,2473,2472,2471)
                        )

                )

            [6] => Array
                (
                    [file] => /var/www/vhosts/dev.decades.com/framework/classes/quiz.php
                    [line] => 204
                    [function] => get_related_items
                    [class] => Model_Content
                    [type] => ::
                    [args] => Array
                        (
                            [0] => quizzes
                            [1] => 
                            [2] => quiz
                            [3] => 3
                            [4] => 1854
                        )

                )

            [7] => Array
                (
                    [file] => /var/www/vhosts/dev.decades.com/framework/classes/quiz.php
                    [line] => 108
                    [function] => _single_page_template
                    [class] => Quiz
                    [type] => ->
                    [args] => Array
                        (
                        )

                )

            [8] => Array
                (
                    [file] => /var/www/vhosts/dev.decades.com/framework/classes/quiz.php
                    [line] => 228
                    [function] => _find_page
                    [class] => Quiz
                    [type] => ->
                    [args] => Array
                        (
                            [0] => https://dev.decades.com/quiz/can-you-recognize-your-favorite-black-and-white-tv-shows-in-full-color
                            [1] => 
                        )

                )

            [9] => Array
                (
                    [file] => /var/www/vhosts/dev.decades.com/index.php
                    [line] => 228
                    [function] => __call
                    [class] => Quiz
                    [type] => ->
                    [args] => Array
                        (
                            [0] => can-you-recognize-your-favorite-black-and-white-tv-shows-in-full-color
                            [1] => Array
                                (
                                    [0] => Array
                                        (
                                        )

                                )

                        )

                )

        )

    [previous:Exception:private] => 
)