It should check all the variables, and if they are all empty, then it should leave $where empty, else it should assign it to "WHERE" (SQL select statment is based on this)
Code: Select all
echo $where, $testset, $testsetand, $suiteset, $suitesetand, $groupset, $groupsetand, $productset, $productsetand, $statusset, $statussetand, $ownerset;
echo "<br>";
if ((!isset($testset)) && (!isset($testsetand)) && (!isset($suiteset)) && (!isset($suitesetand)) && (!isset($groupset)) && (!isset($groupsetand)) && (!isset($productset)) && (!isset($productsetand)) && (!isset($statusset)) && (!isset($statussetand)) && (!isset($ownerset)))
{
$where = "WHERE";
echo "Set Where";
echo "<br>";
}
else
{
$where = "";
echo "no where";
echo "<br>";
}Help, this should work as far as I can see.
Cheers all
LinkJames
*Edit* Meant to say, where I have echoed the variables out, I get a blank line or the variables, so I know they are getting assigned, or left empty as they should be