Share via


PayrollBenefitDetail::findByTimeState Method

Finds a record in the PayrollBenefitDetail table, based on a record ID.

Syntax

client server public static PayrollBenefitDetail findByTimeState(
    PayrollBenefitDetailRecId _recId, 
   [ValidFromDate _validFrom, 
    ValidToDate _validTo, 
    boolean _forUpdate, 
    ConcurrencyModel _concurrencyModel])

Run On

Called

Parameters

  • _forUpdate
    Type: boolean
    A Boolean value that specifies whether to read the record for update; optional.
  • _concurrencyModel
    Type: ConcurrencyModel Enumeration
    An enumeration value that indicates whether a concurrency setting should be used on the table; optional.

Return Value

Type: PayrollBenefitDetail Table
A record from the PayrollBenefitDetail table. See the remarks.

Remarks

The _validFrom and _validTo values limit the table selection in the following ways:

  1. If no value is supplied for either parameter, the current date is used by default. Therefore, the method searches for only active records, and returns either an empty record or a valid record.

  2. If a value is supplied for only the first parameter, the same value is used for the second parameter by default. The method searches for active records as of the supplied date value, and returns either an empty record or a valid record.

  3. If values are supplied for both parameters, the method searches for records for which the validFrom and ValidTo values fall in that interval. The method returns either an empty record or a valid record.

Use the isActiveByTimeState API to check for the existence of a record.

This method tries to get the record and is an expensive operation.

See Also

Reference

PayrollBenefitDetail Table