$sql = "select count (*) from MSG where (Janl = :KEIZIBAN and sex = :op_sex and flag = 1 and EntPC = :EntPC and Pref = :BFLAG ) or (Janl = :KEIZIBAN and sex = :op_sex and flag = 2 and EntPC = :EntPC and ID > 0 and Pref = :BFLAG)"; #### $sth->bind_param(':KEIZIBAN ',$KEIZIBAN , {ora_type=>ORA_VARCHAR2}); #### $sth->bind_param(':KEIZIBAN ',$KEIZIBAN , {ora_type=>ORA_VARCHAR2}); $sth->bind_param(':KEIZIBAN ',$KEIZIBAN , {ora_type=>ORA_VARCHAR2});