This is a migrated thread and some comments may be shown as answers.

Driver class 'net.sourceforge.jtds.jdbc.Driver is not available

3 Answers 160 Views
Getting Started
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Ben Shipper
Top achievements
Rank 1
Ben Shipper asked on 17 Dec 2009, 01:46 AM
Hello,

I'm currently evaluating the telerik open access orm (2009_3_1104), and i'm having issues with establishing an Object Scope from my database, receiving an error stating "Driver class 'net.sourceforge.jtds.jdbc.Driver is not available"

I am attempting to reverse map a few simple tables, and the wizard generates all the persistent objects as expected, however, i get an InvalidOperationException while trying to create an object scope from the database.

My code is as follows, and fails on creating the scope object.

Database db = Database.Get("DatabaseConnection1"); 
IObjectScope scope = db.GetObjectScope(); 
scope.Transaction.Begin(); 
 

The database is an old MSSQL 2000 instance and the connection string uses integrated security.

Full Stack trace of exception:
at Telerik.OpenAccess.SPI.Backends.ThrowException(Exception e)
at Telerik.OpenAccess.RT.ExceptionWrapper.Throw()
at OpenAccessRuntime.storagemanager.StorageManagerFactoryBuilder.createSmfForURL()
at OpenAccessRuntime.storagemanager.StorageManagerFactoryBuilder.createStorageManagerFactory()
at OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp.createStorageManagerFactory()
at OpenAccessRuntime.DataObjects.PersistenceManagerFactoryBase.init()
at OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp.init()
at OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp..ctor(IDictionary properties, Object classloader)
at OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp.getPersistenceManagerFactory(IDictionary props)
at OpenAccessRuntime.DataObjects.BootstrapPMF.getPersistenceManagerFactory(IDictionary props)
at Telerik.OpenAccess.RT.Helper.getPersistenceManagerFactory(IDictionary props)
at Telerik.OpenAccess.RT.DatabaseAdapter.AssertPersistenceManagerFactory(String usr, String password, Boolean open)
at Telerik.OpenAccess.RT.DatabaseAdapter.GetObjectScope(TransactionProvider provider)
at Telerik.OpenAccess.RT.DatabaseAdapter.Telerik.OpenAccess.SPI.IDatabaseAdapter.GetObjectScope()
at Telerik.OpenAccess.Database.GetObjectScope()
at open_access_test.Program.Main(String[] args) in C:\\directory_removed\\Program.cs:line 15
at System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args)
at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading.ThreadHelper.ThreadStart()"

Thankyou for your time,

Kind Regards,
Ben



3 Answers, 1 is accepted

Sort by
0
Damyan Bogoev
Telerik team
answered on 19 Dec 2009, 06:21 PM
Hello Ben Shipper,

It seems that the Telerik.OpenAccess.NTDS.dll is not found. Could you please check whether it is properly installed in the GAC under "C:\Windows\assembly"?

Regards,
Damyan Bogoev
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Ben Shipper
Top achievements
Rank 1
answered on 20 Dec 2009, 09:28 PM
Thankyou for your reply Damyan,

The Telerik.OpenAccess.NTDS dll is available in the GAC and seems to be installed correctly.

If I reference this library directly in my project, it does as you suggested fix the issue and i can successfully persist objects. Just wondering if this is the normal procedure, as I was under the impression that the reference would automatically be made?

I very much appreciate your help with this, and thankyou for your fast response.

This issue may be marked as resolved.

Regards,
Ben
0
Alexander
Telerik team
answered on 23 Dec 2009, 11:45 AM
Hi Ben Shipper,

This is definitely not the expected behavior. It should not be necessary to reference the NTDS dll manually or have such a reference in your project at all. It is enough to have the Telerik.OpenAccess and Telerik.OpenAccess.Query references. However, we could not reproduce the problem, maybe it is related to you environment settings. Please let us know if you face any further problems.

All the best,
Alexander
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
Getting Started
Asked by
Ben Shipper
Top achievements
Rank 1
Answers by
Damyan Bogoev
Telerik team
Ben Shipper
Top achievements
Rank 1
Alexander
Telerik team
Share this question
or