Reference: WQL Aliases
When you create Workday Query Language (WQL) queries, you use aliases to refer to:
- Data sources.
- Data source filters.
- Fields and calculated fields.
- Parameters (built-in prompts).
All Workday-delivered objects have a corresponding WQL alias. Workday creates aliases for calculated fields, whether Workday-delivered or not. You can edit aliases for calculated fields.
Retrieving Aliases by REST API Calls
You can return WQL aliases by calling the appropriate REST API endpoint.
Base URL:
https://{hostname}/api/wql/{version}/{tenant}
Base URL for Workday Extend:
https://api.workday.com/wql/{version}
Alias | REST API Endpoint |
|---|---|
All data sources. | GET {baseURL}/dataSources
|
Single data source. | GET {baseURL}/dataSources/{WorkdayID}
|
All data source filters and associated prompts. | GET {baseURL}/dataSources/{WorkdayID}/dataSourceFilters
|
Single data source filter and associated prompts. | GET {baseURL}/dataSources/{WorkdayID}/dataSourceFilters/{WorkdayID}
|
Fields and calculated fields. | GET {baseURL}/dataSources/{WorkdayID}/fields
|
Retrieving Aliases in Workday
To retrieve aliases, you can:
- Create a custom report on theData SourcesorFieldsreport data source using theWQL Aliasreport field. The report returns the WQL alias only for data sources that Workday has enabled for reporting.
- View WQL aliases for fields, calculated fields, or data sources from the related actions menu.
To ensure the aliases you specify in your query are correct:
- Call theGET /dataSourcesendpoint to determine the ID (also known as the Workday ID, or WID) for your datasource. Use thealiasquery parameter to filter the list of data sources.
- Call theGET /dataSources/{ID}endpoint to view the details of your data source using the WID from theGET /dataSourcescall.The GET /dataSources/{ID}endpoint returns the correct aliases to use in your query.