thanks Binoy.M.V i have to make following changes , $where = "where 1" ; if($_REQUEST[ 'customerno' ] !='') { $where .= "and customernum =".$_REQUEST[ 'customerno' ]."; } if($_REQUEST[ 'businesno' ] !='') { $where .= "and businessrnum =".$_REQUEST[ 'businesno' ]."; } Rahul Dongre Software Engineer Consagous Technologies Pvt. Ltd. The INTERNET now has a personality. YOURS! See your Yahoo! Homepage. http://in.yahoo.com/ [Non-text portions of this message have been removed]