I'm not sure if this is a D5 only issue or not, but there are definitely content_types in D5 that are code only and node_type is not completely reliable as a source for node type data. Getting distinct types from node might be a better solution. I spent a little effort toward this end. We don't have a good way of getting at the metadata about the node type either since it's not in the node_type table anyway, so I mitigated that as best as I could. I've not altered the node_type count query at all, but we should probably look at that as well.

Eclipse

CommentFileSizeAuthor
#1 2143937-1.patch1.03 KBEclipseGc
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

EclipseGc’s picture

FileSize
1.03 KB

initial patch

Eclipse

mikeryan’s picture

Component: Code » D5-specific
Status: Active » Needs work

Is COALESCE portable?

This would omit any node types defined in the table which currently had no actual nodes - which is probably a good thing, but wanted to point that out.