Creating RSS Feed in Oracle APEX
Published on 20 Jul 2025 by CHATURVEDINIDHI26@GMAIL.COM
How to Create an RSS Feed in Oracle APEX
1. Introduction
This guide explains how to generate a valid RSS XML Feed from your Oracle APEX application without using RESTful services. It’s ideal for sharing blog updates with users or feed readers.
2. Prerequisites
- A table like
BLOG\_POSTS
containing blog content.
- Published blog posts stored with a status column (e.g.,
STATUS = 'PUBLISHED'
).
- Oracle APEX app with public page access enabled.
3. SQL Source
Your blog data source can look like this:
SELECT ID, TITLE, SHORT\_DESC, CREATED\_DATE
FROM BLOG\_POSTS
WHERE STATUS = 'PUBLISHED'
ORDER BY CREATED\_DATE DESC;
4. PL/SQL Code to Generate RSS
Create a PL/SQL Dynamic Content Region with this code:
BEGIN
owa\_util.mime\_header('text/xml', FALSE);
htp.p('Cache-Control: no-cache');
owa\_util.http\_header\_close;
htp.p('<?xml version="1.0" encoding="UTF-8"?>');
htp.p('<rss version="2.0"><channel>');
htp.p('<title>My Blog RSS</title>');
htp.p('<link>https://apex.oracle.com/pls/apex/r/myblog/rss-feed</link>');
htp.p('<description>Latest blog posts</description>');
FOR rec IN (
SELECT ID, TITLE, SHORT\_DESC, CREATED\_DATE
FROM BLOG\_POSTS
WHERE STATUS = 'PUBLISHED'
ORDER BY CREATED\_DATE DESC
FETCH FIRST 10 ROWS ONLY
) LOOP
htp.p('<item>');
htp.p('<title>' || apex\_escape.html(rec.TITLE) || '</title>');
htp.p('<link>https://apex.oracle.com/pls/apex/r/myblog/view-blog-post?p16\_id=' || rec.ID || '</link>');
htp.p('<description>' || apex\_escape.html(rec.SHORT\_DESC) || '</description>');
htp.p('<pubDate>' || TO\_CHAR(rec.CREATED\_DATE, 'Dy, DD Mon YYYY HH24:MI:SS') || ' GMT</pubDate>');
htp.p('</item>');
END LOOP;
htp.p('</channel></rss>');
apex\_application.stop\_apex\_engine;
END;
5. Page Settings
- Set the page as Public (Authentication: Page is Public).
- Remove any UI elements — it should return only XML.
- Test the page URL, e.g.:
https://apex.oracle.com/pls/apex/r/myblog/rss-feed
6. Add RSS Link to Blog
Use this in your blog’s HTML to add an RSS link:
<a href="https://apex.oracle.com/pls/apex/r/myblog/rss-feed" target="\_blank">
<img src="https://img.icons8.com/fluency/48/rss.png" alt="RSS Feed" style="vertical-align:middle;" /> Subscribe via RSS
</a>
7. Conclusion
You’ve now created a fully functional RSS feed in Oracle APEX using PL/SQL and a public page. You can share this URL with users or connect it to platforms like Feedly, Outlook, or other RSS readers.