zoukankan      html  css  js  c++  java
  • ALinq for Oracle(V2.2) 日期 映射的一个 BUG(已修正)

    看到有朋友在搜索引擎上这个问题。故将这封邮件帖出来。其实碰到一些莫明其妙的问题,最好的办法是给我发电子邮件。


    The Oracle Provider don't recognize the Date type of Oracle database, please set the DbType of Column Mapping as DateTime, just like below
     
    [Column(Storage="_ShippedDate", UpdateCheck=UpdateCheck.Never, DbType="DateTime")]
      public System.Nullable<System.DateTime> ShippedDate
      {
    get;set;
    }
     
    Or do not special the DbType, just like below
    [Column(Storage="_ShippedDate", UpdateCheck=UpdateCheck.Never]
      public System.Nullable<System.DateTime> ShippedDate
      {
    get;set;
    }
     
    It's a bug,  but I have fixed it, i will send you the new version after a few hours.
     
    regard
    Shu Mai
     
     
    ------------------ Original ------------------
    Date:  Tue, Feb 23, 2010 06:31 AM
    To:  "ansiboy"<ansiboy@163.com>;
    Subject:  exception w/ Alinq (oracle db) - pls help!
     
    Hi! Thanks for releasing ALinq.
     
    I'm having a problem inserting a row into an Oracle table. I get the following exception on ..SubmitChanges();.
     
    The specified type 'DATE' is not a valid provider type.
     
       at ALinq.Oracle.OracleDataTypeProvider.a(String A_0, Int32 A_1, Int32 A_2, String[] A_3)
       at ALinq.Oracle.OracleDataTypeProvider.b(String A_0)
       at ALinq.SqlClient.dn.d(String A_0)
       at ALinq.SqlClient.ag.a(MetaDataMember A_0)
       at ALinq.SqlClient.ag.a(a3 A_0, MemberInfo A_1)
       at ALinq.Oracle.i.a(Expression A_0, LambdaExpression A_1)
       at ALinq.SqlClient.b8.e(MethodCallExpression A_0)
       at ALinq.SqlClient.b8.a(MethodCallExpression A_0)
       at ALinq.Oracle.i.a(MethodCallExpression A_0)
       at ALinq.SqlClient.b8.k(Expression A_0)
       at ALinq.SqlClient.b8.i(Expression A_0)
       at ALinq.SqlClient.SqlProvider.BuildQuery(Expression query, ce annotations)
       at ALinq.SqlClient.SqlProvider.Execute(Expression query)
       at ALinq.aa.a.b(c A_0)
       at ALinq.aa.a.c(c A_0)
       at ALinq.y.a(ConflictMode A_0)
       at ALinq.DataContext.SubmitChanges(ConflictMode failureMode)
       at ALinq.DataContext.SubmitChanges()
       at SANArchive.Program.Main(String[] args) in D:\Profiles\SAN\SANArchive\SANArchive\Program.cs:line 208
     
    The oracle table has several data fields of type "Date".
     
    Any ideas?
     
    Thanks for your help!

    

  • 相关阅读:
    JS面向对象编程的实现
    初见Javascript
    详解promise
    radio单选按钮组操作
    cookie欺骗实战案例
    XSS攻击
    前端如何实现异步加载
    日常问题
    求1+2+...+n
    二叉搜索树的后序遍历序列
  • 原文地址:https://www.cnblogs.com/ansiboy/p/1672832.html
Copyright © 2011-2022 走看看