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

Error being thrown when using openaccessdatasource on webpage (with gridview displaying data)

9 Answers 281 Views
Design Time (Visual Designer & Tools)
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Peter Huisman
Top achievements
Rank 2
Peter Huisman asked on 01 Dec 2010, 11:11 AM
This problem (and related issues) is already being looked into by Telerik through a support ticket, but as my delay is now already up to 2 weeks, I am seeing whether someone out there has had the same problem and resolved it.

I have a rlinq which exposed some flaws in the visual designer (fixed in the last build). When I make a webpage with an openaccess datasource that tries to retrieve data, I get the following error. Has anyone encountered this / attempted to solve this?

Thanks, much appreciated.

Server Error in '/' Application.
Application id class 'Telerik.OpenAccess.RT.OID.IntIdentity' must have field: 'public System.Int32 iD'
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
 
Exception Details: Telerik.OpenAccess.OpenAccessException: Application id class 'Telerik.OpenAccess.RT.OID.IntIdentity' must have field: 'public System.Int32 iD'
 
Source Error:
 
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
 
 [OpenAccessException: Application id class 'Telerik.OpenAccess.RT.OID.IntIdentity' must have field: 'public System.Int32 iD']
   Telerik.OpenAccess.SPI.Backends.ThrowException(Exception e) +28
   Telerik.OpenAccess.RT.ExceptionWrapper.Throw() +34
   OpenAccessRuntime.storagemanager.StorageManagerFactoryBuilder.createSmfForURL() +414
   OpenAccessRuntime.storagemanager.StorageManagerFactoryBuilder.createStorageManagerFactory() +486
   OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp.createStorageManagerFactory() +612
   OpenAccessRuntime.DataObjects.PersistenceManagerFactoryBase.init() +938
   OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp.init() +101
   OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp..ctor(PropertySet properties, Object classloader) +539
   OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp.getPersistenceManagerFactory(PropertySet props) +49
   OpenAccessRuntime.DataObjects.BootstrapPMF.getPersistenceManagerFactory(PropertySet props) +250
   Telerik.OpenAccess.RT.Helper.getPersistenceManagerFactory(PropertySet props) +372
   Telerik.OpenAccess.RT.DatabaseAdapter.AssertPersistenceManagerFactory(String usr, String password, Boolean open) +2077
   Telerik.OpenAccess.RT.DatabaseAdapter.GetObjectScope(TransactionProvider provider) +70
   Telerik.OpenAccess.Database.GetObjectScope(TransactionProvider provider) +40
   Telerik.OpenAccess.OpenAccessContextBase.GetScope() +155
 
[TargetInvocationException: Exception has been thrown by the target of an invocation.]
   System.RuntimeMethodHandle._InvokeMethodFast(IRuntimeMethodInfo method, Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeType typeOwner) +0
   System.RuntimeMethodHandle.InvokeMethodFast(IRuntimeMethodInfo method, Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeType typeOwner) +72
   System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks) +335
   System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) +28
   System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters) +19
   Telerik.OpenAccess.RT.DataSource.OpenAccessDataSourceView.ConstructContext() +1399
   Telerik.OpenAccess.RT.DataSource.OpenAccessDataSourceView.ExecuteSelect(DataSourceSelectArguments arguments) +182
   System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback) +21
   System.Web.UI.WebControls.DataBoundControl.PerformSelect() +143
   Telerik.Web.UI.GridTableView.PerformSelect() +38
   System.Web.UI.WebControls.BaseDataBoundControl.DataBind() +74
   Telerik.Web.UI.GridTableView.DataBind() +364
   Telerik.Web.UI.RadGrid.DataBind() +173
   System.Web.UI.WebControls.BaseDataBoundControl.EnsureDataBound() +66
   System.Web.UI.WebControls.CompositeDataBoundControl.CreateChildControls() +75
   System.Web.UI.Control.EnsureChildControls() +102
   System.Web.UI.Control.PreRenderRecursiveInternal() +42
   System.Web.UI.Control.PreRenderRecursiveInternal() +175
   System.Web.UI.Control.PreRenderRecursiveInternal() +175
   System.Web.UI.Control.PreRenderRecursiveInternal() +175
   System.Web.UI.Control.PreRenderRecursiveInternal() +175
   System.Web.UI.Control.PreRenderRecursiveInternal() +175
   System.Web.UI.Control.PreRenderRecursiveInternal() +175
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2496
 
Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.1

9 Answers, 1 is accepted

Sort by
0
Accepted
Zoran
Telerik team
answered on 02 Dec 2010, 09:59 AM
Hi Peter Huisman,

 This error can be thrown when there is an inconsistency in the version of the OpenAccess assemblies. For example you could have one version of the product installed, but some of our dll's with another version is present in your bin folder and gets loaded in the Application Domain. It usually happens when there is a difference between the versions of Telerik.OpenAccess.dll and Telerik.OpenAccess.35.Extensions.dll. I hope this provides useful for you as well as anyone in the community that might encounter this issue. On our side, we will try to provide an error earlier in the stack which points to the user what exactly is the issue as we admit, this exception is actually a side effect and a rather nasty one to trace.

Regards,
Zoran
the Telerik team
Accelerate your learning with industry's first Telerik OpenAccess ORM SDK. Download today.
0
Jason Marshall
Top achievements
Rank 1
answered on 22 Dec 2010, 06:04 PM
nevermind.
0
Guillermo
Top achievements
Rank 1
answered on 24 Jul 2012, 02:33 PM
Has anyone has more info regarding this problem?... The only way I make it go away is stopping and resuming the pool, but I have to do this every time I build the project and its becoming annoying. I already check the ORM references and versions and they are correct. 

Thanks
0
Zoran
Telerik team
answered on 26 Jul 2012, 03:34 PM
Hello Guillermo,

I would like to ask you about more information regarding when this problem is actually happening on your side. You mentioned that it happens when you rebuild your project, does it also mean that you are upgrading the OpenAccess assemblies to newer version, or is it just adding new functionality to your application and rebuilding, without upgrading OpenAccess? Also, what is the version of OpenAccess that you are using currently?

Regards,
Zoran
the Telerik team
OpenAccess ORM Q2'12 Now Available! Get your hands on all the new stuff.
0
Kyle
Top achievements
Rank 1
answered on 16 Aug 2012, 11:28 AM
I have same problem with new version and it happen almost always when my application pool is new. After few seconds it start work again:

Application id class 'Telerik.OpenAccess.RT.OID.IntIdentity' must have field: 'public System.Int32 _id'

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: Telerik.OpenAccess.OpenAccessException: Application id class 'Telerik.OpenAccess.RT.OID.IntIdentity' must have field: 'public System.Int32 _id'
 
0
Alexander
Telerik team
answered on 21 Aug 2012, 07:03 AM
Hello,

After some private communication it turned out that the error Mikko was getting was caused by an OpenAccess assembly with older version in one of the bin folders of his project. This is the most common cause for this problem, so if anyone else sees the same error, now he knows where to look at.

Kind regards,
Alexander
the Telerik team
Follow @OpenAccessORM Twitter channel to be the first one to get the latest updates on new releases, tips and tricks and sneak peeks at our product labs!
0
Palani
Top achievements
Rank 1
answered on 07 Mar 2013, 06:08 AM

I cleaned all files in my bin folder and my problem solved.

0
Steven Picard
Top achievements
Rank 1
answered on 19 Jul 2013, 03:06 PM
I recently inherited an ASP.NET app that uses Open Access. Although I generally use Telerik controls I have never used Open Access. I am getting the same error as above. Everything compiles and runs fine. This error only happens when I save. I have verified all versions are correct and that I have cleaned the project numerous time (so there are no outdated or conflicting DLL's.) This project worked for the other two developers (who are no longer here) and I have not modified their code related to this in any way.

Application id class 'Telerik.OpenAccess.RT.OID.IntIdentity' used by class 'XXX' must have field: 'public System.Int32 _XXX'.

Any ideas? This is really holding me up.

Thanks.
0
Alexander
Telerik team
answered on 19 Jul 2013, 03:40 PM
Hello Steven,

For the moment the only known reason for this error is the mismatch of OpenAccess assemblies in the bin folder. You said that you have already checked this, so it is possible that the problem is different in your case.
It would be best if you could send us a support ticket and attach there your project, so we could look into it. This would be the fastest way to reproduce the problem and find a solution.

Regards,
Alexander
Telerik
OpenAccess ORM Q2 2013 brings you a more powerful code generation and a unique Bulk Operations support with LINQ syntax. Check out the list of new functionality and improvements shipped with this release.
Tags
Design Time (Visual Designer & Tools)
Asked by
Peter Huisman
Top achievements
Rank 2
Answers by
Zoran
Telerik team
Jason Marshall
Top achievements
Rank 1
Guillermo
Top achievements
Rank 1
Kyle
Top achievements
Rank 1
Alexander
Telerik team
Palani
Top achievements
Rank 1
Steven Picard
Top achievements
Rank 1
Share this question
or