+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| MySql database error                                                                                                                                                         |
+-------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Text  | Unable to send the query to the MySql server.                                                                                                                        |
|       | Statement:                                                                                                                                                           |
|       |    SELECT articlePage.pageId                                                                                                                                         |
|       |    , articlePage.title                                                                                                                                               |
|       |    , UNIX_TIMESTAMP(articlePage.eventDateTime) AS pageDate                                                                                                           |
|       |                                                                                                                                                                      |
|       |    , p_article.teaser                                                                                                                                                |
|       |    , p_article.text                                                                                                                                                  |
|       |    , p_article.location                                                                                                                                              |
|       |    , p_article.showMoreText                                                                                                                                          |
|       |    , p_article.published                                                                                                                                             |
|       |    , authorUser.fuldeNavn  AS authorName                                                                                                                             |
|       |    , authorUser.email      AS authorEmail                                                                                                                            |
|       |   FROM p_page AS articlePage                                                                                                                                         |
|       |    , p_article                                                                                                                                                       |
|       |    , p_field                                                                                                                                                         |
|       |    LEFT JOIN bruger AS authorUser ON authorUser.brugerId = articlePage.ownerUserId                                                                                   |
|       |                                                                                                                                                                      |
|       |    WHERE                                                                                                                                                             |
|       |    AND articlePage.pageId != 100                                                                                                                                     |
|       |    AND articlePage.pageState = 'online'                                                                                                                              |
|       |    AND articlePage.deleted = 'false'                                                                                                                                 |
|       |    AND ( articlePage.status = 'online' OR ( articlePage.status = 'dateControlled'                                                                                    |
|       |      AND NOW() BETWEEN articlePage.onlineFrom AND articlePage.onlineTo )                                                                                             |
|       |    )                                                                                                                                                                 |
|       |    AND articlePage.showIn != 'none'                                                                                                                                  |
|       |                                                                                                                                                                      |
|       |   AND articlePage.eventDateTime <= NOW()                                                                                                                             |
|       |    AND p_article.pageId = articlePage.pageId                                                                                                                         |
|       |    AND p_article.pageState = articlePage.pageState                                                                                                                   |
|       |    AND p_field.fieldId = p_article.fieldId                                                                                                                           |
|       |    AND p_field.pageId = articlePage.pageId                                                                                                                           |
|       |    AND p_field.pageState = articlePage.pageState                                                                                                                     |
|       |   GROUP BY p_article.fieldId                                                                                                                                         |
|       | ORDER BY articlePage.eventDateTime DESC                                                                                                                              |
|       | LIMIT 20                                                                                                                                                             |
| Errno | 1064                                                                                                                                                                 |
| 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 'AND articlePage.pageId != 100 |
|       |    AND articlePage.pageState = 'online'                                                                                                                              |
|       |    AND art' at line 20                                                                                                                                               |
+-------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+

Fatal error: Call to a member function next() on a non-object in /srv/web/bibliotek/egebib.dk/www/easysite/class/ArticleList.class.php on line 276