Trading calendars are foundational infrastructure in financial markets. They enable traders, quantitative analysts, and institutions to accurately track market operating hours, plan execution strategies, and calculate critical metrics such as cashflows, accrual periods, and holding durations.
DolphinDB provides built-in trading calendars for nearly 60 major exchanges worldwide, with full customization capabilities to address granular or scenario-specific business requirements.
As we approach 2026, DolphinDB's annual trading calendar update is now available—featuring a significant enhancement for fixed income, currency, and commodities (FICC) practitioners.
Introducing the China Foreign Exchange Trade System (CFET) Calendar
DolphinDB supports calendar definitions via explicit trading date lists using the dateType="tradingDate" parameter. This approach elegantly handles complex scenarios such as weekend trading sessions or irregular market closures that deviate from conventional "weekends off" assumptions.
The CFET calendar is critical for FICC operations. Functions including bond accrued interest calculations, cashflow scheduling, and settlement date determination all depend on accurate trading calendar data.
Unlike equity or futures exchanges, China's interbank market operates on a distinct schedule. Weekend sessions may be designated as trading days, and CFET publishes explicit trading date lists rather than holiday exclusions. Consequently, the CFET calendar utilizes dateType="tradingDate", meaning the calendar file contains the complete list of trading days while non-trading days are automatically inferred.
Creating custom calendars with weekend sessions or special arrangements is straightforward:
// Example: assume several weekend sessions in 2026
tradingDates = [2026.04.04, 2026.04.05, 2026.04.11, 2026.04.12]
addMarketHoliday(marketName="FICC", holiday=tradingDates, dateType=`tradingDate)
getMarketCalendar("FICC")
// Output: 2026.04.04 2026.04.05 2026.04.11 2026.04.12Updating Your 2026 Trading Calendar
DolphinDB offers two update methods—offline and online—to accommodate different operational requirements and ensure smooth production system upgrades.
Method 1: Offline Update (Recommended for Production Environments)
- Visit the DolphinDB MarketHoliday module repository: https://github.com/dolphindb/DolphinDBModules/tree/master/MarketHoliday/marketHoliday
- Download the latest marketHoliday folder
- Replace the existing marketHoliday folder located at <DolphinDB>/server
- For cluster deployments: Repeat the replacement on every physical node
- Restart the cluster
This approach ensures maximum consistency across your infrastructure and is strongly recommended for mission-critical deployments.
Method 2: Online Update
- Download the latest
marketHolidaymarketHoliday folder - Place it in another directory on the same server, e.g.: /path/newMarketHoliday (Do NOT overwrite the original folder)
- Run the following script in DolphinDB:
def update_2026_holiday(market_code, old_holiday_dir, new_holiday_dir){
old_holiday_files = exec filename.strReplace(".csv","") from files(old_holiday_dir)
new_holiday_files = exec filename.strReplace(".csv","") from files(new_holiday_dir)
if (!(market_code in new_holiday_files)){
return "There is no market holiday file of the exchange."
}
this_holiday = loadText(new_holiday_dir+'/'+market_code+".csv")
if (market_code in old_holiday_files){
updateMarketHoliday(market_code,this_holiday.col(0))
}
else{
getMarketType = extractTextSchema(new_holiday_dir+'/'+market_code+".csv").name[0]
addMarketHoliday(market_code, this_holiday.col(0),getMarketType)
}
}
market_code = "CFET"
old_holiday_dir = "<dolphindb>/server/marketHoliday"
new_holiday_dir = "<dolphindb>/server/newMarketHoliday"
update_2026_holiday(market_code, old_holiday_dir, new_holiday_dir)For cluster deployments, run:
pnodeRun(update_2026_holiday, market_code, old_holiday_dir, new_holiday_dir)Note: While online updates offer convenience, they may introduce brief inconsistencies under heavy load. Offline updates remain the preferred approach for critical production systems.
Verifying Your Update
Confirm the new calendar is functioning correctly with these validation checks:
// CFET: Verify January 1 is NOT a trading day (expected: false)
2026.01.01 in getMarketCalendar("CFET", 2026.01.01, 2026.01.31)
// XSHG: Verify January 1 is not a trading day
2026.01.01 in getMarketCalendar("XSHG", 2026.01.01, 2026.01.31)
// CFET: Verify January 5 IS a trading day (expected: true)
2026.01.05 in getMarketCalendar("CFET", 2026.01.01, 2026.01.31)Looking Ahead
The 2026 trading calendar update strengthens DolphinDB's global market coverage while deepening support for real-world financial operations. The newly integrated CFET calendar is particularly valuable for the rapidly expanding FICC sector, enabling precise temporal standards for bond valuation, risk management, and derivatives settlement.
Updating your calendar ensures your research pipelines, trading infrastructure, and analytics systems remain fully synchronized with 2026 market schedules.
Prepare your DolphinDB environment for the year ahead and power your financial computations with the industry's most accurate temporal foundation.