Skip to content
This repository was archived by the owner on Dec 24, 2022. It is now read-only.

Commit 035157b

Browse files
committed
Use GetTableName API to resolve table name for DB
1 parent 276d93f commit 035157b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tests/ServiceStack.OrmLite.Tests/EnumTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -478,7 +478,7 @@ public void Can_query_EnumMembers_with_SqlFmt()
478478
var id = 1;
479479
db.Insert(new TypeWithEnumMember {Id = id, WorkflowType = WorkflowType.PurchaseInvoice});
480480
var result = db.Single<TypeWithEnumMember>(
481-
"select * from TypeWithEnumMember as db where db.Id = {0} and db.WorkflowType = {1}".SqlFmt(id, WorkflowType.PurchaseInvoice));
481+
"select * from " + db.GetTableName<TypeWithEnumMember>() + " as db where db.Id = {0} and db.WorkflowType = {1}".SqlFmt(id, WorkflowType.PurchaseInvoice));
482482
Assert.That(result.WorkflowType, Is.EqualTo(WorkflowType.PurchaseInvoice));
483483
}
484484
}

0 commit comments

Comments
 (0)