Excel VBA Introduction Part 58.22 - SQL for Excel Files - Join Worksheets from Multiple Files

แชร์
ฝัง
  • เผยแพร่เมื่อ 2 ม.ค. 2025

ความคิดเห็น • 32

  • @youssefsedkey7616
    @youssefsedkey7616 3 ปีที่แล้ว +2

    I never get bored no matter how much I watch your tutorials.

    • @WiseOwlTutorials
      @WiseOwlTutorials  3 ปีที่แล้ว

      Thank you Youssef, I will try even harder to be boring in the next video 😀

    • @youssefsedkey7616
      @youssefsedkey7616 3 ปีที่แล้ว +1

      @@WiseOwlTutorials I don't think so Andy, and you will never exceed my expectations😄😄

  • @frikduplessis8849
    @frikduplessis8849 3 ปีที่แล้ว +1

    Andrew just when I thought I saw everything you dropped this one, I like the SQLquery = SQLquery ....👌
    Thank you very much for all the time and effort you are putting in the help the community its highly appreciated 👍

    • @WiseOwlTutorials
      @WiseOwlTutorials  3 ปีที่แล้ว +1

      Thank you as always Frik, glad you enjoyed it!

  • @KhalilYasser
    @KhalilYasser 3 ปีที่แล้ว +1

    Awesome as usual. You are an incredibly awesome tutor.

  • @VincentHardwick
    @VincentHardwick 3 ปีที่แล้ว +1

    That's dedication right there... still making videos on a Saturday evening just before England play in a knockout match 💪👏

    • @WiseOwlTutorials
      @WiseOwlTutorials  3 ปีที่แล้ว

      It's even worse than that Vince! I spent so much time editing that one and planning the next video that I didn't even see the match!

    • @VincentHardwick
      @VincentHardwick 3 ปีที่แล้ว

      Ooof, you missed a corker of a game. I could threaten to unsubscribe if you don't give yourself the night off on Wed for the semi-final... but we both know that neither of those things is gonna happen! 😂🙄

    • @WiseOwlTutorials
      @WiseOwlTutorials  3 ปีที่แล้ว

      @@VincentHardwick I think you're probably right 😂

  • @padmapriyap579
    @padmapriyap579 ปีที่แล้ว

    Is there a way to create a temp table in this connection?

  • @shinrafahell
    @shinrafahell 3 ปีที่แล้ว

    Hi there, Is it possible to perform different actions such as update or insert in multiple files at the same time?

    • @WiseOwlTutorials
      @WiseOwlTutorials  3 ปีที่แล้ว +1

      Hi Rafael! As far as I know, you need a separate Insert or Update statement for each table that you want to modify.

    • @shinrafahell
      @shinrafahell 3 ปีที่แล้ว +1

      @@WiseOwlTutorials thanks Andrew!

    • @WiseOwlTutorials
      @WiseOwlTutorials  3 ปีที่แล้ว

      @@shinrafahell No problem Rafael!

  • @sikhosikhaobyyogesh8070
    @sikhosikhaobyyogesh8070 2 ปีที่แล้ว

    Sir, How to handle more than million records in CSV file ?
    Please share the link of video if you created on this topic.

    • @WiseOwlTutorials
      @WiseOwlTutorials  2 ปีที่แล้ว +1

      Hi Yogesh, sorry we don't have a video on that topic.

    • @sikhosikhaobyyogesh8070
      @sikhosikhaobyyogesh8070 2 ปีที่แล้ว

      @@WiseOwlTutorials ok thanks..
      Can you please confirm how to how to access csv file through connection string ?

    • @WiseOwlTutorials
      @WiseOwlTutorials  2 ปีที่แล้ว

      @@sikhosikhaobyyogesh8070 Hi Yogesh! Yes, we have videos on how to do this, you can search for videos from the channel homepage. Here's one of the videos you might find helpful th-cam.com/video/V7SslIs7HAI/w-d-xo.html

    • @sikhosikhaobyyogesh8070
      @sikhosikhaobyyogesh8070 2 ปีที่แล้ว +1

      @@WiseOwlTutorials Yes sir I already searched and got it.. You are amazing..I m grateful to you 🙏.

  • @Munichandra_Reddy
    @Munichandra_Reddy 3 ปีที่แล้ว

    Hi sir ,
    I haven't found any social media platforms for you (face book & Instagram & twitter)
    Because of you , lots of peoples and me learnt so many things
    "Your my VBA god"
    Note: I have question ; where did you get the information?
    Try to explain more videos on power bi.

    • @WiseOwlTutorials
      @WiseOwlTutorials  3 ปีที่แล้ว

      Hi! We're on Twitter and Facebook @wiseowltraining
      We'll have more Power BI videos on this channel and our new Wise Owl Shorts channel which you might find useful th-cam.com/channels/K33VBvvtsKbuSMT_aCyRzA.html
      I hope it helps!

  • @mohammedtommis3147
    @mohammedtommis3147 3 ปีที่แล้ว +1

    thaaaaaaaaaank youuuuuuuuuuuu

  • @kartickchakraborty9135
    @kartickchakraborty9135 3 ปีที่แล้ว

    Hi Sir, How are you? Sir, for couple of days, I've a problem to merge Data from different files. I want to say, - suppose you have 3 clients or 3 folders. "Client A", "Client B" and "Client C". Under each folder or client, there are multiple files. Let's say, "Client A" folder contains 5, "Client B" folder contains 10 and "Client C" folder contains 15 files. The main problem is, the spelling and the sequence of the Headers are same in all the files in the same folder but not in the others.
    Let's say for an example, "Client A" folder consists of 5 files which are of same headers like (Emp ID, Emp Name, Age, Ph, State, Sales). Likewise, "Client B" folder has 10 files, which also have the same heading like (Name, ID, Phone, Age, State, Revenue, Zip Code), but not exactly same as "Client A". In the same manner, "Client C" has 15 Files having same headers like (Zip Code, State, Zone, E-Name, E-ID, Sales, Contact No., Age) but not same as headers in "Client A" and "Client B" Folders.
    In this situation, how can I combine the whole data and make a pivot on it? I kindly request you to please make a video on this topic Sir.

    • @WiseOwlTutorials
      @WiseOwlTutorials  3 ปีที่แล้ว

      Hi Kartick, you can map columns with different names by selecting them in the correct order in a Union query. The basic pattern of the code would look like this:
      SELECT [Emp ID], [Emp Name], [Age]
      FROM [Client A]
      UNION ALL
      SELECT [ID], [Name], [Age]
      FROM [Client B]
      UNION ALL
      SELECT [E-ID], [E-Name], [Age]
      FROM [Client C]
      You may find this video which describes how to union data from different files useful th-cam.com/video/dfg34caoI_U/w-d-xo.html

    • @kartickchakraborty9135
      @kartickchakraborty9135 3 ปีที่แล้ว +1

      @@WiseOwlTutorials Thank you so much Sir. I always hold you in high regard. Serving Humanity without any interest is the most sacred way to attain God. This is the only reason, I admire you so much. My Father used to say, to become successful in life, everyone must have a Guru Dev in his life, who will guide him properly. I've learnt a lot of things from you. Throughout these years, you guided me very well. Whatever I am today, just for your blessings. You and I may be in different country, may be our cultures and religions are different. But, irrespective of all that, You are the most precious one in my life. In the path of life, if you face any trouble, please don't hesitate to tell me. I'll always be there with you. This is my facebook profile link - facebook.com/kishor025. If you think me that I deserve to be your student, please share your Facebook link ID. I'll be looking forward to your reply. Please accept my greetings.

    • @WiseOwlTutorials
      @WiseOwlTutorials  3 ปีที่แล้ว

      @@kartickchakraborty9135 Thank you so much Kartick, it's so nice to know that I've helped you with these videos and thank you for taking the time to write such a lovely message.
      I have accepted your LinkedIn invitation, it's a pleasure to connect with you.

  • @grzegorz2852
    @grzegorz2852 2 ปีที่แล้ว

    Hello, i have a question. how to take the worksheet name from a closed worksheet by using ado: I mean that instead of using INNER JOIN (SELECT * FROM [Genres2011$] " & _
    "IN '" & ThisWorkbook.Path & "\Movies2011.xlsx' 'Excel 12.0 Xml;')" -> i would like to use Worksheets(1).Name. I tried INNER JOIN (SELECT * FROM ['" & Worksheets(1).Name & "'$] " & _
    "IN '" & ThisWorkbook.Path & "\Movies2011.xlsx' 'Excel 12.0 Xml;')" but it didn't work

    • @WiseOwlTutorials
      @WiseOwlTutorials  2 ปีที่แล้ว

      Hi Grzegorz! Sadly that won't work - you can't reference the Worksheets collection of a Workbook object unless it's open. You can loop through the sheets in a closed workbook by querying the schema of the file as shown in this video th-cam.com/video/5F8q7Z9kWGw/w-d-xo.html I hope it helps!