Exactly. The table really is just a heap of data indexed (non-uniquely) by id and timestamp. All operations are performed in bulk on the basis of time ranges and I have no need to ever update a particular existing row or care about its identity. Each row is effectively just a data point in a time series. (I could be using RRD for storing this data perhaps but there are other concerns that make it impractical here.)
I suppose I can just not use AR for this case. Most likely that will be more efficient anyways because I am moving large amounts of data around. Jeff. -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Srdjan Sent: Friday, September 08, 2006 9:25 AM To: [email protected] Subject: Re: [Castle-users] ActiveRecord table with no primary key which is never needed in his use case, YAGNI at its best... ;) Ayende Rahien wrote: > Never the less, I don't really like this approach. It basically > cancels any way to do update/delete to the table. > >> -----Original Message----- >> From: [EMAIL PROTECTED] >> [mailto:[EMAIL PROTECTED] On Behalf >> Of Srdjan >> Sent: Friday, September 08, 2006 3:25 PM >> To: [email protected] >> Subject: Re: [Castle-users] ActiveRecord table with no primary key >> >> >> Ayende Rahien wrote: >>> "no primary key for reasons of efficiency" - That is quite a >> contradiction. >>> A table without primary key is basically an unordered heap, searches >>> on this must perform a table scan. Highly costly. >> you would assume that he has indexed access paths, where non unique >> indexes are put on (id, time stamp). >> >> Srdjan >> >> >>>> -----Original Message----- >>>> From: [EMAIL PROTECTED] >>>> [mailto:[EMAIL PROTECTED] On >>>> Behalf Of Jeff Brown >>>> Sent: Friday, September 08, 2006 4:28 AM >>>> To: [email protected] >>>> Subject: [Castle-users] ActiveRecord table with no primary key >>>> >>>> I have a table with no primary key for reasons of efficiency. It >>>> basically consists of a bag of timestamped values associated with a >>>> given id. NHibernate seems to support this scenario by specifying >> an >>>> <id> element with no name, and AR has a suggestive looking >>>> PrimaryKeyType.None but using it throws an exception: >>>> >>>> NHibernate.MappingException >>>> Message: The element 'id' in namespace 'urn:nhibernate-mapping- >> 2.0' >>>> has incomplete content. List of possible elements expected: >>>> 'urn:nhibernate-mapping-2.0:meta urn:nhibernate- mapping-2.0:column >>>> urn:nhibernate-mapping-2.0:generator'. >>>> >>>> I don't really want to add a primary key to this table because I >>>> expect it to get _very_ large. (It contains a stream of >>>> performance data sampled at regular intervals from dozens of >>>> sources. I will probably switch things over to a better >>>> persistence mechanism but >> not >>>> now.) >>>> >>>> Jeff. >>>> >>>> ------------------------------------------------------------------- >>>> - >> - >>>> -- >>>> -- >>>> Using Tomcat but need to do more? Need to support web services, >>>> security? >>>> Get stuff done quickly with pre-integrated technology to make your >>>> job easier Download IBM WebSphere Application Server v.1.0.1 based >> on >>>> Apache Geronimo >>>> http://sel.as- >>>> us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 >>>> _______________________________________________ >>>> CastleProject-users mailing list >>>> [email protected] >>>> https://lists.sourceforge.net/lists/listinfo/castleproject-users >>> >>> -------------------------------------------------------------------- >>> - >> - >>> --- Using Tomcat but need to do more? Need to support web services, >>> security? >>> Get stuff done quickly with pre-integrated technology to make your >> job >>> easier Download IBM WebSphere Application Server v.1.0.1 based on >>> Apache Geronimo >>> http://sel.as- >> us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=1216 >>> 42 _______________________________________________ >>> CastleProject-users mailing list >>> [email protected] >>> https://lists.sourceforge.net/lists/listinfo/castleproject-users >>> >> >> --------------------------------------------------------------------- >> -- >> -- >> Using Tomcat but need to do more? Need to support web services, >> security? >> Get stuff done quickly with pre-integrated technology to make your >> job easier Download IBM WebSphere Application Server v.1.0.1 based on >> Apache Geronimo >> http://sel.as- >> us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 >> _______________________________________________ >> CastleProject-users mailing list >> [email protected] >> https://lists.sourceforge.net/lists/listinfo/castleproject-users > > > ---------------------------------------------------------------------- > --- Using Tomcat but need to do more? Need to support web services, > security? > Get stuff done quickly with pre-integrated technology to make your job > easier Download IBM WebSphere Application Server v.1.0.1 based on > Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=1216 > 42 _______________________________________________ > CastleProject-users mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/castleproject-users > ------------------------------------------------------------------------ - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ CastleProject-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/castleproject-users ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ CastleProject-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/castleproject-users
