Description: Returns the ISO calendar-week number after subtracting a plant-specific offset from the supplied timestamp.
Calling convention: WeekOfTheYearPlant(Date: DateTimeFormat, Plantoffset: DateTimeFormat): Integer
Parameters:
Date: Delphi-compatible date/time serial value.
Plantoffset: numeric day fraction subtracted from Date; for example 5/24 shifts the day boundary by five hours. NULL in either argument returns NULL.
Returns: Shifted calendar-week number in the range 1 through 53, or NULL.
Availability: Default.
Example:
Week := WeekOfTheYearPlant(GetSysDate(), 5 / 24);