Last active
January 31, 2018 18:04
-
-
Save FNogger/2e1b6d1602831a7c924dd1778ed5fbe3 to your computer and use it in GitHub Desktop.
Find
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// <summary> | |
/// Finds the specified record in the <c>CarTable</c> table. | |
/// </summary> | |
/// <param name="_carId"> | |
/// The CarId of the <c>CarTable</c> record to find. | |
/// </param> | |
/// <param name="_forupdate"> | |
/// A Boolean value that indicates whether to read the record for update; optional. | |
/// </param> | |
/// <param name="_concurrencyModel"> | |
/// The table selection ConcurrencyModel; optional. | |
/// </param> | |
/// <returns> | |
/// A record in the <c>CarTable</c> table; otherwise, an empty record. | |
/// </returns> | |
// Begin : Axaptahut, DevTools | |
public static CarTable find(AccountNum _carId, boolean _forupdate = false, | |
ConcurrencyModel _concurrencyModel = ConcurrencyModel::Auto) | |
{ | |
CarTable carTable; | |
carTable.selectForUpdate(_forupdate); | |
if (_forupdate && _concurrencyModel != ConcurrencyModel::Auto) | |
{ | |
carTable.concurrencyModel(_concurrencyModel); | |
} | |
select firstonly carTable | |
where carTable.CarId == _carId; | |
return carTable; | |
} | |
// End: Axaptahut, DevTools |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment