Skip to content

Main content

Medication Record Date Gap Tool

Compare explicit deidentified record dates without inferring medicine use.

Loading tool…

Description

Return signed elapsed days between two medication-record dates.

Pharmacy administration distinguishes medicine and document identifiers, service records, stock balances and payment conventions from decisions about care. Literal labels and supplied status flags help reconcile records, while medicine identity, appropriate treatment and actual availability require independent verification.

Return signed elapsed days between two medication-record dates.

When to use this tool

Use Medication Record Date Gap when reconciling the stated pharmacy record, inventory, timing or financial convention.

How to use the tool and how it works

  1. Enter firstDate, secondDate. Use the units and conventions below.
  2. Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
  3. Read days. Use the output convention below.

Return signed elapsed days between two medication-record dates. Validate real Gregorian YYYY-MM-DD strings and divide their UTC-midnight difference by 86400000.1

Input fieldMeaning and unitsAccepted input
firstDateFirst DateRequired. Text; maximum UTF-16 length 8192. Real proleptic Gregorian YYYY-MM-DD; four-digit years 0000-9999 accepted.
secondDateSecond DateRequired. Text; maximum UTF-16 length 8192. Real proleptic Gregorian YYYY-MM-DD; four-digit years 0000-9999 accepted.
Output fieldInterpretationReturned shape
daysDaysRequired. Safe integer.
json
{
  "input": {
    "firstDate": "2024-02-28",
    "secondDate": "2024-03-01"
  },
  "output": {
    "days": 2
  }
}

Limitations and assumptions

  • The modern parser accepts four-digit years 0000-9999; no local-zone day length, clinical interval or expiry rule is selected.
  • Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.

Alternative or Complementary methods

Inspect verified medicine and service records and the applicable professional procedures; use appropriate clinical systems and qualified professional judgment for care or supply decisions.

References

  1. Calculation and input contract: clinical-pharmacy/medication-record-date-gap — tool.io

Similar or alternative tools