Blog Updated 2

This post is more than 2 years old.

  1. rss.cfm now looks for additional url parameters - basically the same as index.cfm. The feed can now be filtered by category, so if you want, you can syndicate just my ColdFusion content, and nothing else.

  2. getEntries returns two new cols: categoryIDs and CategoryNames. These are both lists where the Nth ID matches the Nth name.

  3. Index.cfm updated to show categories and pass filtering information to rss.cfm.

I'm not entirely happy with the code in getEntries. It seems to me that there should be an easier way to do this:

Table A has records. Table B has records. Table C is a table that defines relationships between A and B. I want to select from A and set a value, "B", which represnts all the records in C where C.A_ID = A.ID. I know it can be done with a stored procedure, but I'm surprised there isn't a way to do this in simple SQL. Something like:

select id, name, categoryNames as (select ....),

Raymond Camden's Picture

About Raymond Camden

Raymond is a senior developer evangelist for Adobe. He focuses on document services, JavaScript, and enterprise cat demos. If you like this article, please consider visiting my Amazon Wishlist or donating via PayPal to show your support. You can even buy me a coffee!

Lafayette, LA https://www.raymondcamden.com

Archived Comments

Comment 1 by Howard Fore posted on 5/23/2003 at 3:37 PM

You''re close:

Select id, name, (select foo from tableB) as categoryNames
from tableA

At least that''s how I''m doing it in SQL Server 2000

hofo

Comment 2 by Raymond Camden posted on 5/23/2003 at 3:43 PM

That only works when the subquery returns one record. Some blog entries have N categories assigned to them.

Comment 3 by seancorfield posted on 5/23/2003 at 7:22 PM

Can you provide a "usage guide" for rss.cfm for folks who read your blog that way? What is the URL API?

Comment 4 by Rob Brooks-Bilson posted on 5/23/2003 at 10:57 PM

I''ve been thinking about the short mode vs. long mode (ala whether to provide the full content of a post vs. a summary with link to the main post) and I have a question ergarding formatting. Should the full post contain the "raw" text, with not HTML formatting, or would you prefer it to come across with HTML formatting included? I''m not sure how the blog readers everyone is using handles the whitespace in the RSS feed, but I''d think you wouldn''t want to get a big jumble if the blog post contains both text and code.