Java Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsProgramming LanguagesJava Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old November 21st, 2012, 07:16 AM
Revoh Revoh is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2007
Location: Portugal
Posts: 38 Revoh User rank is Corporal (100 - 500 Reputation Level)Revoh User rank is Corporal (100 - 500 Reputation Level)Revoh User rank is Corporal (100 - 500 Reputation Level)Revoh User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 4 Days 6 h 34 m 46 sec
Reputation Power: 8
Connect into Access Database

I've been reading a lot of things, and i would like your help about this.

Some say that the connection can be done without the DSN, and i would like to do that, but I'm not being able to make the connection to the database i want.

And the problems starts here:

Code:
Connection conn = DriverManager.getConnection( "jdbc:odbc:Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\\Users\\Don Shinchan\\Documents\\Database1.mdb" );


The path is correct, and the database name is Database1 (i was testing).
And i get a null connection so something is wrong just don't know what, can someone help me out?

Reply With Quote
  #2  
Old November 21st, 2012, 09:05 AM
NormR's Avatar
NormR NormR is offline
Contributing User
Dev Shed Frequenter (2500 - 2999 posts)
 
Join Date: Aug 2010
Location: SW Missouri
Posts: 2,955 NormR User rank is Major (30000 - 40000 Reputation Level)NormR User rank is Major (30000 - 40000 Reputation Level)NormR User rank is Major (30000 - 40000 Reputation Level)NormR User rank is Major (30000 - 40000 Reputation Level)NormR User rank is Major (30000 - 40000 Reputation Level)NormR User rank is Major (30000 - 40000 Reputation Level)NormR User rank is Major (30000 - 40000 Reputation Level)NormR User rank is Major (30000 - 40000 Reputation Level)NormR User rank is Major (30000 - 40000 Reputation Level)NormR User rank is Major (30000 - 40000 Reputation Level) 
Time spent in forums: 1 Week 6 Days 2 h 53 m 34 sec
Reputation Power: 345
Is the URL passed to getConnection() correct? Where did you get the URL you are trying to use?

Reply With Quote
  #3  
Old November 22nd, 2012, 11:40 AM
Revoh Revoh is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2007
Location: Portugal
Posts: 38 Revoh User rank is Corporal (100 - 500 Reputation Level)Revoh User rank is Corporal (100 - 500 Reputation Level)Revoh User rank is Corporal (100 - 500 Reputation Level)Revoh User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 4 Days 6 h 34 m 46 sec
Reputation Power: 8
My own computer path to the database...

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesJava Help > Connect into Access Database

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap