Hijri Date Adjustment in Oracle

From SmartHCM Wiki
Jump to navigation Jump to search

Since Hijri calendar is based on the moon complete revolution around the sun, Hijri calendar has different number of days in a year than Gregorian. Therefore some manual deviation adjustment might be needed for the conversion to/from Gregorian. In other words Hijri calendar is Lunar based, corrections need to be made every so often.

Perform the following steps to adjust the Hijri date:

  • 1. Copy the "lxecal.nlt" file into Oracle_home\nls (you can adjust the file as per your need)
  • 2. Shutdown the database (SQL>shutdown immediate)
  • 3. execute the lxgen.exe command from "Oracle_home\bin"
  • 4. Start the database

Notes: * Gregorian date specified in the deviation should correspond to one of 29th, 30th or 31th days of the Hijri calendar.

  • Numbers greater than 10 are used to subtract days, e.g: 11 --> subtract one day, 12 --> subtract two days and etc.