https://www.linkedin.com/posts/data-dawn_your-analyses-is-useless-if-your-data-is-activity-7375890512094040064-p0Ud?utm_source=social_share_video_v2&utm_medium=android_app&rcm=ACoAAAMyhrcBZfCbyRqksrH2wYOCdYxljJ2vRuI&utm_campaign=copy_link
https://www.linkedin.com/posts/data-dawn_your-analyses-is-useless-if-your-data-is-activity-7375890512094040064-p0Ud?utm_source=social_share_video_v2&utm_medium=android_app&rcm=ACoAAAMyhrcBZfCbyRqksrH2wYOCdYxljJ2vRuI&utm_campaign=copy_link
WWW.LINKEDIN.COM
Your analyses is useless. If your data is a mess. 8 steps to clean data in SQL 👇 đ—Ļ𝘁𝗲đ—Ŋ đŸŦ: 𝗨đ—ģ𝗱𝗲đ—ŋ𝘀𝘁𝗮đ—ģ𝗱 𝗱𝗮𝘁𝗮 𝘀𝘁đ—ŋ𝘂𝗰𝘁𝘂đ—ŋ𝗲 â†ŗ Understand column names and types â†ŗ Check out a… | Dawn Choo | 64 comments
Your analyses is useless. If your data is a mess. 8 steps to clean data in SQL 👇 đ—Ļ𝘁𝗲đ—Ŋ đŸŦ: 𝗨đ—ģ𝗱𝗲đ—ŋ𝘀𝘁𝗮đ—ģ𝗱 𝗱𝗮𝘁𝗮 𝘀𝘁đ—ŋ𝘂𝗰𝘁𝘂đ—ŋ𝗲 â†ŗ Understand column names and types â†ŗ Check out a sample of the data đ—Ļ𝘁𝗲đ—Ŋ 𝟭: 𝗘𝘅đ—Ŋ𝗹đ—ŧđ—ŋ𝗲 𝘁đ—ĩ𝗲 𝗱𝗮𝘁𝗮 â†ŗ For numerical columns, check distributions â†ŗ For categorical variables, check frequencies đ—Ļ𝘁𝗲đ—Ŋ 𝟮: đ—Ļ𝘁𝗮đ—ģ𝗱𝗮đ—ŋ𝗱đ—ļ𝘇𝗲 𝗱𝗮𝘁𝗮 đ—ŗđ—ŧđ—ŋđ—ē𝗮𝘁𝘀 â†ŗ Convert strings to lower case or upper case â†ŗ Cast dates to readable format â†ŗ Remove white spaces đ—Ļ𝘁𝗲đ—Ŋ đŸ¯: đ—Ĩ𝗲đ—ēđ—ŧ𝘃𝗲 𝗱𝘂đ—Ŋ𝗹đ—ļ𝗰𝗮𝘁𝗲𝘀 â†ŗ Use DISTINCT to remove duplicate rows đ—Ļ𝘁𝗲đ—Ŋ 𝟰: 𝗙đ—ļ𝗹𝗹 đ—ļđ—ģ đ—ģ𝘂𝗹𝗹𝘀 𝗮đ—ģ𝗱 đ—ēđ—ļ𝘀𝘀đ—ļđ—ģ𝗴 𝘃𝗮𝗹𝘂𝗲𝘀 â†ŗ Fill with 0 (only when 0 is a meaningful default) â†ŗ Drop the data, if missing data makes the row unusable â†ŗ Fill with the average (for numerical data only) đ—Ļ𝘁𝗲đ—Ŋ 𝟱:  đ—Ļ𝘁𝗮đ—ģ𝗱𝗮đ—ŋ𝗱đ—ļ𝘇𝗲 𝗰𝗮𝘁𝗲𝗴đ—ŧđ—ŋđ—ļ𝗰𝗮𝗹 𝘃𝗮đ—ŋđ—ļđ—Žđ—¯đ—šđ—˛đ˜€ â†ŗ Use CASE WHEN to clean the data đ—Ļ𝘁𝗲đ—Ŋ 𝟲: 𝗙đ—ļ𝗹𝘁𝗲đ—ŋ đ—ŧ𝘂𝘁 đ—¯đ—Žđ—ą 𝗱𝗮𝘁𝗮 â†ŗ Use WHERE to filter out unusable rows đ—Ļ𝘁𝗲đ—Ŋ đŸŗ: đ—Ĩ𝗲đ—ģ𝗮đ—ē𝗲 𝗰đ—ŧ𝗹𝘂đ—ēđ—ģ𝘀 đ—ŗđ—ŧđ—ŋ 𝗰𝗹𝗮đ—ŋđ—ļ𝘁𝘆 â†ŗ Use intuitive and clear column names đ—Ļ𝘁𝗲đ—Ŋ 𝟴: 𝗖đ—ŋ𝗲𝗮𝘁𝗲 đ—ŋđ—˛đ˜‚đ˜€đ—Žđ—¯đ—šđ—˛ 𝘃đ—ļ𝗲𝘄𝘀 đ—ŧđ—ŋ đ˜đ—Žđ—¯đ—šđ—˛đ˜€ â†ŗ Create a view (doesn't take up more storage) â†ŗ Save as a table (faster for querying) ——— Ready to test your SQL skills? Check out these questions on Interview Master: 🙂 Easy SQL question: https://lnkd.in/gG_A8FWP 😉 Medium SQL question: https://lnkd.in/geQqR_uV 😄 Hard SQL question: https://lnkd.in/gRrNfcuK ——— â™ģī¸ Found this useful? Repost it please! | 64 comments on LinkedIn
0 Reacties 0 aandelen