Find Method
public static _PropertyTable find(_PropertyId _propertyId, boolean _forUpdate = false)
{
_PropertyTable propertyTable = null;
propertyTable.selectForUpdate(_forUpdate);
if (_propertyId)
{
select firstonly propertyTable where propertyTable.PropertyId == _propertyId;
}
return propertyTable;
}
static _BuildingUnitDetailsDim findPropertyDescFlat(_PropertyId PropertyId,
Description Description,
_FlatNumber FlatNumber,
boolean _forUpdate = false)
{
_BuildingUnitDetailsDim BuildingUnitDetailsDim;
if (PropertyId)
{
BuildingUnitDetailsDim.selectForUpdate (_forUpdate);
BuildingUnitDetailsDim.selectLocked (_forUpdate);
select firstonly BuildingUnitDetailsDim
index hint PropertyIdx
where BuildingUnitDetailsDim.PropertyId == PropertyId &&
BuildingUnitDetailsDim.Description == Description &&
BuildingUnitDetailsDim.FlatNumber == FlatNumber;
}
return BuildingUnitDetailsDim;
}
{
_PropertyTable propertyTable = null;
propertyTable.selectForUpdate(_forUpdate);
if (_propertyId)
{
select firstonly propertyTable where propertyTable.PropertyId == _propertyId;
}
return propertyTable;
}
static _BuildingUnitDetailsDim findPropertyDescFlat(_PropertyId PropertyId,
Description Description,
_FlatNumber FlatNumber,
boolean _forUpdate = false)
{
_BuildingUnitDetailsDim BuildingUnitDetailsDim;
if (PropertyId)
{
BuildingUnitDetailsDim.selectForUpdate (_forUpdate);
BuildingUnitDetailsDim.selectLocked (_forUpdate);
select firstonly BuildingUnitDetailsDim
index hint PropertyIdx
where BuildingUnitDetailsDim.PropertyId == PropertyId &&
BuildingUnitDetailsDim.Description == Description &&
BuildingUnitDetailsDim.FlatNumber == FlatNumber;
}
return BuildingUnitDetailsDim;
}
Comments
Post a Comment