Saturday, 20 August 2016

MY SQL ODBC CONNECTOR

The MySQL odbc connector works in a way that one needs to have created their database first in any version of phpmyadmin
Step one
After you have installed the connector on your computer
  • Open administrative tools
  • Select  ODBC ....
  • Then click add
  • Select MySQL odbc (either ANSI or ASCII but not both)
  • Then a MySQL window will pop up
  • Then fill in the following fields
  1. data source name(a name to your connection i.e medical)
  2. description(words that describe your connection)
  3. host name/tcp/IP server(local host or domain name or IP address )
  4. port(MySQL port)
  5. username(server user name)
  6. password(server password)
  7. database(select your database from the list) 
  • Then press ok to save your connection
  • Your connection will readily be available for use in any software development project 
NEXT WE WILL SEE HOW TO USE OUR CONNECTION IN VISUAL BASIC DOT NET
Thank you     admin

Wednesday, 2 December 2015

THE JAVA MYSQL CONNECTION CLASS

Problems in your database connectivity?
Here is the solution .For those using netbeans Here is the class


import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
import java.util.logging.Level;
import java.util.logging.Logger;

public class CreateDB
{
    public static  Connection getConnection()
    {
        String driver="com.mysql.jdbc.Driver";
        String url="jdbc:mysql://localhost:3306/tax";//name of the database(tax)
        String username="root";
        String password="";
        try {
            Class.forName(driver);
        } catch (ClassNotFoundException ex) {
            Logger.getLogger(CreateDB.class.getName()).log(Level.SEVERE, null, ex);
        }
        Connection con = null;
        try {
            con = (Connection) DriverManager.getConnection(url,username,password);
        } catch (SQLException ex) {
            Logger.getLogger(CreateDB.class.getName()).log(Level.SEVERE, null, ex);
        }
        return con;
    }  
}

Thursday, 26 November 2015

PROGRAMING

For all the programmers out there here is what you have been waiting for.
Now you can be able to get all the knowledge about computer programming and all your code snippets
right here for free of charge