zoukankan      html  css  js  c++  java
  • PetaPoco.Core.ttinclude修改

    /// <summary>
    /// Adds the singular rule.
    /// </summary>
    /// <param name="rule">The rule.</param>
    /// <param name="replacement">The replacement.</param>
    private static void AddSingularRule(string rule, string replacement) {
    //_singulars.Add(new InflectorRule(rule, replacement));
    }

     mysql:

    public Column PK
    {
    get
    {
    if(this.Columns.Count>1)
    {
    return this.Columns[0];
    }
    else
    {
    return this.Columns.SingleOrDefault(x=>x.IsPK);
    }
    }
    }

    public static bool Exists(object primaryKey) { return repo.Exists<T>(primaryKey); }
    public static bool Exists(string sql, params object[] args) { return repo.Exists<T>(sql, args); }
    public static bool Exists(Sql sql) { return repo.Exists<T>(sql); }

    OracleSchemaReader修改

    //col.PropertyType=GetPropertyType(rdr["DataType"].ToString(), (rdr["DataType"] == DBNull.Value ? null : rdr["DataType"].ToString()));
    col.PropertyType=GetPropertyType(rdr["DataType"].ToString(), (rdr["DATASCALE"] == DBNull.Value ? "" : rdr["DATASCALE"].ToString()));
    //col.IsNullable=rdr["IsNullable"].ToString()=="YES";
    col.IsNullable=rdr["IsNullable"].ToString()=="Y";
    col.IsAutoIncrement=true;

    if (sqlType.ToLower() == "number" && dataScale == "0")
    return "int";

    //修改
    //cmd.GetType().GetProperty("BindByName").SetValue(cmd, true, null);
    PropertyInfo bindByNameInfo = cmd.GetType().GetProperty("BindByName");

    //修改
    tbl.SequenceName=tbl.Name+"_SEQUENCE";

  • 相关阅读:
    编译问题----宏定义一定显示未定义
    低级错误记录-程序更新后,没有显示想要的结果
    云编译的优点-普及云编译
    telecommunication communication 的区别
    学习EPC架构演进历史知识
    EOF与feof的区别
    epoll惊群问题-解决思路
    epoll多路复用机制的学习
    进程组与组长进程
    记录博客开始
  • 原文地址:https://www.cnblogs.com/zwei1121/p/3962744.html
Copyright © 2011-2022 走看看