Search This Blog

Sunday, February 24, 2019

Group Report In Oracle Apex



Just Create A Region with PL/SQL Dynamic Content Type.
Then copy-pest the code.
This report is just a demo. Do your report yourself. Just you can take the concept .

declare
v_did varchar2(50) :=1000;
v_cnt number;
v_rowspan number;
begin

htp.p('<style>
    tr,th,td{
        border: 1px solid black;
    }
    table{
        width: 100%;
    }

</style>');
htp.p('<table><tr><th>did</th><th>name</th><th>sal</th></tr>');
for i in (select department_id did,  department_name dname from departments where department_id in (select department_id from employees) order by 1 asc) loop


 select count(*) into v_cnt from employees where department_id=i.did;
 v_rowspan :=v_cnt+1;
    htp.p('<tr><td rowspan="'||v_rowspan||'">'||i.did||'</td></tr>');

for a in (select last_name lname, salary sal from employees where department_id =i.did) loop
    if v_did<> i.did then
     htp.p('<tr><td>'||a.lname||'</td><td>'||a.sal||'</td></tr>'); 
    end if;

end loop;

 v_did :=i.did;
end loop;
    htp.p('</table>');
end; 


--Thank You 

Tuesday, February 12, 2019

Instant Search in Oracle Apex by Java Script


1. Create a classic report by your query
2. Take a item for input search content
3. Goto Shared Components >> Templates >>Copy Report (Type)/Standard (Name) with diffrent       name like  Standard2
4. Goto Standard2 >> After Column Heading >> </thead> <tbody id="id" >  and save
5. Goto Report Attributes >> Appearance >>Template >> Standard2
6. Copy the code into Page >> Execute when Page Loads

(Change item name and id)

   $(document).ready(function(){
  $("#P9_SEARCH").on("keyup", function() {
    var value = $(this).val().toLowerCase();
    $("#id tr").filter(function() {
   $(this).toggle($(this).text().toLowerCase().indexOf(value) > -1)
    });
  });
});

Then Enjoy

PDF to Text Covert by Oracle Apex

Here are the steps to convert and get the character into a region by Oracle Apex. Step1.  Create a page and Copy-Pest the below code into Pa...