forums › forums › SQLyog › Query Builder and Schema Designer › Query In A Specific Table In All Databases
- This topic is empty.
-
AuthorPosts
-
-
September 27, 2011 at 2:26 am #12461Seyfi GoMember
Hello,
i must create a query and need your help
i have 134 databases under same connection.
i must execute a query for finding and removing the rows including “string1,string2,…string8” from “wp-post” tables
but without querying all of tables.
which is the best way to find and delete the rows with theses strings without querying more than 2650 tables in 134 databases.
i will be grateful if you can help me
Best Regards
seyfigo
-
September 27, 2011 at 6:41 am #32674peterlaursenParticipant
You should consider using the Data Search feature introduced in SQLyog Ultimate 9.1 and 9.2. Refer http://webyog.com/faq/content/33/7/en/sqlyog-version-history.html
Once the rows have been found you can check the checkbox for each (shift+click operator is suported) and delete. It willl still take a little time but much faster than executing a query for each table. Please first read about Data Search in the help file (help .. help menu) to understand exactly how it works – and I would also enssure a backup first.
-
November 14, 2011 at 12:23 am #32675Seyfi GoMember'peterlaursen' wrote:
You should consider using the Data Search feature introduced in SQLyog Ultimate 9.1 and 9.2. Refer http://webyog.com/faq/content/33/7/en/sqlyog-version-history.html
Once the rows have been found you can check the checkbox for each (shift+click operator is suported) and delete. It willl still take a little time but much faster than executing a query for each table. Please first read about Data Search in the help file (help .. help menu) to understand exactly how it works – and I would also enssure a backup first.
Dear Peter,
thank you for your response but i have entreprise version ! not ultimate, is there a way to make it with sql queries ?
thaank you
Seyfi Go
-
November 14, 2011 at 8:15 am #32676Jan.SMember
Hi Seyfigo,
You can use the attached stored procedure. It can be created in any of your databases and then executed using CALL search('text to search').
You might want to try it on some test data, and then modify it to suit your needs.
Regards,
Janani
-
-
AuthorPosts
- You must be logged in to reply to this topic.