PersonUpdateSQL Method

Builds the SQL script for any value changes.

Definition

Namespace: Common.Core.Models
Assembly: Common.Core (in Common.Core.dll) Version: 2.1.5
C#
public static string UpdateSQL(
	DataRow row,
	IPerson obj,
	IPerson mod,
	string addPrefix = ""
)

Parameters

row  DataRow
Database row containing the current Person data.
obj  IPerson
IPerson object containing the original values.
mod  IPerson
IPerson object containing the modified values.
addPrefix  String  (Optional)
Table column name prefix for Address fields (if required).

Return Value

String
An empty string is returned if no changes were found.

Remarks

This method assumes that the table column names are the same as the property names.

See Also