17

I am writing a drop statement (in phpMyAdmin) to get rid of some unneeded tables in my database. If I run this query against our live database I am not seeing the full drop statement (it is getting truncated after 50 characters). If I run it against a copy of that database I get the full statement returned.

Any ideas why the behaviour would be different?

SET GROUP_CONCAT_MAX_LEN=10000;
SELECT CONCAT( 'DROP TABLE ', GROUP_CONCAT(table_name) , ';' ) 
AS statement FROM information_schema.tables 
WHERE table_schema = 'dbname' AND table_name LIKE 'prefix%';
0

1 Answer 1

23

Turns out it was phpMyAdmin - needed to show full texts.

Just above the SQL output there is an 'Options' link. Click that and you will see Partial texts/Full texts radio buttons. enter image description here

Note, that when I went back to get the screenshot it was still set to Full Texts so I assume there is a cookie being set which may explain why it was different in one database to the other.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.