If the http://db.kreie.net URL doesn't work, go to this website to access the scripts and other files used in this video series. https://sites.google.com/view/db-krei...
APEX 18.1 video 18 of 30: Create an interactive report based on SQL. The SQL code combines data from two tables and uses an inner join. Copy an LOV and modify the code. Use an LOV to format a phone number column.
SQL code for interactive report:
select PERSONS.PERS_ID,
FNAME,
MNAME,
LNAME,
ADDR,
ZIP,
PHONE_NUM,
STATUS,
ROLE,
SUPV_ID,
BEGIN_DATE,
END_DATE,
PERSONS.DATE_CREATED,
PERSONS.DATE_MODIFIED
from PERSONS
inner join EMPLOYEES
on PERSONS.PERS_ID = EMPLOYEES.PERS_ID
where status = 'Active'
SQL for phone format:
select substr(phone_num,1,3)||'.'||substr(phone_num,4,3)||'.'||
substr(phone_num,7,4) as phone,
phone_num
from persons
order by 1