MYSQL Tutorial: Efficiently Importing Large CSV Files into MySQL with Python and Pandas

Поділитися
Вставка
  • Опубліковано 27 вер 2024

КОМЕНТАРІ • 19

  • @sandeepanand3834
    @sandeepanand3834 5 днів тому

    how to insert dataframe directly into mysql without manual pasting?

  • @jackrothschild3502
    @jackrothschild3502 11 місяців тому

    Thank you, but,what should I do if there is a large number of columns? Maybe hundreds

  • @ryuhayabusa3540
    @ryuhayabusa3540 Рік тому +2

    Thanks, what if you have millions of rows?

    • @AnalyticsExplorers
      @AnalyticsExplorers  Рік тому

      in your case, You can use the load data infile statement.
      This video method is also applicable, but you can perform it multiple times. For example, you can divide your rows into smaller parts and load each part separately into your database. Hope it helps.

  • @tholetivamsidharreddy6261
    @tholetivamsidharreddy6261 3 місяці тому

    Where the file will be stored

  • @pravinkhandale5158
    @pravinkhandale5158 8 місяців тому

    my program isn't run in sql

  • @VitorioRazzera
    @VitorioRazzera Рік тому

    Great content, thanks for sharing. It just helped me a lot here! 👍👍

  • @jongdave2691
    @jongdave2691 11 місяців тому +2

    This is really helpful, thank you. I wonder if the data has tons of "nan" value,such as Covid data, will still work?

    • @AnalyticsExplorers
      @AnalyticsExplorers  11 місяців тому +1

      Yes sure it still works.
      But, you must do something before importing. Check that data is cleaned as much as possible, you can do this on excel for example. Check that all nan cells contain empty string no spaces no characters are there.
      Best of luck!

  • @rajarajanr4353
    @rajarajanr4353 9 місяців тому

    @Data Analytics - Thanks for sharing it. I tried it and its working for first time and second time its throwing error "'tuple' object is not callable"
    Can you please help?

    • @AnalyticsExplorers
      @AnalyticsExplorers  9 місяців тому

      did you change anything in the code before you ran it again?

    • @rajarajanr4353
      @rajarajanr4353 9 місяців тому

      @@AnalyticsExplorers - i did not change anything. i have found another way to handle this issue and its working fine
      y = []
      for index, row in df1.iterrows():
      x = tuple(row)
      y.append(x)
      y

  • @yaaryvidanpeled8814
    @yaaryvidanpeled8814 8 місяців тому +1

    1.5 GB csv? Is this the way?

    • @AnalyticsExplorers
      @AnalyticsExplorers  8 місяців тому

      1.5 GB!! What a size!
      Your CSV file contains how many rows and columns?

    • @ahmarhussain8720
      @ahmarhussain8720 6 місяців тому

      @@AnalyticsExplorers I have a 50 gb csv

  • @tholetivamsidharreddy6261
    @tholetivamsidharreddy6261 3 місяці тому

    Where the file will be saved

  • @sanikasunil5440
    @sanikasunil5440 6 місяців тому

    bro i want to import csv file containing 60000 rows into wix but there is a limit of 50,000 rows so i am trying to upload it to mysql(external database option) how do i achieve this?

  • @mahimmittal7466
    @mahimmittal7466 Рік тому

    Seriously I tried everyday and Finally I was able to import my file. Thanks to this video!

  • @tholetivamsidharreddy6261
    @tholetivamsidharreddy6261 3 місяці тому

    Help me out where the txt file will be saved