Build a MYSQL Query and Optimise

Lukket Opslået 1 år siden Betalt ved levering
Lukket Betalt ved levering

The MySQL query below takes about 12-14 seconds to execute. Please examine the datatables and the query and share the following -

1. Optimized version of the query with average time taken

2. What do you think was wrong with the existing query ?

Note - please assume all the joins are mandatory in the given query

3. What were the main improvements done ?

Query :

select distinct name ad_type from dim_ad_type x

where exists

( select 1

from sum_adserver_dimensions sum

left join dim_ad_tag_map on dim_ad_tag_map.id=sum.ad_tag_map_id and dim_ad_tag_map.client_id=sum.client_id

left join dim_site on [login to view URL] = dim_ad_tag_map.site_id

left join dim_geo on [login to view URL] = sum.geo_id

left join dim_region on dim_region.id=dim_geo.region_id

left join dim_device_category on dim_device_category.id=sum.device_category_id

left join dim_ad_unit on dim_ad_unit.id=dim_ad_tag_map.ad_unit_id

left join dim_monetization_channel on dim_monetization_channel.id=dim_ad_tag_map.monetization_channel_id

left join dim_os on [login to view URL] = sum.os_id

left join dim_ad_type on [login to view URL] = dim_ad_tag_map.ad_type_id

left join dim_integration_type on [login to view URL] = dim_ad_tag_map.integration_type_id

where sum.client_id = 50 and dim_ad_type.id=[login to view URL] ) order by 1

Connection details -

hostname: 3.140.81.188:3306

Database: perftestcase

UserID & Password : dwh / cV6!lS9=sQ2^rY9~

MySQL Data Engineer Big Data Programmering af database Databaseudvikling

Projekt ID: #35129150

Om projektet

7 bud Remote projekt Aktiv 1 år siden

7 freelancere byder i gennemsnit ₹2186 timen for dette job

bhupen2606

Hello, i have checked your query and optimized. The modified query is producing same result with much less time. Please initiate chat with me so i can explain and share modified query. Thanks

₹1500 INR på 1 dag
(29 bedømmelser)
4.5
vincentgrerry

Hi there.. I'm personal freelancer and interesting with your project are offering and also already read your project description.. so hopefully could help you to optimize your query.. already try quick investigation Flere

₹2250 INR in 2 dage
(19 bedømmelser)
4.2
anjulipatel22

I have 7 plus years of experience with DataOps, BI and ETL development and testing. Experienced in analysis, design, Develop and Test in Data-warehousing using Cloud , different database like Oracle, Teradata etc and B Flere

₹1050 INR in 7 dage
(0 bedømmelser)
0.0
ashutosh21511

I will help you but given credentials are not working. please tell me how to connect. Then, i will solve your problem definitely.

₹1500 INR på 1 dag
(0 bedømmelser)
0.0
arunlin2001

I'm working Data Science Profession. And I have good Knowledge and hands on experience in SQL. I can able to help you on this work.

₹1000 INR in 7 dage
(0 bedømmelser)
0.0
arghaffary

I could be helpful in this field , first i must visit your project in order to give opinion and start my job please contact with me. I have strong knowledge in html, css, jquery, wordpress, responsive and can assure be Flere

₹3000 INR in 7 dage
(0 bedømmelser)
0.0