PL/SQL Functions


function fnc_my_function(p_id number) return number is
    v_counter       number := 0;
   
    begin
       
        select count(k.varsayilan)
        into v_count
        from test_table k
        where id=p_id;
     
        return v_counter;
                                         
        exception
            when no_data_found
            then
            return null ;
       
    end ;

-- Test the function


select package_name.fnc_my_function(65243)
from dual;

Comments

Popular posts from this blog

Solution for "Can not obtain Oracle client information from registry"

Solution for the fault: "System.Diagnostics.Process.Start is not working on IIS, but working on ASP.NET Development Server"