Thursday 15 January 2015

MYSQL - Get all %char% and %text% columns with value length of at least x? -


Is there any way I can do something like the following?

  Table 'where' ("% char%" like the `type 'or" type% "like` type') and MAX (CHAR_LENGTH (`field`) gt; The output should include all such % char%  and % text%  fields with the values ​​in which PHP is the length of PHP The variable is equal to or greater than   

If you have access to information_schema, you can easily capture data Check from * info_schema.column where (data_type = '% char' or '% text' as the data_type) and character_maxim_long & gt; 10

No comments:

Post a Comment