Last active
January 4, 2016 20:29
-
-
Save adrienne/8674158 to your computer and use it in GitHub Desktop.
Useful EE-Related SQL Snippets
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 concat( 'field_id_' , field_id , ' AS ' , field_name , ',' ) AS fieldget | |
FROM exp_channel_fields | |
WHERE group_id = 3 | |
UNION | |
SELECT 'entry_id AS eid' AS fieldget |
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 | |
CONCAT( 'ALTER TABLE exp_channel_data MODIFY COLUMN field_ft_' , field_id , ' VARCHAR(128);' ) | |
FROM | |
exp_channel_fields; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment