Java And MySQL - How To Insert Update Delete And Display Data In jTable [Part-1] [With Source Code]

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

КОМЕНТАРІ • 138

  • @ahmedraza2540
    @ahmedraza2540 7 років тому +2

    finally i successfully insert delete update data into mysql and retrive it into jtable
    with the help of this useful code
    thank u sir

    • @RunCodes
      @RunCodes  7 років тому

      you always welcome!

  • @braindeadtv8360
    @braindeadtv8360 4 роки тому +3

    You're a master of machine prayers! Bless of Omnissia and Emperor upon you!

  • @vipulsonimusic2583
    @vipulsonimusic2583 5 років тому +3

    sir i am not able to do db but after this vdo easily did it thank you sirrrrrrrrrrrr

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

    i am a software engineer very important video for my projects

  • @jherky6680
    @jherky6680 3 роки тому

    You have allowed me to pass my coursework good sir

    • @RunCodes
      @RunCodes  3 роки тому

      We are pleased that it helps you 😊

  • @latifaesmaty9626
    @latifaesmaty9626 2 роки тому

    Thank you for this video. The functions of my project is workin thank you sirrrrrrrrrrrrrrrrrrrr

  • @petersang1460
    @petersang1460 3 роки тому

    Your explanation is so simple 🔥🔥

  • @kymaniwilson8363
    @kymaniwilson8363 3 роки тому

    Wish to see more videos like these in the future. Well done brother! You just got another subscriber and a like

  • @jomarclado9176
    @jomarclado9176 7 років тому +1

    Thank you for this video. The functions of my project is working

  • @Anurag-hc3wb
    @Anurag-hc3wb 4 роки тому

    Thanks for completing my project ❤️❤️❤️❤️

    • @saidfpv
      @saidfpv 3 роки тому

      can i contact you please ?

  • @ybundhunify
    @ybundhunify 2 роки тому

    You are a Lifesaver

  • @sammmyranaway
    @sammmyranaway 7 років тому +3

    you saved my project bro thanks a ton!

  • @vivekkumarsharma6451
    @vivekkumarsharma6451 3 роки тому

    Thank you so much respected Sir , i am very thankful to you, before watching your video I had this error " java.sql.SQLException: Could not retrieve transation read-only status server " but after watching your video it worked .. thanks a ton..

  • @kenaesthetic4565
    @kenaesthetic4565 3 роки тому

    Do you have a video like this sir but it not required to use mysql? Like making Jtable directly without importing mysql

  • @sal3202
    @sal3202 6 років тому

    YOU SAVE MY FINAL APRESENTATION A.K.A PAP

  • @EvulaniorePH
    @EvulaniorePH 3 роки тому

    Thank u so much Sir

  • @muhammadhifzhansyahmi652
    @muhammadhifzhansyahmi652 3 роки тому

    sir, if I use jdatechooser then how should i write it to add the date in add button?
    is it pst.setDate (2, Payment_Date.getDate()); ?

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

    error occured at pst = con.prepareStatement(sql);

  • @saidfpv
    @saidfpv 3 роки тому

    did you use the object oriented design ?

    • @RunCodes
      @RunCodes  3 роки тому

      NOPE!

    • @saidfpv
      @saidfpv 3 роки тому

      in the new version of eclipse i cant drag and drop a button , it sets me like north center west.....

    • @saidfpv
      @saidfpv 3 роки тому

      whats the solution to drag and drop freely

    • @RunCodes
      @RunCodes  3 роки тому

      you can, use netbeans IDE!

    • @saidfpv
      @saidfpv 3 роки тому

      @@RunCodes is there any video using object oriened design ??

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

    is there is code for update or not??

  • @TheRealAnkitSharma
    @TheRealAnkitSharma 2 роки тому

    Hi,
    Great work clearing the concept. Can you tell how to create n number of duplicate row in jtable and insert those newly duplicated/copies to the dabatabase, with different primary key. And one more thing, how to edit a particular column in the jtable for those copies/duplicate rows data.

  • @flurple6921
    @flurple6921 3 роки тому

    im getting an error at the "DriverManager.getConnection" part, the DriverManager is highlighted red

    • @RunCodes
      @RunCodes  3 роки тому

      Click alt+enter to add the library!

  • @djosmauritius
    @djosmauritius 4 роки тому

    hi I'm getting this message when trying to run the project, could you help on this please?
    "Unable to connect to the MySQL server:
    org.netbeans.api.db.explorer.DatabaseException: org.netbeans.api.db.explorer.DatabaseException: java.sql.SQLException: The server time zone value 'unknown' is unrecognized or represents more than one time zone. You must configure either the server or JDBC driver (via the serverTimezone configuration property) to use a more specifc time zone value if you want to utilize time zone support..
    The server may not be running or your MySQL connection properties may not be set correctly. Do you want to edit your MySQL connection properties?"

    • @RunCodes
      @RunCodes  4 роки тому

      update your computer time!

  • @jemaimaabdulmajeed5022
    @jemaimaabdulmajeed5022 6 років тому

    YOU MAN YOU ARE THE BESSSSSTTTTTTTTTT
    THANK YOOOOOOUUUUUUUUUUUUUU

  • @SangTran-ef1hm
    @SangTran-ef1hm 6 років тому

    if I dont use rs2xml.jar, how could I do button view? to show database in jtable
    sr my bad English

    • @RunCodes
      @RunCodes  6 років тому

      I have to idea about it!

  • @gagandeepkaur3098
    @gagandeepkaur3098 3 роки тому

    Hey...i have only 4 parameters but it is showing that doesnt give value for 5th parameter while updating process...pls help

    • @RunCodes
      @RunCodes  3 роки тому

      Have a look at your query, may be you forget commas, parentheses

  • @sgalvis_
    @sgalvis_ 5 років тому

    Thanks! nice tutorial

  • @eiffelcarlllagas5271
    @eiffelcarlllagas5271 7 років тому

    i have a problem about the sql queries where can i find INSERT queries in Phpmy admin database i can't find there please reply

    • @RunCodes
      @RunCodes  7 років тому

      you can write the insert by yourself it's very simple INSERT INTO table_name VALUES() inside the parenthesis you can pass the value. But if you don't like to write the code by yourself and want to copy from phpmyadmin then go to database then expand your database go to the table and from there you will see the SQL tab and click on that tab after clicking that tab you will see various tabs like SELECT UPDATE INSERT etc. you click on that tab and there may appear the SQL Query for the particular operation as you select the tab then copy that code and edit by yourself just watching this video.

  • @latifaesmaty9626
    @latifaesmaty9626 2 роки тому

    I am wait for mor

  • @manishtambe8078
    @manishtambe8078 4 роки тому

    Sir please help what to do if user enter same rollno and same name how to validate the data and how to show it that the duplicate data found

    • @RunCodes
      @RunCodes  4 роки тому

      Use primary key for rollno in database so that the rollno will not be same!

  • @santirpothe
    @santirpothe 6 років тому

    thnx for giving the nice tutorial

  • @Fajiwaji
    @Fajiwaji 6 років тому

    Sir can you help me this?
    java.sql.SQLExcepton:Field'ID'Doesn't Have a default value

    • @RunCodes
      @RunCodes  6 років тому

      U don't have ID as primary key thats why u get such error make ID as primary key in your database

  • @therealog671
    @therealog671 5 років тому

    hello where is that video for downloading a connector

    • @RunCodes
      @RunCodes  5 років тому

      See description section of video!

  • @towhidurrahman9885
    @towhidurrahman9885 7 років тому

    If i want to insert String and int data both what need to be write in "" try{
    String sql = "INSERT INTO add_clips"
    +"(Cname, Cduration, Ctype, Cadd,Cgenre)"
    +"VALUES (?,?,?,?,?,?,?)"; """ ??
    please answer

    • @RunCodes
      @RunCodes  7 років тому

      for int you can use pst.setInt

  • @ahmed-programming-world
    @ahmed-programming-world 6 років тому

    i have this error" java.sql.SQLException: Can not issue data manipulation statements with executeQuery()"

    • @RunCodes
      @RunCodes  6 років тому

      Contact us at facebook.com/TechSupportNep

  • @vinzlorenz5041
    @vinzlorenz5041 7 років тому

    i have a problem on 12:17 line 165. what is jdbc? what are the things that you entered i dont understand bro can you help me?

    • @RunCodes
      @RunCodes  7 років тому

      this is called the connection string:) we need to connect our program with the database before performing the database operation from our program on that database so for this task we need to register JDBC Driver in our program. I am using MySQL database so i need to get connection with the MySQL (watch this video for this ua-cam.com/video/yVeJy05D8ls/v-deo.html which shows how to connect your program with the MySQL DB) and the line 165 is to connect my database with my program and if you want to connect your SQL Server with your application you need to write different connection string (watch this video for this ua-cam.com/video/85VE_kubnsI/v-deo.html). jdbc means java database connectivity. jdbc:mysql://localhost/idusjavanew","root",""); The jdbc:mysql is the default connection string to connect MySQL db, jdbc:mysql://Your_Server_Name/Your_Database_Name","Database_Application_Username","Database_Application_Password");

  • @ahmedraza2540
    @ahmedraza2540 7 років тому

    when i used this code to insert data into mysql using this code it shows this error
    "com.mysql.jdbc.exceptions.jdbc4.MYSQLSyntexErrorException; You have error in your sql syntex. chk the manual that corresponds to your mysql server version for the right syntex to use near'add)VALUES('ahmed','raza','londen')'at line 1
    can to tell me your mysql version?

    • @RunCodes
      @RunCodes  7 років тому

      first download "mysql-connector-java-5.1.40-bin" from www.mysql.com. if
      you don't know how to download and add this jar file watch
      ua-cam.com/video/yVeJy05D8ls/v-deo.html this video first then you will understand.
      and then check your insert query.

  • @TechProgrammingIdeas
    @TechProgrammingIdeas 4 роки тому

    Thanks

  • @swananddongare3795
    @swananddongare3795 4 роки тому

    getting error at setString method the error is can not find symbol

    • @RunCodes
      @RunCodes  4 роки тому

      import it first. import java.sql.PreparedStatement;

    • @TechProgrammingIdeas
      @TechProgrammingIdeas 4 роки тому

      Import all needed libraries
      Welcome to my channel

  • @aditibattulwar6095
    @aditibattulwar6095 7 років тому

    com.mysql.jdbc.exceptions.jdbc4.mysqlsyntaxerrorexception: table doesn't exist.
    What to do in this situation?

    • @RunCodes
      @RunCodes  7 років тому

      +Aditi Battulwar enter your table name that you have created in your database! For more contact us at facebook.com/TechSupportNep

  • @ahmedraza2540
    @ahmedraza2540 7 років тому

    what about this?
    java.sql.SQLException: Parameter index out of rang(1> number of parameters which is 0.

    • @stephenc.nwankwo6284
      @stephenc.nwankwo6284 6 років тому

      Bro were you able to sort that out? I am having exactly the same problem

  • @raihanurrahman503
    @raihanurrahman503 5 років тому

    Im getting erros for my "pst.setString()" codelines can anyone plese help me?

    • @ieyqa
      @ieyqa 5 років тому

      did u find the solutions ? bcus i dont get it. please help me .

    • @RunCodes
      @RunCodes  5 років тому

      Contact us at facebook.com/TechSupportNep

    • @jeffbaldovino7664
      @jeffbaldovino7664 4 роки тому

      Pls answer this. I'm having a problem also in this line:(

    • @asifmahmud7025
      @asifmahmud7025 3 роки тому

      @@jeffbaldovino7664 i face also same problem pst.setString(1,fname.getText()); this line fname does not work did u find solution?

  • @angelamorgado3226
    @angelamorgado3226 5 років тому

    In 20:23 pls help where I could find that in the libraries pls..

  • @lanub6656
    @lanub6656 5 років тому

    Really great! Unfortunatley when I run the it shows "java.lang.UnsupportedOperationException: Not supported yet. Please help Sir

    • @RunCodes
      @RunCodes  5 років тому

      Contact us at facebook.com/TechSupportNep

    • @EvansFianoo
      @EvansFianoo 3 роки тому

      Import MySQL and jar file in the package. By adding it to a library

  • @billyl.andrade5522
    @billyl.andrade5522 2 роки тому

    wow, thankyouu, give source code please

  • @ahmedraza2540
    @ahmedraza2540 7 років тому

    how to solve syntex error problm of sql version?

    • @RunCodes
      @RunCodes  7 років тому

      what type of problem do you face?

  • @ahmedraza2540
    @ahmedraza2540 7 років тому

    can you guide how to use search bar in this panel

    • @RunCodes
      @RunCodes  7 років тому

      i will make video on that stay connected!

    • @ahmedraza2540
      @ahmedraza2540 7 років тому

      okay thanks

  • @sagarchandrachanda7989
    @sagarchandrachanda7989 7 років тому

    how i insert data for jcombobox please reply

    • @RunCodes
      @RunCodes  7 років тому

      +SAGAR BANIK here is the video tutorial 😊 watch this video ua-cam.com/video/z-hyQizHrs0/v-deo.html

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

    Source code or not given

  • @ahmedraza2540
    @ahmedraza2540 7 років тому

    I want to generate bill using these tools, can you help me? plzzzzz

    • @RunCodes
      @RunCodes  7 років тому

      +Ahmed Raza use simple arithmetic operator bro. you can do it by yourself.

    • @ahmedraza2540
      @ahmedraza2540 7 років тому

      okay im trying thanx

    • @stephenc.nwankwo6284
      @stephenc.nwankwo6284 6 років тому

      Ahmed pls I don't have clue on how to solve this Arithematic

    • @stephenc.nwankwo6284
      @stephenc.nwankwo6284 6 років тому

      The Error stopped on it's own without reason why. Now My DbUtils is giving big probs

  • @ahmedraza2540
    @ahmedraza2540 7 років тому

    how to chk parameter index of our textfield?

    • @RunCodes
      @RunCodes  7 років тому

      you can check parameter index from your mysql database. the first column have the parameter index 0 second column will be 1 and so on

    • @ahmedraza2540
      @ahmedraza2540 7 років тому

      thanx

    • @RunCodes
      @RunCodes  7 років тому

      done?

    • @ahmedraza2540
      @ahmedraza2540 7 років тому +1

      yop done. now im updating there is still a problem

  • @swirlandtwirl5417
    @swirlandtwirl5417 4 роки тому

    Hey, thanks.

  • @Zeus-hb2cn
    @Zeus-hb2cn 7 років тому

    Help! I keep getting java.lang.NullPointerException in my program, I can't add a data.

    • @RunCodes
      @RunCodes  7 років тому

      +Zeus Palisoc you may not add the jar file! Contact us at facebook.com/TechSupportNep

    • @pratikshagaikwad9030
      @pratikshagaikwad9030 4 роки тому

      @@RunCodes what is the solution?

    • @RunCodes
      @RunCodes  4 роки тому

      For which error?

    • @pratikshagaikwad9030
      @pratikshagaikwad9030 4 роки тому

      @@RunCodes java. Lang. Null pointer exception

  • @eiffelcarlllagas2061
    @eiffelcarlllagas2061 7 років тому

    Where i can download mysql connection

    • @RunCodes
      @RunCodes  7 років тому

      Check the description section! There is link!

  • @hamzik2255
    @hamzik2255 6 років тому

    BRO AM NOT USING PHPADMIN DATABASE ITS MYSQL MANAGMENT STODIO AND THERE IS NO ROOT SO HOW I CONNECT TO MYSQL .. PLEASE HELP

    • @RunCodes
      @RunCodes  6 років тому

      mysql or sql??

    • @hamzik2255
      @hamzik2255 6 років тому

      TechSupportNep microsoft sql server 2014

    • @RunCodes
      @RunCodes  6 років тому

      Watch this video you will understand ua-cam.com/video/85VE_kubnsI/v-deo.html

  • @andythomson2227
    @andythomson2227 4 роки тому

    tnxxxxxx💓💓💓💓

  • @RunCodes
    @RunCodes  3 роки тому +1

    do you like our work?
    does this tutorial help you?
    if so, you can support us at www.patreon.com/RunCodes

  • @yvonneventura1063
    @yvonneventura1063 6 років тому

    Can I use xampp

  • @ahmedraza2540
    @ahmedraza2540 7 років тому

    i need help in populate jtable but your video is not clear. plzz make it clear

    • @RunCodes
      @RunCodes  7 років тому

      watch part 2 you will able to populate jtable.

    • @ahmedraza2540
      @ahmedraza2540 7 років тому

      but data is not clear.

    • @RunCodes
      @RunCodes  7 років тому

      watch part 2 in 720p (i.e HD) and use earphone you will understand each
      and everything. if you listen i the loudspeaker i.e. laptop or desktop
      default sound without using the speaker sound may not be clear.

  • @aditibattulwar6095
    @aditibattulwar6095 7 років тому

    Am having prblm in update method....

    • @RunCodes
      @RunCodes  7 років тому

      +Aditi Battulwar contacts us at facebook.com/TechSupportNep

  • @kyahnarciso6568
    @kyahnarciso6568 4 роки тому

    I got error on jdbc:mysql:

    • @RunCodes
      @RunCodes  4 роки тому

      Watch video carefully

  • @gyanapriyapradhan6289
    @gyanapriyapradhan6289 2 роки тому

    Odia hai kya

  • @krishnamanuaba7365
    @krishnamanuaba7365 6 років тому

    i dont know why but i get so many error on line 167 and after

    • @RunCodes
      @RunCodes  6 років тому

      +Krishna Manuaba what is your error??

  • @redaba5979
    @redaba5979 4 роки тому

    hi . can'i have a source code pls !

  • @eymme5571
    @eymme5571 3 роки тому

    Scam at 8:36 It didnt show me the list

    • @RunCodes
      @RunCodes  3 роки тому

      🤔 watch the full tutorial first! We still have to write code!

    • @eymme5571
      @eymme5571 3 роки тому

      @@RunCodes My only problem is how to make a search bar