Function Problems

Display Dates and Retrieve Matching Values in Excel

Nimra MalikNimra Malik Nov 18, 2026 869 views

Question details

Display a date as a weekday and day number, and retrieve a related value from another worksheet using an exact match.

Display Dates and Retrieve Matching Values in Excel
Product
Microsoft Excel
Device & OS
not provided
Scenario
A worksheet contains dates to display and lookup values that correspond to information on another sheet.
Observed behavior
The desired result is a date display such as Wednesday-17 and a matching value returned from the other worksheet.
Before you start

Confirm that the date cell contains a valid Excel date and identify the lookup and result columns on the other worksheet. The example below uses Sheet2 column A for lookup values and column B for results.

Solution 1Recommended

Format the date and use INDEX and MATCH for the lookup

Use a custom date format or TEXT formula for the display, then return an exact-match value from another sheet.

1
Format the date cell

Select the date cell, such as A1, open Format Cells, and choose Custom. Enter dddd-dd as the format to display a date such as Wednesday-17 while retaining the underlying date value.

2
Use a formula for text instead

If you need the formatted result in a separate cell, enter =TEXT(A1,"dddd-dd"). This returns text rather than a date value.

3
Enter the lookup formula

In the cell where you want the related value, enter =INDEX(Sheet2!B:B,MATCH(E2,Sheet2!A:A,0)). Replace Sheet2 and the cell references with the names and ranges in your workbook.

4
Check the result

Compare E2 with the values in Sheet2 column A. MATCH uses 0 for an exact match, and INDEX returns the value from the corresponding row in column B.

Format the date and use INDEX and MATCH for the lookup
If no match is found: The formula returns #N/A when the lookup value is absent or does not match exactly. If multiple rows match, it returns the result for the first match.
Work with dates and lookups

Format dates and look up values in WPS Spreadsheets

Use WPS Spreadsheets to display dates with a custom format and retrieve corresponding values from another worksheet with INDEX and MATCH.

  1. 1. Open the workbook: Open WPS Spreadsheets and use Open to select your Excel workbook.
  2. 2. Format the date: Select the date cell, open Format Cells, choose Custom, and enter dddd-dd.
  3. 3. Add the lookup: In the result cell, enter =INDEX(Sheet2!B:B,MATCH(E2,Sheet2!A:A,0)), adjusting the sheet name and references to match your workbook.
  4. 4. Save the workbook: Check the displayed date and lookup result, then use File > Save or Save As to save the workbook.
Display weekday and day numbers without changing the underlying dateRetrieve exact-match values from another worksheetOpen and edit Microsoft Excel XLSX and XLS filesWork with a familiar spreadsheet interface
microsoft office alternative - wps office

Frequently Asked Questions

How do I display a weekday and day number without changing the date?

Select the date cell, open Format Cells, choose Custom, and enter dddd-dd. The underlying value remains a date.

What is the difference between TEXT and a custom date format?

The formula =TEXT(A1,"dddd-dd") returns text in a separate cell. A custom format changes only how the original date cell is displayed.

Why does my INDEX and MATCH formula return #N/A?

The lookup value may not exist in the lookup column or may differ in type or spacing. Compare E2 with the entries in Sheet2 column A and check that MATCH uses 0 for an exact match.

How do I reference a sheet name that contains spaces?

Enclose the sheet name in single quotes, as in =INDEX('Sales Data'!B:B,MATCH(E2,'Sales Data'!A:A,0)).