[fluent-nhib] Fluently and PersistanceModel

2009-03-24 Thread Dru Sellers
how do I get the two of these to work together? is this it? Configuration nhcfg = Fluently.Configure() .Database(() => MsSqlConfiguration.MsSql2005.ConnectionString(x => { x.Database("FocusPa

[fluent-nhib] Re: Do not want to Virtualize my persistent classes

2009-03-24 Thread James Gregory
I do indeed, sorry about that. On 3/24/09, Paul Batum wrote: > James, do you mean Not.LazyLoaded() ? > > On Wed, Mar 25, 2009 at 8:24 AM, James Gregory > wrote: > >> In your ClassMap, call LazyLoaded(). That should inform NHibernate that >> you >> don't want it to generate proxies for that parti

[fluent-nhib] Re: Do not want to Virtualize my persistent classes

2009-03-24 Thread Paul Batum
James, do you mean Not.LazyLoaded() ? On Wed, Mar 25, 2009 at 8:24 AM, James Gregory wrote: > In your ClassMap, call LazyLoaded(). That should inform NHibernate that you > don't want it to generate proxies for that particular entity. > > > On Tue, Mar 24, 2009 at 8:38 PM, greg.co...@gmail.com < >

[fluent-nhib] Re: PersistenceSpecification question

2009-03-24 Thread James Gregory
It's most definitely something wrong with FNH, most likely something wrong with the PersistenceSpecification. What's wrong, I couldn't tell you. This is going to require more research on my part. On Tue, Mar 24, 2009 at 1:30 PM, Bill wrote: > > Hi, > > So, I'm trying to understand - this is an i

[fluent-nhib] Re: Patch for Issues 96, 161, 162, 163 and 164

2009-03-24 Thread James Gregory
Thanks Hudson, this is great. I've applied your patch and closed the related issues. On Tue, Mar 24, 2009 at 9:28 PM, Hudson Akridge wrote: > > Tests done. Patch posted to each of the issues, and I also shot you an > email with more details. Please let me know if you need anything else > sir. > >

[fluent-nhib] Re: Patch for Issues 96, 161, 162, 163 and 164

2009-03-24 Thread Hudson Akridge
Tests done. Patch posted to each of the issues, and I also shot you an email with more details. Please let me know if you need anything else sir. On Mar 24, 1:26 pm, Hudson Akridge wrote: > I don't mind creating a couple tests. I'll see if I can't crank those > out today for you guys. > > On Mar

[fluent-nhib] Re: Do not want to Virtualize my persistent classes

2009-03-24 Thread Tuna Toksoz
You can use interfaces for entities, or you can use static proxies (i don't know about it's current status though) Tuna Toksöz Eternal sunshine of the open source mind. http://devlicio.us/blogs/tuna_toksoz http://tunatoksoz.com http://twitter.com/tehlike On Tue, Mar 24, 2009 at 10:38 PM, greg

[fluent-nhib] Re: Do not want to Virtualize my persistent classes

2009-03-24 Thread James Gregory
In your ClassMap, call LazyLoaded(). That should inform NHibernate that you don't want it to generate proxies for that particular entity. On Tue, Mar 24, 2009 at 8:38 PM, greg.co...@gmail.com wrote: > > I'm new to Fluent NHibernate for I appologive if this is a newbe > question with a simple answ

[fluent-nhib] Do not want to Virtualize my persistent classes

2009-03-24 Thread greg.co...@gmail.com
I'm new to Fluent NHibernate for I appologive if this is a newbe question with a simple answer. Is there a way using Fluent Nhibernate to map your classes such that you do not have to virtualize each method/property? I don't mind having lazy loading for my collections, but prefer not to have NHib

[fluent-nhib] Re: .WithTable in IAutoMappingOverride doesn't override IClassConvention

2009-03-24 Thread James Gregory
Yep, something smelly is going on here. I'll investigate. On Tue, Mar 24, 2009 at 8:13 PM, Billy wrote: > > Looks like this is related to the issue described at > > http://groups.google.com/group/fluent-nhibernate/browse_thread/thread/b866ce932b2a4f89 > > Incidentally, if I modify the class conv

[fluent-nhib] .WithTable in IAutoMappingOverride doesn't override IClassConvention

2009-03-24 Thread Billy
Hi James, I'm updating S#arp Architecture's example project to the last and have made great progress. In fact, the thing remaining is a problem I'm having with an override not "taking." I have the following class convention: public class TableNameConvention : IClassConvention { public bool

[fluent-nhib] Re: .WithTable in IAutoMappingOverride doesn't override IClassConvention

2009-03-24 Thread Billy
Looks like this is related to the issue described at http://groups.google.com/group/fluent-nhibernate/browse_thread/thread/b866ce932b2a4f89 Incidentally, if I modify the class convention to ignore the Region class, then the override works just fine; e.g., public class TableNameConvention : IClas

[fluent-nhib] Re: Specifying database level "on delete" rule not possible?

2009-03-24 Thread Miha Necak
Thank you very much for a quick reply, but that is not what I am looking for (at least I don't think so). The address you provided is a nice resource, but talks about NHibernate level cascade. I'm looking for something similar to this The first cascade is NHibernate level, the second on

[fluent-nhib] Re: Specifying database level "on delete" rule not possible?

2009-03-24 Thread Jon Kruger
This post shows some examples of how you can do it. http://marekblotny.blogspot.com/2009/02/fluent-nhbernate-and-collections.html On Tue, Mar 24, 2009 at 3:22 PM, Miha Necak wrote: > > I am trying to find a way to set the "on-delete" = "cascade" attribute > on key tag that NHibernate enables. Th

[fluent-nhib] Specifying database level "on delete" rule not possible?

2009-03-24 Thread Miha Necak
I am trying to find a way to set the "on-delete" = "cascade" attribute on key tag that NHibernate enables. The result as I understand should also be exportable sql schema geration script with cascades. The goal is for the database to handle cascaded deletes. I've tried all the available conventio

[fluent-nhib] Re: Patch for Issues 96, 161, 162, 163 and 164

2009-03-24 Thread Hudson Akridge
I don't mind creating a couple tests. I'll see if I can't crank those out today for you guys. On Mar 24, 1:12 pm, James Gregory wrote: > Hey Hudson, > This is great, I really appreciate the work you've put into this. If you're > willing, a patch with tests would be even better. It's not that I h

[fluent-nhib] Re: Patch for Issues 96, 161, 162, 163 and 164

2009-03-24 Thread James Gregory
Hey Hudson, This is great, I really appreciate the work you've put into this. If you're willing, a patch with tests would be even better. It's not that I have any issue with the code you've written, but tests help us make sure we don't suffer any regressions in the future. Let me know if you have

[fluent-nhib] Patch for Issues 96, 161, 162, 163 and 164

2009-03-24 Thread Hudson Akridge
Hello, My associate Robert Dusek and I work with NHibernate on a daily basis in a production environment. We attempted to look into converting our production hbm.xml mappings to Fluent mappings, and in this process we've encountered some bugs/difficulties as described in the 5 issues refer

[fluent-nhib] Re: When mapping a byte array, how do I specify the maximum size?

2009-03-24 Thread Karron Qiu
try this. .CustomTypeIs("BinaryBlob"); On Tue, Mar 24, 2009 at 7:20 AM, pangyan wrote: > > Hmm, I did try that. With the latest Fluent NHibernate build > (0.1.0.416), I get the following error: > > System.InvalidOperationException: Content is not a string > > It looks like WithLengthOf is only

[fluent-nhib] Re: PersistenceSpecification question

2009-03-24 Thread Bill
Hi, So, I'm trying to understand - this is an issue with PersistenceSpecification or Fluent NHibernate, not a problem with NHibernate itself, correct? My complete entity heirarchy seems to be working in my application - I just can't figure out how to use PersistenceSpecification to test it. than

[fluent-nhib] Re: How to make IClassConvention or IIdConvention not override my ClassMap

2009-03-24 Thread Filip Kinsky
+1 for this kind of solution I currently also stepped on this issue - I'd like to specify that all int properties should be defined as "Not.Nullable ().SetAttributeOnColumnElement("default", "0")" unless there is Nullable() specified in fluent mapping. On 19 Bře, 16:13, Jon Kruger wrote: > I ha

[fluent-nhib] Re: IJoinedSubClassConvention never called

2009-03-24 Thread Martin Hornagold
FYI, I just tried removing the override and it still never gets called. -Original Message- From: fluent-nhibernate@googlegroups.com [mailto:fluent-nhibern...@googlegroups.com] On Behalf Of Martin Sent: 24 March 2009 10:15 To: Fluent NHibernate Subject: [fluent-nhib] IJoinedSubClassConvent

[fluent-nhib] IJoinedSubClassConvention never called

2009-03-24 Thread Martin
Hi, I have the following class structure: BaseEntity | Person | Author The mapping all works out perfectly, Person is mapped as a class with the Id inherited from the base class, and Author is set as a JoinedSubClass. The problem is that my project has a convention of pluralised tab