IData ApiMigrate(String, Object, Boolean) Method
Migrate an Data Object with a specified ID.
This method allows add or update a data object with a specified ID without using generated ID from system.
Note: if canUpdateIfExist = false then the method will throw exception the specified ID already exits in DB
Definition
Namespace: Casewhere.Runtime.DSL.Api
Assembly: Casewhere.Runtime (in Casewhere.Runtime.dll) Version: 2.9.8.6
Assembly: Casewhere.Runtime (in Casewhere.Runtime.dll) Version: 2.9.8.6
C#
[ObsoleteAttribute("Move to new Migrate(string id, object data, DslMigrationOption option) api")]
void Migrate(
string id,
Object data,
bool canUpdateIfExist = false
)Parameters
Example
C#
var dataApi = ctx.Use<IDataApi>();
dataApi.Migrate(orderId, new
{
Total = 20,
BillingAddress = "123 Sunset Blvd"
},
true);