Home
Search results “Jdbc localhost oracle”
How to use type 4 jdbc driver in eclipse(oracle 11g or 10g)
 
03:06
This Video shows you "How to use type 4 jdbc driver in eclipse(oracle 11g or 10g)" ---------------------------------------------------------------------------------- Before you do this you should have ------------------------------------------------------ (1) Oracle 11g or 10g installed in your pc (2) Eclipse installed in your pc (3) Write the jdbc program (4) Execute the query in SQL Prompt that you are used in your jdbc program --------------------------------------------------------------------------- STEPS 1. Before running the jdbc program, just in case make sure the query executes correctly 2. write the program( i will provide the jdbc program code below) 3. go to Eclipse 4. 'Right Click' on JRE System Library(Build path --~ Configure Build path--~ Add External Jars--~ *choose ojdbc 6 jar -----C:\oraclexe\app\oracle\product\11.2.0\server\jdbc\lib---- (just search for ojdbc6 jar in oracle path or (oraclexe) path) 5. click open 6. click Apply 7. click Apply and close --------------------------------------------- sample jdbc type 4 driver program to execute --------------------------------------------- package com.nt.jdbc; import java.sql.Connection; import java.sql.DriverManager; import java.sql.ResultSet; import java.sql.SQLException; import java.sql.Statement; import java.util.Scanner; public class FourthDriver { public static void main(String[] args) { Scanner sc=null; String user=null,pass=null; Connection con=null; ResultSet rs=null; Statement st=null; String query=null; int count=0; try { sc=new Scanner(System.in); if(sc!=null) { System.out.println("Enter Username: "); user=sc.nextLine(); System.out.println("Enter password: "); pass=sc.nextLine(); } user="'"+user+"'"; pass="'"+pass+"'"; Class.forName("oracle.jdbc.driver.OracleDriver"); con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:xe","system","manager"); if(con!=null) st=con.createStatement(); /*SELECT COUNT(*) FROM USERLIST WHERE UNAME='jaya' AND PWD='123';*/ query="SELECT COUNT(*) FROM USERLIST WHERE UNAME="+user+" AND PWD="+pass; System.out.println(query); if(st!=null) rs=st.executeQuery(query); if(rs!=null) { if(rs.next()) count=rs.getInt(1); System.out.println(count); } if(count==0) System.out.println("Invalid Credentials"); else System.out.println("Valid Credentials"); }//try catch(SQLException se){ se.printStackTrace(); System.out.println("Record insertion failed"); } // catch(ClassNotFoundException cnf){ // System.out.println("Record insertion failed"); // cnf.printStackTrace(); // // } catch(Exception e){ System.out.println("Record insertion failed"); e.printStackTrace(); } finally { try { if(rs!=null) rs.close(); }catch(SQLException se) { se.printStackTrace(); } try { if(st!=null) st.close(); }catch(SQLException se) { se.printStackTrace(); } try { if(con!=null) con.close(); }catch(SQLException se) { se.printStackTrace(); } try { if(sc!=null) sc.close(); }catch(Exception se) { se.printStackTrace(); } }//finally }//method }//class ---------------------------------------------------------------------- ask in comments if you have any doubts ---------------------------------------------------------------------- ---------------------------------------------------------------------------------------------------------- Visit www.99techbuzz.com for more Articles like this Video :) ________________________________________________________________ Subscribe to the Channel http://www.youtube.com/channel/UCndUIPHik4T497b2sC_A6sw?sub_confirmation=1 ---------------------------------------------------------------------------------------------------------- For more tips and tricks like The Facebook Page https://www.facebook.com/99techbuzz/ ----------------------------------------------------------------------------------------------------------
Views: 564 99TechBuzz
java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver
 
03:55
complete tutorial for beginner to Connect Java Application with Oracle database through jdbc
Views: 28318 alam jamal
Java Oracle Connection Part1
 
05:06
How to Connect Oracle database to Java Java Oracle Connection Part2 at : http://youtu.be/T_DceKcyBJg download Link : http://www.mediafire.com/download.php?grgdh35vzlcyivj has "jar file" + "SQL class" + "pdf show steps"
Views: 45589 Abdelrahman Hassan
[HINDI]How to connect oracle with java || In Eclipse || by tech valley
 
10:28
This video will explain you how to connect the oracle database with java in eclipse Download link for software and program 1. Eclipse mars.2 https://www.eclipse.org/downloads/ 2. Oracle express 11g accept the license and click on required link.. it requires sign in .. sign in to download http://www.oracle.com/technetwork/database/database-technologies/express-edition/downloads/index.html Program: import java.sql.*; class OracleCon{ public static void main(String args[]){ try{ //step1 load the driver class Class.forName("oracle.jdbc.driver.OracleDriver"); //step2 create the connection object Connection con=DriverManager.getConnection( "jdbc:oracle:thin:@localhost:1521:xe","system","oracle"); //step3 create the statement object Statement stmt=con.createStatement(); //step4 execute query ResultSet rs=stmt.executeQuery("select * from emp"); while(rs.next()) System.out.println(rs.getInt(1)+" "+rs.getString(2)+" "+rs.getString(3)); //step5 close the connection object con.close(); }catch(Exception e){ System.out.println(e); } } }
Views: 1982 Tech Valley
ClassNotFoundException oracle jdbc driver OracleDriver in Eclipse
 
13:23
If your Eclipse editor not found ojdbc14.jar file path..then you can do this procedure....it will solve your ClassNotFoundException in your JDBC Application in Eclipse...
Views: 14050 SIVA KRISHNA KASTURI
java.sql.SQLException: No suitable driver found for jdbc
 
01:58
Funciona para Netbeans , Eclipse
Views: 25715 n3x4 n3x4r
Create new connection with new user in Oracle SQL Developer
 
10:28
This video shows you how to create a new connection using a new user account (other than the system user account) in Oracle SQL Developer, so that you have a clean workspace without all the clutter of system tables. It is NOT a general introduction to using Oracle SQL Developer.
Views: 350726 Chitu Okoli
Crear Pool de Conexion GlassFish Server (Mysql-Oracle)
 
10:47
Vídeo tutorial de como crear pool de conexión GlassFish Server Solución Error class java.lang.RuntimeException Comandos Oracle y Mysql asadmin.bat create-jdbc-connection-pool --datasourceclassname com.mysql.jdbc.jdbc2.optional.MysqlDataSource --restype javax.sql.DataSource --property "portNumber=3306:serverName=localhost:DatabaseName=oms:password=123456:user=root:url=jdbc\\:mysql\\://localhost\\:3306/oms\\?zeroDateTimeBehavior\\=convertToNull" MysqlPoolConexion asadmin.bat create-jdbc-resource --connectionpoolid MysqlPoolConexion jdbc/mysqlCon asadmin.bat create-jdbc-connection-pool --datasourceclassname oracle.jdbc.pool.OracleDataSource --restype javax.sql.DataSource --property user=jacabarcas:password=123456:url="jdbc\:oracle\:thin\:@localhost\:1521\:XE" OraclePoolConexion asadmin.bat create-jdbc-resource --connectionpoolid OraclePoolConexion jdbc/oracleCon Solución Error (HTTP Status 500 - Internal Server Error type Exception report messageInternal Server Error descriptionThe server encountered an internal error that prevented it from fulfilling this request. exception java.lang.IllegalStateException: getOutputStream() has already been called for this response note The full stack traces of the exception and its root causes are available in the GlassFish Server Open Source Edition 4.1.1 logs.)
Oracle Database Tutorial 70: IO ERROR: The network adapter could not establish the connection
 
03:34
IO ERROR: The network adapter could not establish the connection Learn how to solve this Oracle Database / SQL Developer Error with in 4 minutes ------------------------------------------------------------------------ ►►►LINKS◄◄◄ Blog : http://bit.ly/sql-developer-error-the-network-adapter-could-not-establish-the-connection Previous Tutorial ► Intersect and Minus SQL set operators https://youtu.be/sDZFpwEw1k8 ------------------------------------------------------------------------- ►►►Let's Get Free Uber Cab◄◄◄ Use Referral Code UberRebellionRider and get $20 free for your first ride. ------------------------------------------------------------------------- ►►►Help Me In Getting A Job◄◄◄ ►Help Me In Getting A Good Job By Connecting With Me on My LinkedIn and Endorsing My Skills. All My Contact Info is Down Below. You Can Also Refer Me To Your Company Thanks ------------------------------------------------------------------------- Copy Cloud referral link || Use this link to join copy cloud and get 20GB of free storage https://copy.com?r=kb4rc1 -------------------------------------------------------------------------- ►Make sure you SUBSCRIBE and be the 1st one to see my videos! -------------------------------------------------------------------------- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ►►►Find me on Social Media◄◄◄ Follow What I am up to as it happens on https://twitter.com/rebellionrider https://www.facebook.com/imthebhardwaj http://instagram.com/rebellionrider https://plus.google.com/+Rebellionrider http://in.linkedin.com/in/mannbhardwaj/ http://rebellionrider.tumblr.com/ http://www.pinterest.com/rebellionrider/ You can also Email me at for E-mail address please check About section Please LIKE and SHARE my videos it makes me happy. Thanks for liking, commenting, sharing and watching more of our videos This is Manish from RebellionRider.com ♥ I LOVE ALL MY VIEWERS AND SUBSCRIBERS
Views: 151713 Manish Sharma
Oracle Database tutorials 4:  database connectivity using SQL developer and command prompt
 
09:19
Blog Link: http://bit.ly/how-to-create-new-connection-in-sql-developer Wishlist: http://bit.ly/wishlist-amazon This SQL tutorial and Oracle database 11g tutorial for beginners will show how to connect to database either on a local machine or on a machine in your LAN using ip address. Tool used in this tutorial is SQL developer & command prompt. This tutorial series is part of SQL expert exam certification training. If you are preparing for SQL certification you can use my tutorials. This SQL Tutorial is a part of free training. Copy Cloud referral link || Use this link to join copy cloud and get 20GB of free storage https://copy.com?r=j7eYO7 Contacts Email [email protected] Twitter https://twitter.com/rebellionrider Instagram http://instagram.com/RebellionRider Facebook. https://www.facebook.com/imthebhardwaj Linkedin. in.linkedin.com/in/mannbhardwaj/ Thanks for linking, commenting, sharing and watching more of our videos The Code makers
Views: 278362 Manish Sharma
Inserting Record To Oracle Database–JDBC | Najibullah Anwari | 2017
 
15:51
Visit our Website: http://www.afghanCoders.com Visit our Facebook Page: www.facebook.com/afghancoders56/ Visit our Twitter: www.twitter.com/afghancoders7/ ----------------------------------------------------------------------------------------------------------- package com.ac.jdbc; import java.sql.Connection; import java.sql.DriverManager; import java.sql.SQLException; import java.sql.Statement; public class InsertingRecord { public static void main(String[] args) { String oracleDriver = "oracle.jdbc.driver.OracleDriver"; Connection con = null; String url ="jdbc:oracle:thin:@localhost:1521:xe"; String uname ="system"; String pwd = "manager"; int countOfRecords = 0; String query = "insert into product values(109,'Computer',1400 )"; Statement st = null; try { Class.forName(oracleDriver); System.out.println("Driver Class Loaded"); con = DriverManager.getConnection(url,uname,pwd); System.out.println("Connection is Established "); st = con.createStatement(); countOfRecords = st.executeUpdate(query); System.out.println(countOfRecords +" Record is inserted Successfully "); } catch (ClassNotFoundException | SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } finally { if(st!=null) { try { st.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } if(con!=null) { try { con.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } } } } } }
Views: 11 AfghanCoders
Basics of jdbc programming Tutorial-11(Retrieving a text file from oracle database)
 
09:46
this video deals with the overall idea of how the jdbc program is connected to the database to retrieve a text file from the database. //Retrieving a text file from the oracle database import java.sql.*; import java.io.*; class Jdbc { public static void main(String[] args) throws Exception { Connection con=null; PreparedStatement pst=null; ResultSet rs=null; try { Class.forName("oracle.jdbc.driver.OracleDriver"); con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:xe", "student","shubham123"); if(con!=null) { System.out.println("connection established"); pst=con.prepareStatement("select * from myfile"); } if(pst!=null) { System.out.println("preparedstatement object created"); rs=pst.executeQuery(); rs.next(); Clob c=rs.getClob(1); System.out.println("File Size="+c.length()); Reader r=c.getCharacterStream(); int ch; FileWriter fw=new FileWriter("f://text.txt"); while((ch=r.read())!=-1) fw.write((char)ch); fw.close(); } } catch(SQLException e) { e.printStackTrace(); } catch(ClassNotFoundException e) { e.printStackTrace(); } catch(Exception e) { e.printStackTrace(); } finally { pst.close(); con.close(); } } }
Views: 66 Learn it by Fun
Connect Netbeans IDE 8.0 to Oracle Step By Step
 
10:44
In you database you can insert any thing you want and than retrieve your data from netbeans
Views: 62422 Ad H
MySQL Database connection in Java using Eclipse || Login page Example || English
 
10:44
download mysql-connector.jar file https://goo.gl/ftjWmK if this video really helped you then you can help me out by Donatation me on PayPal paypal.me/Tarique1 For connecting java application with the mysql database, you need to follow 5 steps to perform database connectivity. In this example we are using MySql as the database. So we need to know following informations for the mysql database: Driver class: The driver class for the mysql database is com.mysql.jdbc.Driver. Connection URL: The connection URL for the mysql database is jdbc:mysql://localhost:3306/test where jdbc is the API, mysql is the database, localhost is the server name on which mysql is running, we may also use IP address, 3306 is the port number and test is the database name. We may use any database, in such case, you need to replace the test with your database name. Username: The default username for the mysql database is root. Password: The default password for the mysql database is ""(blank).Password is given by the user at the time of installing the mysql database. In this example, we are going to use "" as the password. Let's first create a table in the mysql database, but before creating table, we need to create database first. create database test; use test; create table tblogin(UserName varchar(10),Password varchar(40)); ----------------------------------- The above example will fetch all the records of tblogin table. To connect java application with the mysql database mysqlconnector.jar file is required to be loaded. download the jar file mysql-connector.jar Two ways to load the jar file: paste the mysqlconnector.jar file in jre/lib/ext folder set classpath 1) paste the mysqlconnector.jar file in JRE/lib/ext folder: Download the mysqlconnector.jar file. Go to jre/lib/ext folder and paste the jar file here. 2) set classpath: There are two ways to set the classpath: temporary permanent How to set the temporary classpath open command prompt and write: C: set classpath=c:\folder\mysql-connector-java-5.0.8-bin.jar;.; How to set the permanent classpath Go to environment variable then click on new tab. In variable name write classpath and in variable value paste the path to the mysqlconnector.jar file by appending mysqlconnector.jar;.; as C:\folder\mysql-connector-java-5.0.8-bin.jar;.;
Views: 47164 Technical Babaji
81 Advanced Java Tutorial | JDBC | JDBC Connection Pool and Its Utilization | adv java
 
26:23
Advanced Java Tutorial :adv java: JDBC Connection Pool and Its Utilization | java Database connectivity :JDBC Connection Pooling: JDBC Connection pool is a factory that contains set of readily available JDBC connection objects. Using JDBC Connection pool we can make more clients interacting with Database by using minimum JDBC connection objects. JDBC DataSource object represent JDBC Connection pool that means to access connection objects from connection pool we need to use DataSource object. DataSource Object means its the object of a class that implements javax.sql.DataSource interface There are two types of JDBC connection objects: ----------------------------------------------- 1) Direct Connection object: Created by programmer (manually) Ex. Class.forName("oracle.jdbc.driver.OralcleDriver"); Connection con=DriverManager.getConnection("url","user","pass"); 2)Pooled Connection object: It is the object that is collected from JDBC connection pool using JDBC DataSource object. Two types of JDBC connection pools: ----------------------------------- 1) DriverManaged JDBC Connection Pool: (Driver itself maintains connections) -Suitbale for standalone application. -Uses Type 1/2/4/5 drivers directly. -Only few JDBC drivers support this kind of JDBC connection pools ex. Oracle OCI, thin driver 2) Server managed JDBC connection pool: -Suitable for web applicatoin which runs on web/proxy server. -Uses type 3 with type 1/2/4/5 JDBC drivers. -Suitable for 3-tier/n-tier applicatoin which runs on server environment. Example JDBC application on Oracle thin driver to manage the JDBC connection pool for Oracle: ========================================================================= import java.sql.*; import javax.sql.*; import oracle.jdbc.pool.*; public class ConnectionPoolTest { public static void main(String[] args) throws Exception { //create the Empty jdbc datasource object representing driver managed Connection pool for oracle OracleConnectionPoolDataSource ds=new OracleConnectionPoolDataSource(); //give the details to create JDBC connection objects in the above empty datasource connection pool i.e 'ds' ds.setDriverType("thin"); ds.setServerName("localhost"); ds.setPortNumber(1521); ds.setServiceName("orcl"); ds.setUser("scott"); ds.setPassword("boss"); //Upto here JDBC connection pool ready with JDBC connection object //get one JDBC connection object from connnection pool Connection con=ds.getConnection(); // Write the JDBC persistant logic Statement st=con.createStatement(); ResultSet rs=st.executeQuery("select * from student"); while(rs.next()){ System.out.println(rs.getInt(1)+"\t"+rs.getString(2)+"\t"+ rs.getString(3)); } rs.close(); st.close(); con.close(); // --- returns/release the conection object back to JDBC connection pool } }
Views: 601 tech fort
Database connection in Eclipse (Oracle) : javavids
 
03:33
How to connect Oracle database in Eclipse? Part of Java online video tutorials: http://www.javavids.com
Views: 91148 Jiri Pinkas
How connect Oracle SQL Developer to a local Oracle database
 
06:25
This video shows how to set up a local Oracle database and connect to it with SQL developer. LINKS: Oracle 11g database: http://www.oracle.com/technetwork/database/database-technologies/express-edition/downloads/index.html Oracle SQL Developer: http://www.oracle.com/technetwork/developer-tools/sql-developer/downloads/index.html
Views: 5133 MineIsPolo
How to Connect MS SQL Server Database with Oracle SQL Developer
 
05:38
how to connect sql server with sql developer how to connect sql server with sql develope How to Connect MS SQL Server Database with Oracle SQL Developer jtds - sql server and sybase jdbc driver cannot connect to microsoft sql server on localhost sql developer jtds-1.2.5.jar oracle sql developer oracle sql server download native sspi library not loaded sql developer jtds 3rd party jdbc driver oracle sql developer connect to microsoft sql server jtds-1.2.5.jar oracle sql developer jtds - sql server and sybase jdbc driver sql developer connect to sql server named instance jtds 3rd party jdbc driver sql developer cannot connect to microsoft sql server how to connect sql server with sql developer
Views: 11075 Oracle PL/SQL World
JDBC and Database Connectivity
 
14:14
// To retrive data from database package com.anwari.jdbc; import java.sql.Connection; import java.sql.DriverManager; import java.sql.ResultSet; import java.sql.SQLException; import java.sql.Statement; public class Test { public static void main(String[] args) { Connection con = null; Statement st = null; ResultSet rs = null; try { Class.forName("oracle.jdbc.driver.OracleDriver"); //create connection obj con = DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:xe", "system", "manager"); //create Statement object st = con.createStatement(); //create resultset object rs = st.executeQuery("Select pno ,pname,price from product "); while(rs.next()) { System.out.println("Product ID "+rs.getString(1)+" Product Name "+rs.getString(2)+" Product Price "+rs.getDouble(3)); } } catch (ClassNotFoundException | SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } if(rs!=null) { try { rs.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } } if(st!=null) { try { st.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } } if(con!=null) { try { con.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } } } }
Views: 315 AfghanCoders
Java JDBC Tutorial - Part 1: Connect to MySQL database with Java
 
09:06
5 FREE JAVA VIDEO COURSES - CLICK HERE - https://goo.gl/7i95F8 --- View more videos on my "Java JDBC Tutorial" Playlist: http://goo.gl/crT4nS Closed-Captioning and English subtitles available. In this tutorial, you will learn how to connect to a MySQL database with Java. Download source code from - http://www.luv2code.com/2014/03/21/connect-to-mysql-database-with-java-jdbc/ Please subscribe to my channel. http://goo.gl/EV6Kwv ---- Follow luv2code: Website: http://www.luv2code.com YouTube: http://goo.gl/EV6Kwv Twitter: http://goo.gl/ALMzLG Facebook: http://goo.gl/8pDRdA --- Join my mailing list: Get advance notice on new tutorials. Emails about 1 per week. - http://www.luv2code.com/joinlist --- Questions or problems? Post them in the comments section below. --- Want to suggest a video? Leave a comment below. I'm always looking for new video ideas. Let me know what video you'd like for me to create. --- Video Transcript Time - 00:00 Hello. In this tutorial, you will learn how to connect to a MySQL database with Java. In this session we’re going to learn how to connect a MySQL database with Java. Before we get started there are some prep work that needs to take place. One is that you need to have a MySQL database already installed. If not, you can download one from the site listed here on the slide. Time - 00:20 Next, we’ll need to download and install a MySQL JDBC driver. This driver will allow the Java program to connect to the database. You can download it from this URL, and I’ll do that now. I’ll just take this URL, drop it into my favorite browser and here I am at the page. I’m on this page, this is for downloading the Connector/J browser. I’ll select the platform, platform independent. Now move down and I’ll select download and it will download a zip archive. Make sure you download the most recent version. In this case it’s 5.1.29. Make sure you download something at that version or later. Time - 01:04 Download, scroll down, select, “No thanks, just start my download.” This will start downloading the file for you. Now what we can do is show it in the finder. I’ll double click it to extract it. At this point I have the driver extracted. There’s a file in here called MySQL connector.jar that we’ll use later. Time - 01:34 Next, what I need to do is create a Java project in Eclipse. Let’s do that. On Eclipse I’ll say I’ll save file, new, Java project. This will be JDBC demo and I will select finish. What I’ll do is I will add a new class. New, class, this will be my driver and it will have a public static void main region. At this point we have a shell for our project created. Time - 02:28 Next, what we’ll do is we will talk to the actual development process and I really like this slide because it outlines exactly what we need to do. The first thing we’ll do is add the database driver to the classpath. Next, we’ll get a connection, we’ll submit a SQL query and then we’ll process the result set. Time - 02:48 Let’s start with step one, adding a MySQL database driver to the classpath. In our Eclipse project I’m going to add a new folder called lib, lib for library. In this lib folder I’m going to add the driver that I downloaded earlier. What I’ll do is I’ll just grab this driver. It’s the MySQL connector bin.jar and I’ll just drag and drop it to this lib folder. It will prompt me and I’ll say go ahead and copy the file. Time - 03:25 Next, I need to add the jar file, the driver to the classpath. I’ve set this up with properties, choose Java build path and then I’ll choose add jars. Expand this folder, that lib, I’ll grab that jar file and I’ll have it setup. Great. Time - 03:51 Now we can start coding. We need to get a connection, submit a SQL query and process a result set. Let me just sketch this out on a slide over here. The first thing I’ll do up top is I’ll just do an import on java.sql.* because all of the classes and interfaces that we need are in this package. Time - 04:17 I’ll also just setup a try catch block just to handle for any exception that may occur. Small typo there. Time - 04:40 Inside of this section I’m going to first get a connection to database. Then next I will create a statement. Then from here I will execute a SQL query and then I will process the result set. Time - 05:16 That’s my basic game plan, let’s fill it in with some real code. Here I’ll say connection, myConn = DriverManager.getConnection. I’ll give the jdbc:mysql://localhost:3306/demo student, student. Student is the user ID and student is also the password. [snip] Click the Transcripts tab for full transcript.
Views: 642033 luv2code
MySQL Database via JDBC (read from table)
 
22:05
This is Ashton Fei, from Shenzhen China. Gmail: [email protected] Wechat: yunjia_fei Twitter: https://twitter.com/YunJiaFei Instagram: https://www.instagram.com/polymusic Apps Script Support: https://goo.gl/forms/GhJC63annAtIsif72 This is for MySQL server connection only. Script file: https://docs.google.com/spreadsheets/d/1Ph8tKTfYWkbXyFlO4bbqCa55LPv6Ex7V3yBMCzMppV8/edit?usp=sharing
Views: 11865 Ashton Fei
Oracle & Java Prg1 - How to Connect Oracle database with Java using Netbeans IDE
 
07:06
This video explains you how to create a new database connection in java with Oracle database...!
Views: 95286 Thamizh arasaN
How to connect to oracle database in java (using Eclipse)
 
06:26
How to connect to oracle database in java (using Eclipse) Database: Oracle 10g Enterprise Edition Download jar: Steps 1.Go to Link : http://www.oracle.com/technetwork/database/enterprise-edition/jdbc-112010-090769.html 2. Accept the licence agreement. 3. Select ojdbc6.jar
Views: 107364 Vishnu Kyatannawar
How to add mysql jdbc to eclipse
 
01:57
https://dev.mysql.com/downloads/connector/j/
Views: 24487 Otaku Style
Java NetBeans Tutorial:  Connecting to a MySQL Database with Java, JDBC and NetBeans
 
05:23
Download Java Source Code: http://www.luv2code.com/?p=992 In this video you will learn how to connect to MySQL with Java and NetBeans. Please subscribe to this channel :-) - https://www.youtube.com/user/luv2codetv?sub_confirmation=1 Video Transcript Time - 00:00 Hi, this is Chad (shod) with luv2code.com. In this video, you will learn how to connect to MySQL with Java and NetBeans. Time - 00:10 Let's go over the development process. The first thing we'll do is review the database tables, then we'll download and add MySQL database driver to NetBeans, then we'll actually create the Java code. Time - 00:25 Let's look at our database and see what data we have. We'll move to the MySQL workbench tool. See that we have a table called Employees and then we'll do a select star from that table and we'll see that we have three employees currently in our database. Time - 00:46 Now I'll create a simple NetBeans project. I'll go to the File menu, I'll select new Project. Make sure the Java application is selected and click next. For the project name, I'll give it jdbcdemo, I'll click Finish. Now what I'll do is I'll add a new Java Class. I'll select the project, I'll right click, I'll select New Java Class. For the name of the class I'll enter demo and hit finish. Now I have a basic Java Class ready to go. Time - 01:26 I will show you how to download the MySQL database driver and add it to your NetBeans project. First thing we have to do is visit the MySQL website at dev.mysql.com. On this page, we'll choose the dropdown and we'll select the platform independent. We'll choose the second entry here, the ZIP Archive and we'll click the download button. On the next page right near the bottom, we'll say no thanks, just start my download. Then we'll save it to our local system. Time - 02:07 Now let's move over to our Finder window on our file system and find the actual file that we just downloaded and I want to uncompressed it because right now it's a ZIP. I'll double click it, this will expand it or extract it. I'll look at it through list view. Now I have this new directory with the artifacts and there's a MySQL connector Java bin.jar, that's the actual JDBC driver that we'll use. Time - 02:35 Now we need to copy this file to the NetBeans project directory. I'll right click, I'll select copy then I'll switch over to NetBeans, I'll click the files tab and I'll select my project and I'll right click and I'll say paste. Even though the file is copied over, we still need to tell NetBeans that this a JAR library that we'll use on our project. What I'll do know is I'll click on the projects tab, I'll go to libraries and I'll choose add library and now I'll navigate to that NetBeans project directory where I actually have the file stored. Jbdcdemo and MySQL connector Java bin and I'll select choose. Then I'll expand this library's folder and we'll see that now this MySQL Java driver is part of this NetBeans project. Time - 03:37 Now let's start with the coding. The first thing I need to do is import Java to SQL package and then I'll drop in code for this main map it and then I'll walk through the code and show you how it works. This is our main map it, the main routine for the application. Then we have variables for the connection statement and result set. We also have the user id and password that we'll use. Time - 04:03 Then the first step is getting a connection to a database. We'll use the URL, the user id and the password. Then we go through and we create a statement object. Then we use this statement object to execute SQL query, select star from employees, then we'll process the result set and we'll simply print out the last name of the employee along with the first name. We have our accession handler and then we also clean up our resources at the end once we're done. Time - 04:42 Then to actually run the application, we will right click, select run file and at the bottom we have our output. We have our three employees that were listed in the database and our Java program was able to access it successfully. Great. Time - 04:59 Okay so this wraps up our video. You learned how to use NetBeans to connect to a MySQL database. Please subscribe to our channel to view more videos on Java, click thumbs up to like our video. Also visit our website luv2code.com to download the Java source code used in this video.
Views: 102463 luv2code
07. Oracle DataBase Connection with jsp servlet and Inserted data
 
13:08
Oracle DataBase Connection with jsp servlet and Inserted data. Toad for database and IDE eclipse for dinamic web project. Driver : http://www.mediafire.com/?rvu48ohne4xm1 //download jar.... Servlet Api : http://www.mediafire.com/?rvu48ohne4xm1 Class.forName("oracle.jdbc.driver.OracleDriver"); con = DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:orcl", "hr", "hr"); Project link : http://www.mediafire.com/?rvu48ohne4xm1
Views: 163 Sazibur Rahman
ORA-12505: TNS:listener does not currently know of SID given in connect descriptor
 
06:44
This video will show you How to fix "MSVCR100.dll missing from your computer" error which comes for various application when you try to run the application like Visual studio 2008, 2010 or 2012, wamp or php server, some popular games etc. Follow the steps that i have showed in this video. For that i have used the following link to download MSVCR100.dll file. Use this link to download the dll file http://jhelioviewer.org/libjhv/Microsoft.VC100.CRT-x86-32/msvcr100.dll
Views: 50325 Bangalore Techie
Basics of jdbc programming Tutorial-10(Storing a text file into oracle database)
 
10:36
this video deals with the overall idea of how the jdbc program is connected to the database in order to store a text file //storing of a text file to oracle database import java.sql.*; import java.io.*; class Jdbc { public static void main(String[] args) throws Exception { Connection con=null; PreparedStatement pst=null; try { Class.forName("oracle.jdbc.driver.OracleDriver"); con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:xe", "student","shubham123"); if(con!=null) { System.out.println("connection established"); pst=con.prepareStatement("update myfile set col1=? where col2=100"); } if(pst!=null) { System.out.println("preparedstatement object created"); File f=new File("f:\\hello.txt"); FileReader fr =new FileReader(f); pst.setCharacterStream(1,fr,(int)f.length()); System.out.println("file size="+f.length()); int i=pst.executeUpdate(); System.out.println(i+" records affected"); } } catch(SQLException e) { e.printStackTrace(); } catch(ClassNotFoundException e) { e.printStackTrace(); } catch(Exception e) { e.printStackTrace(); } finally { pst.close(); con.close(); } } }
Views: 127 Learn it by Fun
How to change Port number of Oracle Data Base
 
04:29
by kumar This video is going to tell you how to change your port no of oracle data base ,default port 8080.(oracle)
Views: 18797 brijesh kumar
How to install a JDBC driver in Oracle SQL Developer
 
02:38
To connect to a third party database in SQL Developer, you will need to install a jdbc driver. The drivers are free downloads. Review the supported jdbc driver versions at http://www.oracle.com/technetwork/products/migration/jdbc-migration-1923524.html. Copyright © 2013 Oracle and/or its affiliates. Oracle® is a registered trademark of Oracle and/or its affiliates. All rights reserved. Oracle disclaims any warranties or representations as to the accuracy or completeness of this recording, demonstration, and/or written materials (the "Materials"). The Materials are provided "as is" without any warranty of any kind, either express or implied, including without limitation warranties of merchantability, fitness for a particular purpose, and non-infringement.
Views: 152530 Oracle Learning Library
83 Advanced Java | JDBC 4 | without using Class forName(-) oracle thin driver | adv java
 
12:36
Advanced Java Tutorail : JDBC 4 0. adv java | Java Database Connectivity JDBC Application to test the database without using Class.forName(-) method. JDBC 4.0 Specification: The important feature of JDBC 4.0 specification is automatic loading of java driver class from java.sql. Driver File available from jar file of jdbc driver i.e. (ojdbc6.jar in oracle 11g). This makes programmers to avoid Class.forName(-) statement in his java application while writing jdbc code. - All the jdbc drivers thar are given based on jdbc 4.0 specification are giving java.sql.Driver File in there jar files, So when these jar files are added to the classpath the driver manager class automatically collects the driver class from java.sql.Driver File, loads the driver class & registers that driver automatically with DriverManager service. ojdbc14.jar (given by oracle 10g) is based on jdbc 3.0 specification so it does not contain java.sql.Driver File . ojdbc6.jar (given by oracle 11g) is based on jdbc 4.0 specification, so it contain java.sql.Driver File as shown below java.sql.Driver------oracle.jdbc.OracleDriver postgresql-8.4-701.jdbc4.jar of posgresql is based on jdbc 4.0 specification, so it contains java.sql.Driver File as shown below java.sql.Driver------org.postgresql.Driver JDBC application to test the connection with oracle database without using Class.forName(-) ===================================================== Step 1) Set the jar to the classpath ( ojdbc6.jar) Step 2) create the jdbc application import java.sql.*; public class WithoutClassForName { public static void main(String[] args) throws Exception { Connection con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:orcl", "scott", "boss"); Statement st=con.createStatement(); st.executeUpdate("insert into student values(1000,'patil','Omerga')"); } } compile & run
Views: 302 tech fort
Updating Record in Oracle Database–JDBC | Najibullah Anwari | 2017
 
11:33
Visit our Website: http://www.afghanCoders.com Visit our Facebook Page: www.facebook.com/afghancoders56/ Visit our Twitter: www.twitter.com/afghancoders7/ ----------------------------------------------------------------------------------------------------------- package com.afghancoders.jdbc; import java.sql.Connection; import java.sql.DriverManager; import java.sql.SQLException; import java.sql.Statement; public class UpdateRecord { public static void main(String[] args) { String oracleDriver = "oracle.jdbc.driver.OracleDriver"; Connection con = null; String url = "jdbc:oracle:thin:@localhost:1521:xe"; String uname = "system"; String pwd = "manager"; String query ="update product set pname ='ipad' where pno=103"; int countOfRecords = 0; Statement st = null; try { Class.forName(oracleDriver); System.out.println("Drive Class Loaded"); con = DriverManager.getConnection(url,uname,pwd); System.out.println("Connection Established"); st = con.createStatement(); countOfRecords = st.executeUpdate(query); System.out.println(countOfRecords +" Records Updated Successfully "); } catch (ClassNotFoundException | SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } finally { if(st!=null) { try { st.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } if(con!=null) { try { con.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } } } } } }
Views: 27 AfghanCoders
Fetch data from Oracle database to excel , using "APACHE POI".
 
16:26
To fetch data from oracle to excel ,we need to download.... 1-netbeans(https://netbeans.org/downloads/) 2-jdk(https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html) 3-oracle 11g(https://www.oracle.com/technetwork/database/enterprise-edition/downloads/index.html) 4-Apache Poi jars(https://mvnrepository.com/artifact/commons-lang/commons-lang/2.6)...https://mvnrepository.com/artifact/org.apache.poi/poi/3.9 5-jar for oracle:-https://www.oracle.com/technetwork/apps-tech/jdbc-112010-090769.html CODE:- import java.io.File; import java.io.FileOutputStream; import java.sql.*; import org.apache.poi.xssf.usermodel.XSSFCell; import org.apache.poi.xssf.usermodel.XSSFRow; import org.apache.poi.xssf.usermodel.XSSFSheet; import org.apache.poi.xssf.usermodel.XSSFWorkbook; class ExcelDatabase { public static void main(String args[]) throws SQLException{ try{ //step1 load the driver class Class.forName("oracle.jdbc.driver.OracleDriver"); //step2 create the connection object Connection con=DriverManager.getConnection( "jdbc:oracle:thin:@localhost:1521:xe","SYSTEM","SYSTEM"); //step3 create the statement object Statement stmt=con.createStatement(); //step4 execute query ResultSet resultSet=stmt.executeQuery("select * from EMPLOYE_TABLE"); XSSFWorkbook workbook = new XSSFWorkbook(); XSSFSheet spreadsheet = workbook.createSheet("employe db"); XSSFRow row = spreadsheet.createRow(1); XSSFCell cell; cell = row.createCell(1); cell.setCellValue("EMPLOYEE_ID"); cell = row.createCell(2); cell.setCellValue("EMPLOYEE_NAME"); cell = row.createCell(3); cell.setCellValue("EMPLOYEE_ADD"); cell = row.createCell(4); cell.setCellValue("EMPLOYEE_CONTACTNO"); cell = row.createCell(5); cell.setCellValue("EMPLOYEE_STATUS"); cell = row.createCell(6); cell.setCellValue("EMPLOYEE_SALARY"); int i = 2; while(resultSet.next()) { row = spreadsheet.createRow(i); cell = row.createCell(1); cell.setCellValue(resultSet.getInt("EMPLOYEE_ID")); cell = row.createCell(2); cell.setCellValue(resultSet.getString("EMPLOYEE_NAME")); cell = row.createCell(3); cell.setCellValue(resultSet.getString("EMPLOYEE_ADD")); cell = row.createCell(4); cell.setCellValue(resultSet.getString("EMPLOYEE_CONTACTNO")); cell = row.createCell(5); cell.setCellValue(resultSet.getString("EMPLOYEE_STATUS")); cell = row.createCell(6); cell.setCellValue(resultSet.getString("EMPLOYEE_SALARY")); i++; } FileOutputStream out = new FileOutputStream(new File("exceldatabase.xlsx")); workbook.write(out); out.close(); System.out.println("exceldatabase.xlsx written successfully"); //con.close(); }catch(Exception e){ System.out.println(e);} } }
Views: 655 TecHKmn
Conexão com Banco de Dados - JDBC
 
10:07
Neste vídeo vou estar realizando a conexão com banco de dados e fazendo o teste do mesmo. Link para download do Driver: PostgreSQL : https://jdbc.postgresql.org/download.html Oracle : http://www.oracle.com/technetwork/database/features/jdbc/index-091264.html MySQL : http://dev.mysql.com/downloads/connector/j/ Configuração de URL : -MySQL: Class.forName(“com.mysql.jdbc.Driver”); DriverManager.getConnection(“jdbc:mysql://localhost/bd”,”usuario”,senha); -Oracle: Class.forName(“oracle.jdbc.driver.OracleDriver”); DriverManager.getConnection(“jdbc:oracle:thin://localhost/bd”,”usuario”,senha);
Views: 544 Vinicius Junio
111 Java web application using JDBC Connection pool for Oracle, in Glassfish server Servlet Tutorial
 
31:54
Procedure to make #java #web #application #using #JDBC #Connection #pool(pool1) for #Oracle #database, created in #Glassfish #mydomain2 #server: Advance Java #Servlet #Tutorial Step 1) make sure that mydomain2 server of Glassfish is there in running mode. Step 2) Keep web appl ready Deployment Directory Structure: 35GFPoolApp ------- |-----index.html |-----WEB-INF |--------web.xml |--------classes |--------ConnPoolServlet.java |--------ConnPoolServlet.class for above web appplication Source code Refer 109 Servlet to Database communication using Approach 3 Connection Pool with Oracle, Weblogic Step 3) Change JNDI name from "techfort" to "GFOraCP" Step 4) Compile Servlet program & need to prepare .war file representing the whole web application compile Create war file C:\Users\om\Desktop\35GFPoolApp jar cf 35GFPoolApp.war . Step 5) Deploy above created web application in mydomain2 server of GlassFish hard deployment: (copy and paste war file to mydomain2\autodeploy directory) C:\glassfish3\glassfish\domains\mydomain2\autodeploy Step 6) Test the web application http://localhost:6060/35GFPoolApp/ (i have changed HTTP port number 8080 to 6060 in tutorial number 105) http://localhost:8080/35GFPoolApp/ (By defult port number is 8080)
Views: 73 tech fort
Basics of jdbc programming Tutorial-7(inserting row in Resultset object)
 
09:12
this video deals with the insertion of a row in updatable ResulSet. I have shown the insertion using a java code. //Insertion of a row using updatable ResultSet import java.sql.*; import java.util.*; class Jdbc { public static void main(String[] args) throws Exception { Connection con=null; Statement st=null; ResultSet rs=null; String query=null; try { Class.forName("oracle.jdbc.OracleDriver"); con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:xe","student","shubham123"); if(con!=null) { System.out.println("connection established"); st=con.createStatement(ResultSet.TYPE_SCROLL_SENSITIVE,ResultSet.CONCUR_UPDATABLE); } if(st!=null) { rs = st.executeQuery("select empid,ename,salary,comm,gender,city from emp026"); //Do not use * in oracle System.out.println("-----Current Records------"); while(rs.next()) { System.out.println(rs.getInt(1)+" "+rs.getString(2)+" "+rs.getDouble(3)+" "+rs.getDouble(4)+" "+rs.getString(5)+" "+rs.getString(6)); } System.out.println("\n-----------------------"); rs.moveToInsertRow(); rs.updateInt(1,60); rs.updateString(2,"ankit"); rs.updateDouble(3,3000); rs.updateDouble(4,40); rs.updateString(5,"male"); rs.updateString(6,"mumbai"); rs.insertRow(); //MySQL require primary key on table System.out.println("Data inserted"); rs=st.executeQuery("select empid,ename,salary,comm,gender,city from emp026"); while(rs.next()) { System.out.println(rs.getInt(1)+" "+rs.getString(2)+" "+rs.getDouble(3)+" "+rs.getDouble(4)+" "+rs.getString(5)+" "+rs.getString(6)); } } } catch(SQLException e) { e.printStackTrace(); } catch(ClassNotFoundException e) { e.printStackTrace(); } catch(Exception e) { e.printStackTrace(); } finally { st.close(); con.close(); } } }
Views: 166 Learn it by Fun
Java PostgreSQL Connection JDBC windows
 
15:42
Java and PostgreSQL connection JDBC CODE can be found on this link: https://www.tutorialspoint.com/postgresql/postgresql_java.htm Source : Tutorialspoint Download JAR file postgresql-(VERSION).jdbc.jar from postgresql-jdbc repository The latest one. .getConnection ("jdbc:postgresql://localhost:5432 /dbname","postgres", "password"); Add the jar file in library Click on services Database -- New Connection Driver PostgreSQL Enter Password Click Test Connection If connection then everyting is setuped properly Add the code. Done!
Views: 3863 dhiraj am
Basics of jdbc programming Tutorial-9(Retrieval of an image from the Database)
 
10:24
this video deals with the overall idea of how the jdbc program is used for Retrieval of an image from theoracle databse.The java code for retrieval of an image in oracle database: //retrieve an image from the database import java.sql.*; import java.io.*; class Jdbc { public static void main(String[] args)throws Exception { Connection con=null; PreparedStatement pst=null; ResultSet rs=null; try { Class.forName("oracle.jdbc.driver.OracleDriver"); con=DriverManager.getConnection( "jdbc:oracle:thin:@localhost:1521:xe","student","shubham123"); pst=con.prepareStatement("select * from image"); rs=pst.executeQuery(); if(rs.next())//now on 1st row { Blob b=rs.getBlob(2);//2 means 2nd column data byte by[]=b.getBytes(1,(int)b.length());//1 means first image FileOutputStream fout=new FileOutputStream("f:\\shubhamKumar.jpg"); fout.write(by); fout.close(); }//end of if System.out.println("ok"); } catch(SQLException e) { e.printStackTrace(); } catch(ClassNotFoundException e) { e.printStackTrace(); } catch(Exception e) { e.printStackTrace(); } finally { pst.close(); con.close(); } } }
Views: 62 Learn it by Fun
Install and configure Sql Developer on Windows | Oracle Tutorial
 
05:12
How to Install SQL Developer on Windows 1) Download for the below link http://www.oracle.com/technetwork/developer-tools/sql-developer/downloads/index.html 2) Make sure you have Java Development Kit installed with latest version. http://www.oracle.com/technetwork/java/javase/downloads/index.html 3) Install SQL developer as rpm -ihv sqldeveloper-xxx.noarch.rpm (replace xxx with exact version of your SQL developer) Run SQL developer on linux command prompt as $ sqldeveloper 4) Create a new connection to connect to user Technology Lair : www.technologylair.org Subscribe : http://www.youtube.com/subscription_center?add_user=technologylair For More Videos : http://www.youtube.com/user/technologylair/videos For Video Tutorials :http://www.youtube.com/playlist?list=PLC71CFFF7A916DCAA For Android : http://www.youtube.com/playlist?list=PLUXK1VpPWQKHI1l-NvM5jvNKKnmNy9eHp For Linux : https://www.youtube.com/playlist?list=PLUXK1VpPWQKHV2xOmjQgUNj3Hrmcslj-H Kalam e Iqbal : http://www.youtube.com/playlist?list=PLF057785BD260F061 Like us on Facebook : https://www.facebook.com/technologylair Tweet us : http://twitter.com/technologylair Follow us : https://plus.google.com/u/0/118196883367288585963/posts Pin us : http://www.pinterest.com/technologylair/
Views: 336254 TechLair
Jdbc tutorial part-5 | Advanced Java Tutorial |  Inserting Record into Database  |  JDBC  Videos
 
05:25
In This Video we will learn how to insert record into the database using JDBC program. Program code;- =================================================== import java.sql.DriverManager; import java.sql.Connection; import java.sql.Statement; import java.sql.SQLException; public class InsertingRecordDemo{ public static void main(String[] args) throws SQLException{ DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver()); Connection con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:xe","system","password"); Statement st=con.createStatement(); st.executeUpdate("insert into student values(53,'ramu',50.5)"); System.out.println("record is insterted"); } } =================================================== JDBC (java database connectivity) FREE video tutorials. Thanks for watching my video. SUBCRIBE my channel for new updates-
Views: 31 RAJASEKHAR REDDY
Basics of jdbc programming Tutorial-4 (Statement and PreparedStatement in jdbc)
 
22:39
this video is all about the basic concept about the Statement and PreparedStatement in jdbc ,I have shown with java program how to create the objects and execute the queries. import java.sql.*; class Jdbc { public static void main(String[] args)throws Exception { Class.forName("oracle.jdbc.driver.OracleDriver"); Connection con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:xe","student","shubham123"); Statement st=con.createStatement(); String query="insert into employeenew values(15,'srk',2000,30,'male','muz')"; int n=st.executeUpdate(query); if(n!=0) System.out.println("inserted"); else System.out.println("not inserted"); con.close(); } }
Views: 176 Learn it by Fun
110 Create JDBC connection Pool Oracle Database DataSource Glassfish server mydomain2 Servlet Tutori
 
33:42
Procedure to #create #JDBC #connection #Pool for #Oracle #Database #software, #JDBC #DataSource in "#mydomain2" (already created #domain) of #Glassfish #Application #Server: #Advance #Java #Servlet #Programming #Tutorial Keep ready "mydomain1 / mydomain2" Step 1) Place the oracle Thin driver relateed Jar file in following directory (ojdbc14.jar) C:\glassfish3\glassfish\domains\mydomain2\lib\ext directory Without adding ojdbc14.jar file to the ext directory/folder if we try to ping in connection pool, then it will show an errror: Ping: Error Ping not succeded on admin console Step 2) Start mydomain2 of GlassFish Server: C:\glassfish3\glassfish\bin asadmin start-domain mydomain2 Step 3) Open admin console of mydomain2 server. http://localhost:424/login.jsf Enter username and password Step 4) Create JDBC Connection Pool for Oracle: Go to admin console (Browser): Pool Name: pool1 (logical name) To check "pool1" connection pool is succeeded or not (Verify by applying Ping operation) Step 5) Crete JDBC DataSource Representing the above JDBC Connection Pool(pool1): go to admin console--- JNDI Name: GFOraCP To see/observe the above created JNDI tree structure goto application server ---- JNDI browsing The above created DataSource will be registered automatically with GlassFish registry having JNDI Name "GFOraCP"
Views: 61 tech fort
73 Advanced Java Tutorial |JDBC | ResultSetMetaData to print records given database | adv java
 
19:10
#Advanced Java Tutorial: adv java - Example Java JDBC application on ResultSetMetaData to print the records of given database table along with columns names & column datatype. import java.sql.*; import java.util.*; public class ResultSetMetaDataWithDataTypes { public static void main(String[] args) throws Exception { Scanner sc=new Scanner(System.in); System.out.println("enter the table name"); String tab=sc.next(); //create jdbc connection Class.forName("oracle.jdbc.driver.OracleDriver"); Connection con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:orcl", "scott", "boss"); //create peristant logic Statement st=con.createStatement(); ResultSet rs=st.executeQuery("select * from "+tab); ResultSetMetaData rsmd=rs.getMetaData(); int colCount=rsmd.getColumnCount(); ------------------------------------------------------- ----------------------------------- //close rs.close(); st.close(); con.close(); } }
Views: 227 tech fort
Java Tutorial 20 : Connect to MySQL Database
 
15:48
Please Rate, Comment and Subscribe. http://creativitytuts.org
Views: 399755 Naveed Ziarab
java.lang.ClassNotFoundException: com.mysql.jdbc:Driver-[Solved]
 
03:14
Download the Source Code of the project here http://chillyfacts.com/java-program-to-connect-to-mysql-database/ Solution for ClassNotFoundException-How to add jar file in eclipse java project http://chillyfacts.com/how-to-add-jar-file-in-eclipse-java-project/ Mysql connector jar download http://chillyfacts.com/mysql-connector-jar-download/ How to install Mysql DataBase https://www.youtube.com/watch?v=izNdC8ekzE8 Best Mysql Client for Windows https://www.youtube.com/watch?v=TaDn1vOTCLk ------------------------------------ Exception java.lang.ClassNotFoundException: com.mysql.jdbc.Driver at java.net.URLClassLoader$1.run(URLClassLoader.java:200) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:307) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at java.lang.ClassLoader.loadClass(ClassLoader.java:252) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:169) at Simple.MyProg.main(MyProg.java:15)
Views: 12719 jinu jawad m
Android Login Application With MSSQL Server Using JDBC
 
06:20
This video contains complete android login app tutorial connection with sql server using JDBC/Jtds.
Views: 110269 kamran bhatti
How to connect Java and MySQL in Eclipse on Windows 8.1
 
12:14
Many time you need a connection between Java and MySQL database. There are lots of drivers available for it.In this video we shows how to connect Java and MySQL in Eclipse IDE. If you write codes on notepad , please set "classpath" to connect with MySQL. If you have any questions comment it below..
Views: 141018 7chip
Configure Database on WebSphere Message Broker or Integration Bus
 
08:16
In this video we will see who to Configure Database on Integration Bus or WebSphere Message Broker. Commands used for Configuration SET BROKERNAME=ProjectsGeek SET PROVIDERNAME=ROUTING MQSIDELETECONFIGURABLESERVICE %BROKERNAME% -c JDBCProviders -o %PROVIDERNAME% mqsicreateconfigurableservice %BROKERNAME% -c JDBCProviders -o %PROVIDERNAME% -n connectionUrlFormat,connectionUrlFormatAttr1,databaseName,databaseType,databaseVersion,jarsURL,portNumber,securityIdentity,serverName,type4DatasourceClassName,type4DriverClassName -v "jdbc:oracle:thin:[user]/[password]@[serverName]:[portNumber]:[connectionUrlFormatAttr1],"xe","8","Oracle","11.2","C:\oraclexe\app\oracle\product\11.2.0\server\jdbc\lib","1521","mySecurityIdentity",localhost,"oracle.jdbc.xa.client.OracleXADataSource","oracle.jdbc.OracleDriver" MQSISETDBPARMS %BROKERNAME% -n jdbc::mySecurityIdentity -u System -p admin MQSISETDBPARMS ProjectsGeek -n odbc::ROUTING -u System -p admin mqsichangeproperties %BROKERNAME% -c JDBCProviders -o %PROVIDERNAME% -n securityIdentity -v mySecurityIdentity mqsireportproperties %BROKERNAME% -o %PROVIDERNAME% -c JDBCProviders -r
Views: 2743 ProjectsGeek