Visual Basic Programming Tutorial - Connecting to a MySQL Database with VB.NET Using ADO.NET

Loading...

Sign in or sign up now!
Alert icon
Upgrade to the latest Flash Player for improved playback performance. Upgrade now or more info.
6,725
Loading...
Alert icon
Sign in or sign up now!
Alert icon

Uploaded by on Sep 28, 2011

In this Visual Basic 2010 programming tutorial, we'll be connecting to and pulling data from a MySQL database, utilizing the ADO.NET connector provided at http://www.mysql.com/products/connector/

In this video, we will perform the following tasks:
1.) Creating the Connection Objects, a Connection String, and a Query String
2.) Connecting to our MySQL Database
3.) Drawing Data from our Database to our Windows Form
4.) Filtering our query results, and sorting the data
5.) Creating a Table Relationship to pull data from multiple tables
6.) Disconnecting from the Database

This tutorial assumes that you already have an operable MySQL database, access to the database, and a basic working knowledge of your database.

  • likes, 0 dislikes

Link to this comment:

Share to:

Uploader Comments (Aardaerimus)

  • Great video! Don't you happen to have a tutorial to connect to a Postgresql server?

  • @victorpictor Thank you, Victor. :-)

    Unfortunately, I've never attempted a connection to postgresql with VB, though there does appear to be a couple different data providers out there for it. Try googling "npgsql" or "psqlODBC". Hope this gets you on the right path. :-)

  • if u compile a program with SQL in it dose other PC have to have SQL installed on them to run yr program?

    great videos btw ::)

  • @Rardon99 Thank you Rardon99. :-)

    Yes, they will have to have an functional and accessible installation of MySQL on their computer or another accessible server. What you CAN compile with your program are SQL scripts that will configure a new database on their server, and create the table structure. This is a standard practice for database applications.

    Another environment, is a game server where the database is only accessible to the server (user accounts, etc.) and the users won't see it. :-)

  • Whoa! I wish I knew how to do this... Really want to learn how to make an online game. Maybe I can figure it out using this tutorial!

    *watches*

    :O!!! C++ Driver for MySQL? This sounds exciting. Alright, I'm looking into this.

  • @DrunkenWaffle Yup! The C++ Driver is on the same download page. :-D

    Should be very similar, connection-wise. I've also used this with ASP, and just learned the same with PHP. Good stuff! :-)

    A DB makes certain kinds of storage soooo nice. Good for "save game" data, and user accounts, and lotsa other stuffs, and the nice thing is all the data you pull to and enter from your game or application is also easily pulled into web pages.

    I've made my own web apps and forums from scratch with it. :-D

see all

All Comments (11)

Sign In or Sign Up now to post a comment!
  • @Aardaerimus :O! Awesome! You will definitely pull an awesome project together in the future... I can't wait to see it :D

    I'm definitely looking into this soon. :P

Loading...

Alert icon
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more