Dapper Rainbow - How to specify table name in another schema

dapper dapper-rainbow

Question

I am pretty new to Dapper Rainbow so I may be missing something obvious. Is it possible to specify the table name and if so how?

I have tried the following with no luck.

public class DashboardContext : Database<DashboardContext>
{
    public DashboardContext()
    {
       this.DashboardResults = new Table<DashboardResult>(this, "Monitor.DashboardResult");
    }

    public Table<DashboardResult> DashboardResults { get; set; }
}

Popular Answer

I had the same problem but it seems an error in the code. I´ve just commented the lines where is setting the constructor for tables (Database.cs) and it works.

    internal void InitDatabase(DbConnection connection, int commandTimeout)
    {
        this.connection = connection;
        //this.commandTimeout = commandTimeout;
        //if (tableConstructor == null)
        //{
        //    tableConstructor = CreateTableConstructorForTable();
        //}

        //tableConstructor(this as TDatabase);
    }

I guess this is not the best solution...




Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow
Is this KB legal? Yes, learn why
Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow
Is this KB legal? Yes, learn why