Error
Database query error
Query:
SELECT COUNT(DISTINCT IF( `Profiles`.`Couple`=0, `Profiles`.`ID`, IF( `Profiles`.`Couple`>`Profiles`.`ID`, `Profiles`.`ID`, `Profiles`.`Couple` ) )) AS "Cnt" FROM `Profiles` WHERE `Profiles`.`Status` = 'Active' AND DATE_ADD( `DateLastNav`, INTERVAL MINUTE ) >= NOW() AND (`Profiles`.`Couple`='0' OR `Profiles`.`Couple`>`Profiles`.`ID`)
Mysql 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 ') >= NOW() AND (`Profiles`.`Couple`='0' OR `Profiles`.`Couple`>`Profiles`.`ID`)' at line 1
Found error in file /home/nichead1/public_html/datinguniversal.com/search.php
at line 442. Called db_value function with erroneous argument #0

Debug backtrace:
Array
(
    [1] => Array
        (
            [file] => /home/nichead1/public_html/datinguniversal.com/inc/db.inc.php
            [line] => 104
            [function] => db_res
            [args] => Array
                (
                    [0] => SELECT COUNT(DISTINCT IF( `Profiles`.`Couple`=0, `Profiles`.`ID`, IF( `Profiles`.`Couple`>`Profiles`.`ID`, `Profiles`.`ID`, `Profiles`.`Couple` ) )) AS "Cnt" FROM `Profiles`  WHERE `Profiles`.`Status` = 'Active' AND DATE_ADD( `DateLastNav`, INTERVAL  MINUTE ) >= NOW() AND (`Profiles`.`Couple`='0' OR `Profiles`.`Couple`>`Profiles`.`ID`)
                    [1] => 1
                )

        )

    [2] => Array
        (
            [file] => /home/nichead1/public_html/datinguniversal.com/inc/db.inc.php
            [line] => 120
            [function] => db_arr
            [args] => Array
                (
                    [0] => SELECT COUNT(DISTINCT IF( `Profiles`.`Couple`=0, `Profiles`.`ID`, IF( `Profiles`.`Couple`>`Profiles`.`ID`, `Profiles`.`ID`, `Profiles`.`Couple` ) )) AS "Cnt" FROM `Profiles`  WHERE `Profiles`.`Status` = 'Active' AND DATE_ADD( `DateLastNav`, INTERVAL  MINUTE ) >= NOW() AND (`Profiles`.`Couple`='0' OR `Profiles`.`Couple`>`Profiles`.`ID`)
                    [1] => 1
                )

        )

    [3] => Array
        (
            [file] => /home/nichead1/public_html/datinguniversal.com/search.php
            [line] => 442
            [function] => db_value
            [args] => Array
                (
                    [0] => SELECT COUNT(DISTINCT IF( `Profiles`.`Couple`=0, `Profiles`.`ID`, IF( `Profiles`.`Couple`>`Profiles`.`ID`, `Profiles`.`ID`, `Profiles`.`Couple` ) )) AS "Cnt" FROM `Profiles`  WHERE `Profiles`.`Status` = 'Active' AND DATE_ADD( `DateLastNav`, INTERVAL  MINUTE ) >= NOW() AND (`Profiles`.`Couple`='0' OR `Profiles`.`Couple`>`Profiles`.`ID`)
                )

        )

    [4] => Array
        (
            [file] => /home/nichead1/public_html/datinguniversal.com/search.php
            [line] => 66
            [function] => PageCodeSearchResult
            [args] => Array
                (
                    [0] => Array
                        (
                        )

                )

        )

)
Called script: ///search.php
Request parameters:
Array
(
    [online_only] => 1
)