Skip to content

Instantly share code, notes, and snippets.

@shestakow1993
Last active May 17, 2018 10:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shestakow1993/27a278fddf2521e31f006561fe2afb58 to your computer and use it in GitHub Desktop.
Save shestakow1993/27a278fddf2521e31f006561fe2afb58 to your computer and use it in GitHub Desktop.
select TABLE_NAME from information_schema.TABLES WHERE TABLE_TYPE='BASE TABLE' and TABLE_SCHEMA ='bgbilling' and TABLE_NAME LIKE 'pattern1%'INTO OUTFILE '/tmp/passwdp1.txt' ;
select TABLE_NAME from information_schema.TABLES WHERE TABLE_TYPE='BASE TABLE' and TABLE_SCHEMA ='bgbilling' and TABLE_NAME LIKE 'pattern2%'INTO OUTFILE '/tmp/passwdp2.txt' ;
....
....
select TABLE_NAME from information_schema.TABLES WHERE TABLE_TYPE='BASE TABLE' and TABLE_SCHEMA ='bgbilling' and TABLE_NAME LIKE 'patternN%'INTO OUTFILE '/tmp/passwdpn.txt' ;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment