Setting Job Dates and Receiving Samples

Overview

Sample receiving is the process of marking a job or samples as received by the laboratory, that is, the samples' paperwork has arrived at the laboratory.

Once the job and samples are registered (or pre-registered), an important task is to ensure that the sample list matches the samples registered for the job.

Some laboratories do not mark a job or sample as received until the samples are physically received by the laboratory, and only at that point, are jobs and samples manually marked as received.

Process

  • A job's Received On date-time is when the job's paperwork and samples are received by the laboratory. Often jobs are registered ahead of time, so the Received On date denotes the point in time at which the job's registration is ready for last-minute adjustments, for example, sample gridding, prior to analysis.
  • A job's Required On date-time is when a certificate containing the results for the job is required by the job's stakeholders.
  • A job's Priority and Received On date-time, and any holidays defined for the laboratory, are used to determine the job's Required On date.
  • A job's Possible On date-time should ideally be the possible date-time by which the job's certificate report can be generated, based on the longest duration of job analysis, however, currently this is set in the same way as the Required On date-time.
  • A job's Agreed On date-time is when it is agreed with the client that the certificate report is available. Agreed Date defaults to Required On, but is updatable.
  • A sample's Received On date-time is when the sample is received by the laboratory, and is inherited from the job, but may be updated.
  • A sample's Required On date-time is when a certificate containing the results for the sample is required by the job's stakeholders, and is inherited from the job, but may be updated.
  • A sample's Priority is inherited from the job, but if updated then the new Priority and Received On date-time, and any holidays defined for the laboratory, are used to determine the sample's Required On date.
  • A sample's Possible On date-time is inherited from the job.
  • A sample's Agreed On date-time is when it is agreed with the client that the certificate report is available, and is inherited from the job, but may be updated.
  • Working days of the week are those days in which the laboratory is operating, and is defined by the WORKING_DAYS_OF_WEEK application preference that contains a seven-character string of y and n characters, representing Monday through to Sunday that indicate the days of the week which are regular working days, and a Y or a N to represent the starting day of the week. Where the preference is not defined, inactive, or empty, then Yyyyynn is used as a default.
  • A holiday is a day in which the laboratory is not operating, and is defined using the CCHLDY—Holiday application.

Defaulting Job Received Date and Priority

When a job is created from scratch, then:

  • Where the AUTO_RECEIVE_JOBS application preference is enabled, then the job's Received On date-time is set to the laboratory's current date-time, and the job's Received By is set to the current user. For each sample registered with the job, the sample's Received On and Received By is inherited from the job. For a new job, if the job received date is updated from CCREGN - Job Update, then all the underlying samples will get updated with the same date when the samples are expanded.
  • A job's Priority defaults in this order: from the project if the job links to a project and the project has a priority defined, from the client if the client has a priority defined, or from the DEFAULT_PRIORITY application preference, and if not defined there, then defaults to 5D (days).

When a job is created by copying another job, then the job's Received On defaults the same as a job created from scratch, but the job's Priority is inherited from the source job.

When a job is created from a job template, then the job's Received On date is dependent on the value of Auto-receive Job? checkbox. If checked, then when a job is created from the template, the received on date-time is set to the laboratory's current date-time.

Calculation of the Job's Required Date

The date on which a job is received, the job's priority, working days of the week for the laboratory, and holidays determine when a job is required.

  • A job's Required Date is set to the job's Received Date plus the job's Priority unit, with the overriding condition that for each day in-between Received On and Required On, when a laboratory holiday falls on a non-working day, then the holiday's Adjustment determines the new non-working day (instead of the holiday), and new non-working day is incorporated in the calculation of the Required On date-time, as follows:
    • If the day is NOT a working day according to the preference then add one day to the Required On date-time.
    • If the day IS a working day according to the preference, and the holiday's Holiday Type is OnceOff, or the holiday's Holiday Type is Repeat and DAYMONT(Day) = DAYMONT(Holiday) and the holiday's Adjustment is None, then ADD one day to the Required On date-time.
    • If the day is NOT a working day according to the preference and the holiday's Holiday Type is OnceOff, or the holiday's Holiday Type is Repeat and DAYMONT(Day) = DAYMONT(Holiday) and the holiday's Adjustment is None, then DO NOT add one day to the Required On date-time.
    • If the day is NOT a working day according to the preference and the holiday's Holiday Type is OnceOff, or the holiday's Holiday Type is Repeat and DAYMONT(Day) = DAYMONT(Holiday) and the holiday's Adjustment is Forward or Backward, then add one day to the Required On date-time.

Examples:

  1. No priority is defined in the DEFAULT_PRIORITY application preference, nor on the client nor project—The priority is taken from the system default of 5D (days).
  2. A priority is only defined in the DEFAULT_PRIORITY application preference—The priority is taken from the preference.
  3. A priority is defined on the client only—The priority is taken from the client.
  4. A priority is defined on the client and project only—The priority is taken from the project.
  5. A priority is defined defined in the DEFAULT_PRIORITY application preference and on the client and on the project—The priority is taken from project.
  6. A priority is defined in the DEFAULT_PRIORITY application preference and on the project only—The priority is taken from the project.
  7. A priority is defined in the DEFAULT_PRIORITY application preference and on the client only—The priority is taken from the client.
  8. Where a single holiday is defined and the WORKING_DAYS_OF_WEEK application preference is defined and all days are working days, then the date calculation skips over the holiday.
  9. Where multiple holidays are defined and the WORKING_DAYS_OF_WEEK application preference is defined and all days are working days, then the date calculation skips over each holiday.
  10. Where the WORKING_DAYS_OF_WEEK application preference is not defined, then the date calculation uses the system default of Yyyyynn (Monday is the first day of the week, and Saturday and Sunday are non-working days).
  11. Where the WORKING_DAYS_OF_WEEK application preference is defined and no holidays are defined, then the date calculation skips over the non-working days.
  12. Where the WORKING_DAYS_OF_WEEK application preference is defined and holidays are defined, then the date calculation skips over any day that is a non-working day and/or a holiday.

Modify Job Received Date from Mark Received Service

This refers to the Mark Received service from the CCREGN - Search Job found in the bottom part of the grid. This service is designed for empty values for the job received on date field. This happens if the application preference AUTO_RECEIVE_JOBS is turned off or the field value is removed on purpose.

  • If the job's Received On date value is empty, and the user clicks Mark Received from the job search, then the job's Received On date and Received By is set to the current laboratory's date-time and user. This value is then persisted to all the current samples in the job. If the job's received date is already populated with a value, and the user clicks the Mark Received service, then it will not update the existing date and user. Instead, it will return a message that the job has already been received.
  • Other dates for the job are updated, as outlined in the sections below.

See the procedure below to mark jobs from the job search with a received date.

Mark jobs as received

Modify Sample Received Date from Mark Received Service

For each sample in a job that is marked as received, where the sample's Received On date is not already set, then the sample's Received On date and Received By is set to the current laboratory's date-time and user.

See the procedure below to mark samples as received from the sample grid flow.

Mark samples as received

Flow on effect of marking samples as received:

  • Each related sample scheme's Expiry Date and sample scheme analyte's Expiry Date is recalculated. When the Received Date is updated for a production sample and the production sample scheme does not have a precursor sample scheme, the sample scheme is included in a laboratory batch, and the production sample scheme's Holding Time is set, then the laboratory batch sample scheme's Expiry Date is calculated by the holding time engine. Refer to Conditions for Calculating Expiry and Warning Dates and Using Sample Expiry.

    Example: A production job contains S2Ana5 and S2Ana6, and S2Ana5 is the precursor sample scheme of S2Ana6. If S2Ana5 and S2Ana6 are included in the same laboratory batch job, then in the laboratory batch job, LB_S2_Ana5 is the precursor sample scheme of LB_S2_Ana6. In this case, an update to S2's Received Date would recalculate S2Ana5's Holding Time and LB_S2Ana5's Holding Time.

Changing a Job's Priority and Dates

Note: A job's Priority is mandatory and must be entered in the format xN, where x is an integer and N is a code for a date-time period: S (second), N (minute), H (hour), D (day), M (month), Y (year). For example, 10D (10 days), 30N (30 minutes).

When a job's Priority is updated, then:

  • The job's Received Date remains unchanged.
  • The job's Required Date is set as per the calculation outlined above.
  • The job's Possible Date is set to the calculated job's Required Date.
  • The job's Agreed Date is set to the calculated job's Required Date.
  • These priority and dates at the sample, sample scheme, sample scheme analyte, job scheme and job scheme analyte remain unchanged.

When a job's Priority is cleared, then:

  • The job's Received Date remains unchanged.
  • The job's Required Date is cleared.
  • The job's Possible Date is cleared.
  • The job's Agreed Date is cleared.
  • These priority and dates at the sample, sample scheme, sample scheme analyte, job scheme and job scheme analyte remain unchanged.

When a job's Received Date is updated, then the job's Received By is set to the current user, and:

  • The job's Priority remains unchanged.
  • The job's Required Date is set as per the calculation outlined above.
  • The job's Possible Date is set to the job's Required Date, as calculated.
  • The job's Agreed Date is set to the job's Required Date, as calculated.
  • These dates at the sample, sample scheme, sample scheme analyte, job scheme and job scheme analyte remain unchanged.

Note: The job's Received Date cannot be set later than the job's Required Date.

When a job's Received Date is cleared, then:

  • The job's Priority remains unchanged.
  • The job's Required Date is cleared.
  • The job's Possible Date is cleared.
  • The job's Agreed Date is cleared.
  • These dates at the sample, sample scheme, sample scheme analyte, job scheme and job scheme analyte remain unchanged.

When a job's Required Date is updated, then it is not recalculated on submit, and:

  • The job's Priority remains unchanged.
  • The job's Received Date remains unchanged.
  • The job's Possible Date is set to the job's Required Date, as updated.
  • The job's Agreed Date is set to the job's Required Date, as updated.
  • These dates at the sample, sample scheme, sample scheme analyte, job scheme and job scheme analyte remain unchanged.

Note: The job's Required Date cannot be set earlier than the job's Received Date.

When a job's Required Date is cleared, then it is not recalculated on submit, and:

  • The job's Priority remains unchanged.
  • The job's Received Date remain unchanged.
  • The job's Possible Date is cleared.
  • The job's Agreed Date is cleared.
  • These dates at the sample, sample scheme, sample scheme analyte, job scheme and job scheme analyte remain unchanged.

When a job's Possible Date is updated, then it is not recalculated on submit, and:

  • The job's Priority remains unchanged.
  • The job's Received Date remains unchanged.
  • The job's Required Date remains unchanged.
  • The job's Agreed Date remains unchanged.
  • These dates at the sample, sample scheme, sample scheme analyte, job scheme and job scheme analyte remain unchanged.

Note: The job's Possible Date cannot be set earlier than the job's Received Date.

When a job's Possible Date is cleared, then it is not recalculated on submit, and:

  • The job's Priority remains unchanged.
  • The job's Received Date remain unchanged.
  • The job's Required Date remains unchanged.
  • The job's Agreed Date remains unchanged.
  • These dates at the sample, sample scheme, sample scheme analyte, job scheme and job scheme analyte remain unchanged.

When a job's Agreed Date is updated, then it is not recalculated on submit, and:

  • The job's Priority remains unchanged.
  • The job's Received Date remains unchanged.
  • The job's Required Date remains unchanged.
  • The job's Possible Date remains unchanged.
  • These dates at the sample, sample scheme, sample scheme analyte, job scheme and job scheme analyte remain unchanged.

Note: The job's Agreed Date cannot be set earlier than the job's Received Date.

When a job's Agreed Date is cleared, then it is not recalculated on submit, and:

  • The job's Priority remains unchanged.
  • The job's Received Date remain unchanged.
  • The job's Required Date remains unchanged.
  • The job's Possible Date remains unchanged.
  • These dates at the sample, sample scheme, sample scheme analyte, job scheme and job scheme analyte remain unchanged.

Update job priority, received, required or agreed date

Gridding Samples On and Off for Analysis

Samples are gridded on and off for analysis by marking them as listed not received, insufficient sample, not analysed or no result, or reset to be analysed using the CCSGRD—Sample Grid application.

The SAMPLE_GRIDDING_ANALYTE_HDR_FIELD, SAMPLE_GRIDDING_SCHEME_HDR_FIELD application preferences set the sample grid header. The CCPREF—Preferences application is used to set preferences, accessed using the System Setup » Laboratories and Application Setup » Application Preferences menu option.

Only sample scheme analytes where the sample has a Workflow Status of Not Started can be set to Listed Not Received.

When sample scheme analytes have their Workflow Status set to Insufficient Sample, Not Analysed or No Result, then existing results are retained so that a reset is applied, then the result is still available and the Workflow Status reverts to Analysed instead of to Not Started.