I'll put it on, don't worry.

On Tue, Feb 16, 2010 at 1:23 PM, Mikael Henriksson <mik...@zoolutions.se>wrote:

> Gaah that's it I go home, play some xbox because I have become mentally
> instable! DiscriminatorValue(WTF) would have been a good first place to
> start looking...
>
> This gotta be on the daily wtf somewhere.
>
>
> On Tue, Feb 16, 2010 at 2:16 PM, Mikael Henriksson 
> <mik...@zoolutions.se>wrote:
>
>> HAH! Just because of that I decided to try it out anyway. It doesn't work
>> so here's something for you:
>>
>> NHibernate.MappingException : Could not format discriminator value to SQL 
>> string of entity
>> CpaSmsBilling
>>   ----> System.FormatException : Input string was not in a correct format.
>>
>>     public class BillingDetailMap : ClassMap<BillingDetail>
>>     {
>>         public BillingDetailMap()
>>         {
>>             Table("billing_info");
>>
>>             Id(x => x.Id)
>>                 .Column("billing_info_id")
>>                 .GeneratedBy.Identity()
>>                 .Not.Nullable();
>>
>>             Map(x => x.BillingProvider)
>>                 .Column("billing_provider_id")
>>                 .Not.Nullable();
>>
>>             References(x => x.BillingRecord)
>>                 .Column("billing_record_id")
>>                 .Not.Nullable()
>>                 .Cascade.None();
>>
>>             DiscriminateSubClassesOnColumn("billing_provider_id",
>> BillingProviders.None);
>>         }
>>     }
>>
>>     public class CpaSmsBilling : BillingDetail
>>     {
>>         public CpaSmsBilling()
>>         {
>>             BillingProvider = BillingProviders.CpaSms;
>>         }
>>
>>         public virtual string Platform { get; set; }
>>         public virtual string PlatformVersion { get; set; }
>>         public virtual string ValidationSuccessful { get; set; }
>>         public virtual DateTime ValidatedAt { get; set; }
>>         public virtual string ValidationInfo { get; set; }
>>         public virtual DateTime ResponseAt { get; set; }
>>         public virtual string IsBilledOk { get; set; }
>>         public virtual int SequenceNumber { get; set; }
>>         public virtual string Msisdn { get; set; }
>>         public virtual int ChargedPrice { get; set; }
>>
>>         protected override IEnumerable<PropertyInfo>
>> GetTypeSpecificSignatureProperties()
>>         {
>>             return new List<PropertyInfo>
>>                     {
>>                         typeof (Operator).GetProperty("Id"),
>>                         typeof
>> (Operator).GetProperty("AuthenticationSuccessful"),
>>                         typeof (Operator).GetProperty("ChargedPrice"),
>>                         typeof (Operator).GetProperty("Msisdn")
>>                     };
>>         }
>>     }
>>
>>     public class CpaSmsBillingMap : SubclassMap<CpaSmsBilling>
>>     {
>>         public CpaSmsBillingMap()
>>         {
>>             Table("billing_info_cpa_sms");
>>
>>             Map(x => x.ChargedPrice)
>>                 .Column("response_charge_price");
>>             Map(x => x.IsBilledOk)
>>                 .Column("response_status");
>>             Map(x => x.Platform)
>>                 .Column("validation_platform");
>>             Map(x => x.PlatformVersion)
>>                 .Column("validation_version");
>>             Map(x => x.ResponseAt)
>>                 .Column("response_message");
>>             Map(x => x.SequenceNumber)
>>                 .Column(" response_seqno");
>>             Map(x => x.ValidatedAt)
>>                 .Column("validation_timestamp");
>>             Map(x => x.ValidationInfo)
>>                 .Column("validation_info");
>>             Map(x => x.ValidationSuccessful)
>>                 .Column("validation_status");
>>         }
>>     }
>>
>>
>>
>> On Tue, Feb 16, 2010 at 2:02 PM, James Gregory 
>> <jagregory....@gmail.com>wrote:
>>
>>> These are my favourite support questions. Keep it up :)
>>>
>>> On Tue, Feb 16, 2010 at 12:32 PM, Mikael Henriksson <
>>> mik...@zoolutions.se> wrote:
>>>
>>>> Never mind, I totally reconsidered that.
>>>>
>>>> On Tue, Feb 16, 2010 at 12:42 PM, Mikael Henriksson <
>>>> mik...@zoolutions.se> wrote:
>>>>
>>>>> Hey guys,
>>>>>
>>>>> I need to do a pretty custom subclassoncolumn where I need to evaluate
>>>>> an enum and use one value for several options. What do I need to override?
>>>>>
>>>>
>>>>  --
>>>> You received this message because you are subscribed to the Google
>>>> Groups "Fluent NHibernate" group.
>>>> To post to this group, send email to fluent-nhibernate@googlegroups.com
>>>> .
>>>> To unsubscribe from this group, send email to
>>>> fluent-nhibernate+unsubscr...@googlegroups.com<fluent-nhibernate%2bunsubscr...@googlegroups.com>
>>>> .
>>>> For more options, visit this group at
>>>> http://groups.google.com/group/fluent-nhibernate?hl=en.
>>>>
>>>
>>>  --
>>> You received this message because you are subscribed to the Google Groups
>>> "Fluent NHibernate" group.
>>> To post to this group, send email to fluent-nhibern...@googlegroups.com.
>>> To unsubscribe from this group, send email to
>>> fluent-nhibernate+unsubscr...@googlegroups.com<fluent-nhibernate%2bunsubscr...@googlegroups.com>
>>> .
>>> For more options, visit this group at
>>> http://groups.google.com/group/fluent-nhibernate?hl=en.
>>>
>>
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Fluent NHibernate" group.
> To post to this group, send email to fluent-nhibern...@googlegroups.com.
> To unsubscribe from this group, send email to
> fluent-nhibernate+unsubscr...@googlegroups.com<fluent-nhibernate%2bunsubscr...@googlegroups.com>
> .
> For more options, visit this group at
> http://groups.google.com/group/fluent-nhibernate?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Fluent NHibernate" group.
To post to this group, send email to fluent-nhibern...@googlegroups.com.
To unsubscribe from this group, send email to 
fluent-nhibernate+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/fluent-nhibernate?hl=en.

Reply via email to