By pkx on
I incorrectly imported a bunch of blog entries from Wordpress as filtered HTML.
Can anyone help me with an SQL query or something to quickly switch them all to full HTML? I see the type in the node_revisions table, but I don't know how to identify just my blog entries.
Thanks!
Comments
I did something similar once
I did something similar once when I imported a large phpBB forum. Try this:
UPDATE node_revisions SET format = 3 WHERE type = blogThis assumes that the Full HTML input format is "3" (which is the default for D5).
#1054 - Unknown column
#1054 - Unknown column 'type' in 'where clause'
I don't have a 'type' column in the node_revisions table. I've got nid, vid, uid, title, body, teaser, log, timestamp, and format. This is Drupal 5.1 (just upgraded from 5.0 last night).
The lack of 'type' is why I couldn't figure it out myself :). Any ideas?
The type is stored in {node}
The type is stored in {node} so you'll need to write a SQL query that UPDATEs {node_revision}s based on the type assosciated with that nid (node id) in the {node} table. unfortunatly my sql skills are pathetic.
Thanks! I got it with the
Thanks!
I got it with the help of a SQL-Ninja friend of mine:
update node_revisions set format = 3 where nid in (select nid from node where type = 'blog')