Notification of password expiration trigger
I am trying to create a logon trigger that notifys users their password is about to expire. Here is a piece of the code. How would I give this notification message after logon?
SELECT trunc(expiry_date) - trunc(lv_date)
INTO v_expiry_time
FROM dba_users
WHERE username IN (SELECT USER FROM dual);
if v_expiry_time > 0 and v_expiry_time <= 10 then
/*give this message --> 'Your password will expire in ' || v_expiry_time || ' day(s).' */
end if;