<?php
     $session =& JFactory::getSession();
     $status1 = $session->get('status', '0');
     $searchrec = $status1;

     $userid = $session->get('cf_user_id', '0');
     $suserid=$userid;
     echo "WHERE status='$searchrec'AND cf_user_id=$suserid";
?>