Created
July 9, 2015 11:52
-
-
Save rupl/a30b8440360081828505 to your computer and use it in GitHub Desktop.
SQL to extract latest revision of body field out of Drupal 7
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT node.title, body.body_value | |
FROM node | |
LEFT JOIN node_revision ON node.vid = node_revision.vid | |
LEFT JOIN field_revision_body AS body ON node_revision.vid = body.revision_id; | |
-- WHERE node.type = 'whatever' | |
-- etc |
Author
rupl
commented
Jul 9, 2015
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment