Connect Java with Mysql Database | Java JDBC | Java Database connectivity | JDBC MySql | ArjunCodes

Поделиться
HTML-код
  • Опубликовано: 10 июл 2021
  • how to connect Java application with MySQL database, inserts a row to a table and get all rows data from that table. We will add mysql-java-connector jar file in Intellij. We follow 5 steps while connecting Java application with any Database(Mysql) and getting data from database :
    1. Register the Driver class
    2. Create connection
    3. Create statement
    4. Execute queries
    5. Close connection
    Source Code JDBC : github.com/youtube-arjun-code...
    Install Intellij : • Install intellij in wi...
    ➡️ Support me
    PayPal : paypal.me/codewitharjun
    Patreon : / codewitharjun
    ➡️ Subscribe : / codewitharjun
    Stay Connected :
    ➡️ LinkedIn : / arjungautam1
    ➡️ Github : github.com/arjungautam1
    Join Community :
    ➡️Discord : / discord
    Follow me on :
    ➡️ Medium: / codewitharjun
    ➡️ Dev.to : dev.to/codewitharjun
    #java #javaprogramming #javatutorialforbeginner #mysqlconnectionjava #CodeWithArjun #Programming

Комментарии • 105

  • @mayurdighe
    @mayurdighe Год назад +22

    simple program is what I needed and you provided. Otherwise people keep explaining all other nonsense. Thanks man.

  • @dinguskhan56
    @dinguskhan56 Год назад +4

    i was missing the mysql connector jar file and thanks to you, now my project works fine.
    Thank you for sharing!

  • @barborasipova1332
    @barborasipova1332 10 месяцев назад +1

    Love this explanation ! Thank you so much

  • @_SurajYadav-lr9fl
    @_SurajYadav-lr9fl 9 месяцев назад +1

    thank you thank you so much bhai , i have been searching for such video for 2 weeks ,but I was getting error everywhere . but finally using this video I got setup my jdbc with my eclipse , now I can learn advance java , again thank you so much bro

  • @user-oc6tz6ri6d
    @user-oc6tz6ri6d 7 месяцев назад +1

    i was really having a hard time understanding this , thank u soooo much it was well explained

  • @user-ri5sv1um9q
    @user-ri5sv1um9q 5 месяцев назад +1

    Thnx for giving such a valuable information through a single program❤it really help me alot😊to leran.

  • @system.out.printlnsmartert5781
    @system.out.printlnsmartert5781 Год назад +2

    How did you call the sql string in the resultset? When I make the resultset I can only call the url, username, and password strings.

  • @deonvogg9616
    @deonvogg9616 2 года назад +11

    u are ze best java developer in ze world thanks indusian peaople risin loh

  • @meetslanki3538
    @meetslanki3538 10 месяцев назад +2

    i have seen a lot of videos and tried to connect with database and fetch the data from java but i did not get any output. i got bunch of error. however i saw your video and tried to connect with database. i succeed thus i thankful to you.

  • @user-dq5zm7qe7r
    @user-dq5zm7qe7r Год назад +5

    Thank you very much brother, I had been trying and trying for 5 hours without success but thanks to you I was finally able to do it, thank you very much I really appreciate it

  • @BoredTAK5000
    @BoredTAK5000 Год назад +1

    I was having so much trouble with the official sql connector thanks to this fix I should be able to fix it

  • @djdholan
    @djdholan 10 месяцев назад +3

    i sow around more than 20 videos on connectivity but your video help me really
    thanks from my heart❤‍🔥

  • @florrain1842
    @florrain1842 11 месяцев назад +1

    This was amazingly helpful,thanks a lot!!

  • @juliobell3470
    @juliobell3470 4 месяца назад +1

    💯Super useful. Thanks!

  • @niki_dee1524
    @niki_dee1524 2 года назад +2

    thx man, you help me, like u

  • @bhargavijethva7958
    @bhargavijethva7958 5 месяцев назад +1

    Very nice explanation⭐

  • @iftyl1525
    @iftyl1525 9 месяцев назад +1

    Thanks a lot brother.

  • @l.r.4006
    @l.r.4006 7 месяцев назад +1

    thank you very much, I needed to create a mysql application for a class and your tutorial was invaluable to me

  • @michaelsafwat1953
    @michaelsafwat1953 6 месяцев назад +1

    Thank you so much Brother

  • @newwoodmovies9228
    @newwoodmovies9228 11 дней назад +1

    thank you so much

  • @premar9937
    @premar9937 10 месяцев назад +1

    Thank you👍

  • @rashmikaabeyrathna9397
    @rashmikaabeyrathna9397 8 месяцев назад

    i'm ubuntu linux user. i use mysql from my terminal. i followd exact steps you showd except data base stuff. it works.

    • @rashmikaabeyrathna9397
      @rashmikaabeyrathna9397 8 месяцев назад

      i didn't start localhost manually. look like linux has take care about that by itself.

  • @vendara5173
    @vendara5173 Год назад

    Thanks you so much

  • @adeshyaduvanshi2482
    @adeshyaduvanshi2482 Год назад +1

    thank u so much....that was helpful❤

  • @raviajagiya9794
    @raviajagiya9794 Год назад +1

    Finally I done it thnx bro

  • @ImperialSolo
    @ImperialSolo 5 месяцев назад +1

    Thx Man!

  • @pitpot2
    @pitpot2 4 месяца назад +1

    youre the best

  • @ticket1159
    @ticket1159 7 месяцев назад

    so is it same result if i write these codes im netbeans?

  • @AlexeySuzdalenko
    @AlexeySuzdalenko 2 месяца назад

    fanks a lot, my friend !!!

  • @priyanshurai4817
    @priyanshurai4817 Месяц назад

    I also need to define SSC certificate while creating connection with db. Need help

  • @KarolKasperek
    @KarolKasperek Год назад

    oh my fucking od i was looking for some tutorial about java jdbc whole week. Thanks bro, cheer, love you so much

  • @l1keeN
    @l1keeN Год назад +2

    Very useful video. TY, indian bro!

  • @user-xm4sq3ee2q
    @user-xm4sq3ee2q 5 месяцев назад +1

    cool video)

  • @prajwalshetty2633
    @prajwalshetty2633 Год назад

    its raising ClassNotFoundException even after installing jconnect how do i solve it

  • @andreylion8140
    @andreylion8140 7 месяцев назад +1

    You are really cool, man. Thanks!

  • @user-kr9ry1in7o
    @user-kr9ry1in7o 7 месяцев назад +1

    thanks its soo 🤞🤞

  • @curiousnepal
    @curiousnepal 3 года назад +1

    Nice man !!!

    • @CodeWithArjun
      @CodeWithArjun  3 года назад

      Yo sab Magg Creation ko canva wala course ko kamaal ho.

  • @meendum_thamizh
    @meendum_thamizh 10 месяцев назад

    How to add the jar file path while coding in notepad

  • @bohdanakachmar6965
    @bohdanakachmar6965 Год назад +3

    Hey! You really helped me, so thank you so much!!

  • @eel546
    @eel546 Год назад +10

    can you please tell us how to make a local database and connect to it, so when i export the project to a .exe it still works??

    • @sen7826
      @sen7826 Год назад +1

      I am not sure if that can work, because this is supposed to be something that happens at the back end of a website. Exporting to exe is typically for a software application product that someone downloads from the internet.
      But I could be totally wrong.

  • @jaykumarpawar6591
    @jaykumarpawar6591 Год назад

    I have error occur in while loop system.out statement is ')' expected how i can solve this error

  • @youmna4045
    @youmna4045 День назад +1

    life saver

  • @yaswanthkadiri8870
    @yaswanthkadiri8870 Год назад

    But we cannot put this as a global gradle project . . which can have this database as a dependency so it will work in all systems. . .

  • @maxxi7629
    @maxxi7629 8 месяцев назад +1

    thanks! das krazayyyy

  • @ahappypotato9549
    @ahappypotato9549 Год назад +1

    thank you very much

  • @sandipgole1
    @sandipgole1 2 года назад +1

    Thanks man..

  • @lungelongobese212
    @lungelongobese212 2 месяца назад +1

    Amazing content fam🙏

  • @8bpnoobie832
    @8bpnoobie832 3 месяца назад

    how can i add the jar file in vs code?

  • @sjjjaiswal6521
    @sjjjaiswal6521 Год назад +1

    Very good information

  • @pratibhanevhare2757
    @pratibhanevhare2757 7 месяцев назад

    sir I face this issue while connectivity java.sql.SQLSyntaxErrorException: ORA-00942: table or view does not exist please solve this problem

  • @S-craY
    @S-craY Год назад +1

    Tnank you!!!

  • @user-bx6bj5vw8l
    @user-bx6bj5vw8l 3 месяца назад +1

    Thanks for this information

  • @TheOneAndOnlyyy
    @TheOneAndOnlyyy Год назад +1

    almost gave up on my project thanks bro

  • @trungdinh450
    @trungdinh450 3 года назад +1

    how to include jdbc in a spring project. Can u help me ?

    • @CodeWithArjun
      @CodeWithArjun  3 года назад +1

      I have already got video on that with title 'Connect Spring Boot with MySql arjuncodes'
      Goto my channel or just search this title on RUclips.
      If you again get problem messsage me on facebook.

  • @omniamahmoud6604
    @omniamahmoud6604 3 месяца назад

    I don't have project structure on my IDE, I work on eclipse

  • @infinitespace1982
    @infinitespace1982 4 месяца назад

    I get communications link failure, any idea why?

  • @Rob-J-BJJ
    @Rob-J-BJJ 7 месяцев назад

    sir you didn't even go over what is xampp or how to use it , that would be something good to know, maybe list it in the description or something at least

  • @user-jd7yh1nu2p
    @user-jd7yh1nu2p 17 дней назад +1

    thanks man

  • @ahamedhamthan6992
    @ahamedhamthan6992 Год назад +1

    so much usefull. thanks a lot

  • @xtwist3779
    @xtwist3779 2 года назад +1

    good job

  • @maxxi7629
    @maxxi7629 8 месяцев назад +1

    i love yo

  • @nirajkc224
    @nirajkc224 Год назад +1

    thanks.

  • @daniilkobzar4869
    @daniilkobzar4869 Год назад

    But it not secure to store password in plain text in your code. How can you make it work other way?

    • @sen7826
      @sen7826 Год назад

      You could ask for the password as a user input before anything else in the program

  • @diptipatil6200
    @diptipatil6200 2 года назад +1

    How to include jar file in classpath

    • @CodeWithArjun
      @CodeWithArjun  2 года назад +1

      I have got video on that. Check out on my channel.

    • @diptipatil6200
      @diptipatil6200 2 года назад

      @@CodeWithArjun yes sure

  • @user-bu8mg7uq3s
    @user-bu8mg7uq3s Год назад +1

    thank you

  • @sandy6T9
    @sandy6T9 Год назад +1

    bro are you nepali ?

  • @CopyCoderX
    @CopyCoderX 6 месяцев назад +1

    i know you are nepali, arent you ??

  • @vitz8572
    @vitz8572 11 месяцев назад +8

    Content is fine but accent is very difficult to bear

    • @danvelc9912
      @danvelc9912 8 месяцев назад +5

      Just bear with it

    • @Nxtfbrdf
      @Nxtfbrdf 8 месяцев назад +7

      Bro İt's clear
      English is not even my first language and İ manage to understand them while speaking
      Don't make a big deal of the accent

    • @ElectrostatiCrow
      @ElectrostatiCrow Месяц назад

      That's the price to pay for learning how to code.😂

  • @user-dp8kk3ju8k
    @user-dp8kk3ju8k 4 месяца назад +1

    cool video)