Hello, I'm a new member, yep you guessed it.
I really need help understanding some concepts but I will like to take it one at a time.
The major problem is connecting to a database. The pdfs I got are useless..my lecturers' note pointless..
I am using the <sql:dataSource> tag to connect to a database...but the problem is i don't understand the attributes..
the driver attribute, from what I could glean helps the database to understand the java code..so the java code is translated into the database language in order to understand and process it.
What i don't understand is..where can I find the correct driver to use? How do I know if it is the correct one to use..every tutorial as a different one I want to go crazy..
The same thing with the other url tag..apparent it is the url for where the database is located.
Since I am using Access how can I find the url of the database.
I have seen many rude comments about how Access is bad and everything..don't have a go at the student please :O..its for assignment
That is the driver in my lecturers notes..so I am using that..but i am not sure what url to use for the access.
I went to the datasource option and created a DataSource called access..But how do I link it to the Access database?
Please help a lost JSP programmer.
How do you link it to the Access database?
Via the DataSources(ODBC) control panel in windows.
You set up the DSN to point to your specific access database .mdb file.
Make sure you create a SYSTEM DSN, and not a user DSN.
Your URL from java then just becomes jdbc:odbc:[insert_name_of_DSN_here]
so jdbc:odbc:access would be correct.
Joined: Apr 03, 2011
I got it to work, that was the problem I was setting it in User DSN.
Sorry I stole your thunder ;)...Yeah considering that our lecturers themselves told us last year not to use Access, its a hypocritical that we have to use it now..Ah well, it is for an assignment.
Can you explain what a data source is exactly..Is it like the name for a connection to a database or something. The explanations aren't quite clear.
And is it possible to have multiple databases/tables to a datasource. I tried and it always created a new datasource :S