Skip to main content
Glama

generate_calendar_table_m

Create a calendar table in Power Query M with date, fiscal, and locale columns. Specify start/end dates and optional fiscal month/locale, then refresh.

Instructions

Generate a full date/calendar table as a new query: List.Dates over [startExpr..endExpr] with ~20 part columns (Year, Quarter, QuarterName, MonthNo, MonthName, MonthShort, YearMonthNo, YearMonth, ISOWeek, ISOYear, WeekdayNo, DayName, DayNo, DayOfYear, StartOfMonth, EndOfMonth, IsWeekend). startExpr/endExpr are RAW M, e.g. "#date(2020,1,1)" or a parameter reference. Pass fiscalYearEndMonth (1..12) to add FiscalYear/FiscalMonthNo/FiscalQuarter. Pass locale (e.g. en-NZ) to render month/day names in that culture. Refresh afterwards.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes
localeNolocale/culture for month/day names, e.g. en-NZ (optional)
endExprYesend date as raw M, e.g. #date(2025,12,31)
sessionIdYes
startExprYesstart date as raw M, e.g. #date(2020,1,1)
fiscalYearEndMonthNofiscal year-end month 1..12 (optional; adds fiscal columns)
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description discloses important behavioral traits: startExpr/endExpr must be raw M expressions, fiscal and locale parameters modify output columns, and a refresh is required afterward. With no annotations provided, it carries the burden well, though it doesn't state side effects like overwriting an existing query.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is dense but appropriately sized for the tool's complexity. Each sentence adds value: purpose, raw M requirement, optional fiscal, locale, and refresh. The column list is long but directly specifies the output.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no annotations and no output schema, the description covers the main functionality, parameter semantics, and post-conditions. It lacks explicit explanation of sessionId and name, but these are less critical for correct invocation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The description adds meaning beyond the schema for startExpr/endExpr (raw M format), fiscalYearEndMonth (adds specific columns), and locale (affects month/day names). It does not explain sessionId or name, but schema coverage is 67% and the description compensates for the key parameters.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool generates a full date/calendar table as a new query, with a specific verb and resource. It enumerates the exact columns produced, which distinguishes it from siblings like create_date_table and generate_445_calendar_m.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear context for when to use the tool: when a comprehensive calendar table with many part columns is needed, with optional fiscal and locale support. It does not explicitly name alternatives or exclusions, but the scope is well-defined.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/cyphonica/powerbi-pbix-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server