Steps to Connect with Database đ„đ„ | Explained in Detail (Java Database Connectivity) - JDBC #3
VloĆŸit
- Äas pĆidĂĄn 13. 07. 2019
- What are the steps that are required to connect with the database in JDBC.
I have explained in brief what are the steps to follow to connect with database and perform operations with the database.
Steps to Connect with Database , explained in Detail (Java Database Connectivity) - JDBC #3
how to connect java program with database
1) load the driver:
Class.forName("com.mysql.jdbc.Driver")//
2)Create a Connection:
Connection con=DriverManager.getConnection("jdbc:mysql://127.0.0.1:3306/dbname","root","root");
3)Create query, Statement , PreparedStatement , CallableStatement
eg
String q="select * from students";
Statement stmt=con.createStatement();
ResultSet set=stmt.executeQuery(q);
4)Process the data :
while(set.next())
{
int id=set.getInt("studentID");
String name=set.getString("studentName");
System.out.println(id);
System.out.println(name);
}
5) Close the connection:
con.close();
Thank you sir đđ
You provided me with a strong foundation of JDBC.
great explanation!
21:10 kaun kehta hai Java Difficult hai...
Difficult tha ab nhi hai, THANK YOU soo much sir :)
Awesome video with great explaination.đđ
Seriously sir mujhe bohat dar lag raha for this topic and u helped me out , hats off to you. Expecting more videos on java for java developers
Kaun kehta hai Java difficult hai, thanks for your immense inputs bro!
Zabardast padhaheh bhai
TopClass And InDeapth Teaching
Superâ€â€â€
The unmost unrated channel but acha video bana te ho
Excellent sir g
If my class teacher tech this type wow u r osm sir love you sir
Great đ
hii sir thanks lot for this oswm playlist. sir please we need java projects
Perfectđ„
bhai aap jo bhi batate ho sab samajh aa jata hđ
Thanks bhaiiđđ
great video
great one
Greatđ
Mast sir. Thanks... â€ïžâ€ïžâ€ïž
nyc explanation
thanks sir
you are great đ
awesome vdo
Sat sat pranam apkođ
demo of JDBC should also be on command prompt using java program
â€â€â€â€â€ thank you đđđđ
đđđđ
thank you.
Good
simply we can use BufferReader also to fetch data
â€
Hare Krishna Hare Krishna Krishna Krishna Hare Hare
Hare Rama Hare Rama Rama Rama Hare Hare â€â€
Raadhe Raadhe â€â€
Jai Shree Ram â€â€â€
Please make videos on exceptions handling
Yes sir please
sir I face this issue while connectivity java.sql.SQLSyntaxErrorException: ORA-00942: table or view does not exist please solve this problem
exactly same issue
i didnt see you put any sketchy jar file from untrusted link into your library folder like other youtuber told us to.
Sir should i get Driver link...we were not get the driver proper from google.
sir pls work on audio .its very low
but its clear atleast
Which OS you are using ?
sublime text editor
Sir latest NetBeans IDE KA JDBC with my SQL dalo na......kisi ne bhi nahi dala video iske upar.....new version me library ka option nahi hai
how to find fully classified classname of oracle jdbc jar file??? please help
if all these are interfaces how we are creating object
sir an error genreted , javap is not recognized
add class path in advance system settings
Voice is very slow sir in this video
Ky bolte ho bhai
Mazha atta hai sunne međ
EXACTLY LMAO
mac book mai sql connector install kesa kren
editor konsa hai ye
sir where to load the driver?
đ”
javap' is not recognized as an internal or external command,
operable program or batch file.
How to solve this error???????
Step 1: Locate JDK Installation Directory
Locate the directory where you have installed the Java Development Kit (JDK). For example, if you installed JDK 17, the path might be something like C:\Program Files\Java\jdk-17.
Step 2: Set JAVA_HOME
Right-click on "This PC" or "Computer" on your desktop or in File Explorer.
Select "Properties."
Click on "Advanced system settings" on the left.
Click the "Environment Variables" button.
Under "System variables," click "New."
Enter JAVA_HOME as the variable name and the path to your JDK installation as the variable value (e.g., C:\Program Files\Java\jdk-17).
Step 3: Update PATH
In the "Environment Variables" window, find the "Path" variable under "System variables" and click "Edit."
Click "New" and add %JAVA_HOME%\bin to the list.
Step 4: Restart Command Prompt
Close any open Command Prompt windows and open a new one to ensure that the changes to the environment variables take effect.
Step 5: Verify Java Tools
Open a new Command Prompt and type the following commands:
Now, you should be able to use Java tools such as javap without encountering the "not recognized" error. If the issue persists, double-check the steps to ensure there are no typos or errors in the environment variable settings.
Hope this helps.
Sir I'm facing an error in MySQL command line client, everytime I enter password it crashes. What should I do? Please let me know.
Enter correct password.. Bro
Same happens with me, Im entering correct password, plz reply sir
@@pratikshakheme if you will enter wrong it will close automatically without any error
@@srschool4298 yes, solved sir
No suitable driver found for Url error
Mera ak error a raha hai kaha pe chat karke puche
mko kuch samajh ku nhi aya
com.mysql.cj.jdbc.Driver is the new class