• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Connecting to SQL Server from NetBeans

 
kelly devon
Ranch Hand
Posts: 78
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How do i connect to SQL server from the SQL server itself or should i write the JDBC ODBC code? because from the netbeans application i cannot link. please help
thank you
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do you mean what client should you use? SQL Server Management Studio comes with the SQL Server tools.


or should i write the JDBC ODBC code

Unless your database is Access you should never have to write JDBC-ODBC code.
 
kelly devon
Ranch Hand
Posts: 78
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Am sorry i meant what client should i use. cause i tried asking the netbeans application to locate the sql server which it didnt so am confused. its not even recognising it. please help thank you
 
Jan Cumps
Bartender
Posts: 2586
11
C++ Linux Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am moving this post to our IDE forum.
I adapted to title to show that you can't connect to SQL Server with NetBeans.
 
Peter Johnson
author
Bartender
Posts: 5852
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Two steps: first register the JDBC driver, then register the database. Details:

1) Click on the Services tab (it is in the top-left panel, next to the Projects ans Files tabs). Expand databases and right-click Drives, choose New Driver. In the New JDBC Driver dialog click Add and locate the JDBC driver JAR file. Once you identify the driver JAR the rest of the fields in the dialog should be filled. Click OK

2) Right-click the driver and select Connect Using. Fill out the New Database Connection dialog for your database. Click OK. A new entry for your database shows up under Database.

You can then expand the database entry to view tables and data.
 
kelly devon
Ranch Hand
Posts: 78
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you so much
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic