JDBC

JDBC Tutorial

In this tutorial, you learn how to connect to a MySQL database using Java JDBC.

The tutorial starts with an overview of the JDBC API. Then you learn how to set up your development environment with the appropriate MySQL database drivers. Next the tutorial shows you how to submit a SQL query and process the result set. Also, you learn how to perform SQL insert, updates and deletes.

The tutorial moves on to advanced topics such as Prepared Statements to handle SQL paramaters. You also learn how to call stored procedures using various parameter types (IN, INOUT, OUT and ResultSet). Next, the tutorial shows you how to process large data types such as BLOBs and CLOBs. Finally, the tutorial wraps up with a section on reading database connection information from a configuration file.

# Video
0 JDBC Overview
1 Submitting SQL Queries
2 Inserting Data into the Database
3 Updating Data in the Database
4 Deleting Data from the Database
5 Creating Prepared Statements
6 Calling Stored Procedures - Part 1- IN Parameters
7 Calling Stored Procedures - Part 2- INOUT Parameters
8 Calling Stored Procedures - Part 3- OUT Parameters
9 Calling Stored Procedures - Part 4- Result Set
10 Defining JDBC Transactions
11 Accessing Database MetaData
12 Reading ResultSet MetaData
13 Reading and Writing BLOBs
14 Reading and Writing CLOBs
15 Reading Database Connection Info from Properties File
16 Connect Java Swing GUI to a MySQL Database - #0
17 Connect Java Swing GUI to a MySQL Database - #1
18 Connect Java Swing GUI to a MySQL Database - #2
19 Connect Java Swing GUI to a MySQL Database - #3
20 Connect Java Swing GUI to a MySQL Database - #4
21 Connect Java Swing GUI to a MySQL Database - #5
22 Connect Java Swing GUI to a MySQL Database - #6
23 Connect Java Swing GUI to a MySQL Database - #7
24 Connect Java Swing GUI to a MySQL Database - #8
25 Connect Java Swing GUI to a MySQL Database - #9
26 Connect Java Swing GUI to a MySQL Database - #10

 

Did you like my blog post?

Signup now and receive an email when I publish new luv2code content.

I will never give away, trade or sell your email address. You can unsubscribe at any time.

Share

17 Comments

  1. Comments  andrew   |  Monday, 02 November 2015 at 9:52 am

    Hey,

    Im having some trouble with my Jtable displaying the data i pull from mysql. i tried to break the problem down. I can get the data (i call students) to print to the console but when i try to implement a version of the table model inside a scrollpane (like yours) i can seem to get anything to show in my jpanel. Would you know how to help me?

    Thanks
    -A

  2. Comments  Chad Darby   |  Thursday, 05 November 2015 at 8:00 am

    Hi Andrew,

    I’d recommend that you download the code from the video series and get it running on your local computer.

    Once you’re successful with that, then you should compare your own personal code with the code from the video.

    Let me know if you need anything else πŸ™‚

  3. Comments  gito sukoco   |  Saturday, 02 April 2016 at 7:55 pm

    thanks very much… ilove this website

  4. Comments  Mark   |  Friday, 22 April 2016 at 5:45 pm

    Hi Chad,

    Just a word of gratitude for a wonderfully explained and designed course. I have just finished my degree and I learnt more from this course than my previous year in class learning Java & database implementation. Using your initial design and expanding on the functionality somewhat I was able to create a system I was very proud of, and truth be told would not have been possible without your code and tutorial guidance.

    Many Thanks.

  5. Comments  Denis   |  Sunday, 24 April 2016 at 4:01 am

    Thanks a lot Chad Darby for this excellent jbdc course! From this year and from this site I luv2code much more

  6. Comments  Chad Darby   |  Monday, 02 May 2016 at 9:01 am

    Hi Mark,

    I’m very happy that you found the JDBC course useful. Thanks for the compliments and taking the time to leave such kind words πŸ™‚

  7. Comments  Chad Darby   |  Monday, 02 May 2016 at 9:02 am

    Hi Denis,

    Thanks a bunch for watching the JDBC videos. I’m glad you enjoyed them. Thanks for the positive review πŸ™‚

  8. Comments  Chad Darby   |  Monday, 02 May 2016 at 9:03 am

    you are welcome! thanks for watching the videos πŸ™‚

  9. Comments  Bilguun   |  Tuesday, 03 May 2016 at 11:51 am

    Sorry my english bad but i very well understand this course .Thank you very much this JDBC course very nice tutorials
    Good luck (y) :))

  10. Comments  Chad Darby   |  Tuesday, 03 May 2016 at 9:41 pm

    awesome! so glad you enjoyed the course. thanks for watching πŸ™‚

  11. Comments  Anurag   |  Tuesday, 21 June 2016 at 2:49 pm

    Hi Chad Darby,

    i just start leaning java,so plz give me suggestions.

  12. Comments  Chad Darby   |  Friday, 01 July 2016 at 6:45 pm

    Hi Anurag,

    I have links to help you learn Java: http://www.luv2code.com/learnjava

  13. Comments  Subhadeep Niogi   |  Wednesday, 10 August 2016 at 4:38 pm

    Absolutely wonderful tutorials and great explanation. I am a newbie in Java and this website helped me a lot to get started with Eclipse, Java and the concept of Hibernate.

  14. Comments  Habib Al-Muhanna   |  Tuesday, 06 December 2016 at 1:15 pm

    Hi Chad,

    Thank you.

    Habib Adnan Al-muhanna.
    Baghdad – Iraq

  15. Comments  Chad Darby   |  Friday, 16 December 2016 at 10:39 am

    You are welcome, Habib πŸ™‚

  16. Comments  Vic Calag   |  Wednesday, 05 April 2017 at 6:31 pm

    Hello Chad,

    Greetings from Philippines!

    Thank you very much for this wonderful tutorial and for making it free to the public.

    Best regards,

    Vic

  17. Comments  Chad Darby   |  Thursday, 06 April 2017 at 5:44 pm

    Hi Vic,

    Thanks so much for the kind words! thanks for watching my videos πŸ™‚

Leave a Reply





About


ChΓ‘d (shod) Darby is a Java architect, author and instructor. He has over 20 years of Java development experience. Read more about him.

BTW: He luvs 2 code!

Make a Donation

Support the luv2code dude!

Follow Me

Subscribe via RSS

Search