The OData adaptors connect IFS OI Server to services that publish data through the OData protocol, such as IFS Cloud, EnergySys and many other business systems. The OData Time Series Adaptor provides tag data for trends. The Generic OData Adaptor provides datasets.
Overview
OData is a standard way of publishing tables of data over the web. Each table (an entity set) has an address, and the service accepts query options in the URL, such as $filter, $select and $orderby. There are two OData adaptors:
| Adaptor | Use it for | How it is configured |
| OData Time Series Adaptor | Tag data: readings for named tags over time, shown in trends and anywhere Explorer reads tag history | On the datasource: which table holds the readings, and which columns hold the name, timestamp and values |
| Generic OData Adaptor | Datasets: tables of rows and columns | On each dataset: the query is the OData URL to call |
Both adaptors share the same authentication options and are read-only. If the service returns JSON but is not an OData service, use the Generic REST adaptors instead.
What's New
| Change | Description |
| OData Time Series Adaptor | New adaptor that reads tag data from OData tables in either wide or narrow layout, with tag browsing and batched requests. Included in the main and Remote Data Host installers. |
| OData v4 support | Both adaptors follow the OData v4 standard: v4 date formats in filters, OData-Version headers, and clearer error messages that include the service's own error code and text. The Time Series adaptor still supports v1 to v3 services. |
| Computed columns | Dataset queries can build a column from other columns with concat(...) as Name, for example to produce a column that matches entity names. See Computed Columns. |
| Navigation paths | The Time Series adaptor's Table Name can be a navigation path such as Plants('P1')/Readings. |
| Token renewal | With OAuth 2.0, if the service rejects a token that has been revoked, the adaptor gets a new token and retries once. |
Service Requirements
The OData service must support:
- The query options $filter (with eq, ge, le, and and or), $orderby, $top, $skip and $select.
- $batch requests, for the Time Series adaptor. Tag data is requested in batches.
- JSON or Atom/XML responses. The adaptors handle both.
Before configuring a datasource, open a table's URL in a browser (for example https://server/odata/WellDaily?$top=5) to check the column names, their capitalization and the date format. Column names in OData are case-sensitive.
Authentication
Both adaptors have the same authentication settings. The following table lists them along with the name and type to be used in the Import/Export spreadsheet.
| Parameter | Description and example | Name | Type |
| Authentication | How to sign in to the service. Options: None, Secure Login (default), OAuth 2.0, Certificate. In the Import/Export spreadsheet use the values None, Login, OAuth2 or Certificate. | Authentication | String |
| UserName / User name | User name. Required for Secure Login. With OAuth 2.0, optional (see below). | Username (Time Series) UserName (Dataset) |
String |
| Password | Password. Required for Secure Login. With OAuth 2.0, optional (see below). | Password | EncryptedString |
| OAuth2 Client ID | Client ID. Required for OAuth 2.0. | Client Id | String |
| OAuth2 Client Secret | Client secret. Required for OAuth 2.0. | Client Secret | EncryptedString |
| OAuth2 TokenURI | Address of the token endpoint. Required for OAuth 2.0. Example: https://login.example.com/oauth2/token | TokenURI | String |
| Certificate Thumbprint | Thumbprint of the client certificate. Required for Certificate authentication. Enter it exactly as Windows shows it, in capitals, without spaces. | Certificate Thumbprint | String |
| Certificate Verification Endpoint | An address the adaptor calls with the certificate to check that it is accepted. Required for Certificate authentication. | Verification Endpoint | String |
- Secure Login sends the user name and password with each request. Both are required. If the service needs no sign-in, choose None.
- OAuth 2.0 gets a token from the token endpoint using the client ID and secret (the client-credentials grant). If a user name and password are also filled in, the adaptor signs in as that user instead (the password grant). Tokens are renewed a minute before they expire.
- Certificate uses a client certificate from the Local Machine's Personal certificate store on the server that runs the adaptor. The account the adaptor runs under must be able to read the certificate's private key.
OData Time Series Adaptor
The OData Time Series Adaptor reads tag data from an OData table that holds timestamped readings. The table can be wide or narrow.
Time Series Adaptor Settings
In addition to the authentication settings:
| Parameter | Description and example | Name | Type |
| BaseURI | Required. The address of the OData service. Example: https://server.example.com/odata | BaseURI | String |
| OdataServerVersion | The OData version of the service: v1, v2 (default), v3 or v4. This controls the date format used in filters. Check the service's $metadata document if you are not sure. | Odata Server Version | String |
| Table Name | Required. The entity set that holds the readings. Can be a navigation path. Examples: WellDaily, Plants('P1')/Readings | TableName | String |
| WideMode | Selected (default): the table is wide, with one column per measurement. Cleared: the table is narrow, with one row per tag reading. | WideMode | Boolean |
| Name Field | Required. The column that holds the entity name (wide mode) or the tag name (narrow mode). Example: NAME | NameField | String |
| Timestamp Field | Required. The column that holds the reading's date and time. Example: PRODUCTION_DATE | TimeStampField | String |
| Value Column(s) | The columns that hold readings, separated by commas. In wide mode, list each measurement column, for example GAS_VOL,OIL_VOL,CHOKE. In narrow mode, give the single value column, for example VALUE. Readings are only read from the columns listed here. | Columns | String |
| Confidence Column Name | Optional. A column that holds the reading's confidence, from 0 to 100. If blank, readings have a confidence of 100. | Confidence | String |
| Entity Attribute Delimiter | Wide mode only. The characters that join the entity name and the column name to form a tag name. Default: . (so Well 1 and GAS_VOL make the tag Well 1.GAS_VOL). | Entity Attribute Delimiter | String |
| Additional Filters | Optional. A filter added to every data request with and. Use it when the service needs a fixed condition. Example: Site eq '2401'. Not applied when browsing for tags. | Additional Filters | String |
| Batch Size | Required. How many entities (wide mode) or tags (narrow mode) to request together. Default: 50. Lower it if requests are too long for the service. | Batch Size | Integer |
| Tag Discovery Table Name | Optional. A table that lists the available tags. If blank, tags are found by scanning recent readings. See Tag Browsing. | Tag Discovery TableName | String |
| Tag Discovery Column Names | Required if Tag Discovery Table Name is set. Five column names, separated by commas, in this order: tag name, description, units, minimum, maximum. Leave a position empty if the table has no such column, for example TAGNAME,,,MIN,MAX. Default: TAGNAME,DESCRIPTION,UNITS,MINIMUM,MAXIMUM. | Tag Discovery Columns | String |
| Scan Days | Required. Used only when Tag Discovery Table Name is blank: how many days of readings to scan when browsing for tags. Default: 5. If every entity reports daily, 1 is enough. | ScanDays | Integer |
Wide and Narrow Tables
Wide tables have one row per entity per time, with a column for each measurement. Each measurement column becomes a tag, named entity + delimiter + column.
| NAME | PRODUCTION_DATE | GAS_VOL | OIL_VOL |
| Well 1 | 2026-09-01 | 1520.4 | 310.2 |
| Well 2 | 2026-09-01 | 980.0 | 122.7 |
With Name Field NAME, Timestamp Field PRODUCTION_DATE and Value Column(s) GAS_VOL,OIL_VOL, this table provides the tags Well 1.GAS_VOL, Well 1.OIL_VOL, Well 2.GAS_VOL and Well 2.OIL_VOL.
Narrow tables have one row per tag per time. Clear WideMode. The Name Field holds the tag name and Value Column(s) is the single value column.
| TAGNAME | TIMESTAMP | VALUE | QUALITY |
| TIC-101 | 2026-09-01T08:00:00Z | 72.5 | 100 |
| FIC-200 | 2026-09-01T08:00:00Z | 50.1 | 90 |
With Name Field TAGNAME, Timestamp Field TIMESTAMP, Value Column(s) VALUE and Confidence Column Name QUALITY, this table provides the tags TIC-101 and FIC-200.
How Tag Data Is Fetched
- Over a time range, the adaptor asks for rows whose timestamp is between the start and end times, for the requested entities, in batches of Batch Size. In wide mode it uses $select to fetch only the needed columns.
- At a single time, OData cannot ask for "the latest row for each entity", so the adaptor asks for the most recent rows up to that time and then asks again for any entity it didn't get a value for.
- If a time range has no data for a tag, the adaptor fetches the last known value before the range and uses it.
- If a value column doesn't exist, the service rejects the whole request. The adaptor marks the tags that use that column with an error, then repeats the request without it so that the other tags still return data.
- An entity that doesn't exist returns no data rather than an error, because OData can't tell the difference between an unknown entity and one with no readings.
Readings can be numbers, text or true/false. Text that looks like a number is read as a number. If any reading for a tag is non-numeric text, all of that tag's readings are returned as text.
Time Zones
Request times are converted to the datasource's time zone before they are sent.
- v1 to v3: times are sent as datetime'2026-09-01T08:00:00', with no time zone. Set the datasource's time zone to the zone the service stores its times in.
- v4: times are sent as 2026-09-01T08:00:00Z, which means UTC. Set the datasource's time zone to UTC; otherwise local times are sent labeled as UTC and readings will be shifted.
Tag Browsing
When a user browses for tags, the adaptor finds them in one of two ways.
With a tag list table (Tag Discovery Table Name is set): the adaptor reads the table, sorted by the tag name column, in pages of ten times the Batch Size. The description, units, minimum and maximum come from the columns given in Tag Discovery Column Names.
Without a tag list table: the adaptor reads all readings from the last Scan Days and lists each entity and value column it finds. Minimum and maximum are set from the values seen, the description is name OData tag, and units are tbd. This can be slow for large tables; a tag list table is recommended when there are many tags. Additional Filters are not applied while scanning.
Generic OData Adaptor (Datasets)
The Generic OData Adaptor returns a dataset from an OData query. The datasource holds the service address and authentication. Each dataset's query is the rest of the URL: the entity set and any query options.
Dataset Adaptor Settings
In addition to the authentication settings:
| Parameter | Description and example | Name | Type |
| Base URL | Required. The address of the OData service. The dataset query is added to it; a / between them is added automatically if needed. Example: https://server.example.com/main/ifsapplications/projection/v1/ActiveSeparateHandling.svc | BaseUrl | String |
The Generic OData Adaptor always uses OData v4.
Writing a Dataset Query
The query is the entity set name followed by OData query options:
Products?$select=ProductID,ProductName,UnitPrice&$filter=UnitPrice gt 20&$orderby=ProductName
Each property returned becomes a column. The column type follows the OData type: numbers, text, true/false, dates and durations. Other details:
- Structured (complex) properties are split into one column per field, named Property - Field, for example Address - City.
- Dates without a time zone (OData DateTime, used by older services) are treated as UTC. DateTimeOffset values keep their own offset.
- GUIDs and binary values are returned as text.
Dataset Query Keywords
OData datasets use their own keywords. These replace the SQL keywords PARAM() and SORTBY() and produce values in OData format. Keywords that take a parameter add it to the dataset's options in Explorer. Keyword names are not case-sensitive.
| Keyword | Usage | Description |
| ODataParam | ODATAPARAM(name,data_type,odata_type) Example: ODATAPARAM(site,string,String) becomes '2401' |
A single value supplied in Explorer, written in the OData format for odata_type. name: the parameter name shown in Explorer. Case-sensitive, no spaces. data_type: the Explorer parameter type, for example string, integer, decimal, boolean, datetime or duration. odata_type: the OData type of the property being compared. See the table below. |
| ODataUserParam | ODATAUSERPARAM(name,data_type,odata_type) | The same as ODATAPARAM, but the value comes from a user parameter supplied at run time by the page, not from the dataset's configured parameters. It doesn't appear as a dataset option. |
| ODataSortBy | ODATASORTBY(column [asc|desc][,…]) Example: ODATASORTBY(ProductName desc) becomes &$orderby=ProductName desc |
Sorts the results. Adds an optional ODataSortBy option to the dataset so that the sort can be changed in Explorer. Because it adds &, the query must already contain a ?. |
| ODataUserParamSortBy | ODATAUSERPARAMSORTBY(column [asc|desc]) | The same as ODATASORTBY, but the sort can be overridden by a user parameter supplied at run time by the page. |
OData Types for ODATAPARAM
The odata_type argument controls how the value is written. Older OData versions wrap some values with a type prefix or suffix. OData v4 services, including the Generic OData Adaptor's, expect the plain form, so use the types marked Yes in the last column.
| odata_type | Explorer value | Written as | OData v4 |
| String | string | 'Well 1' | Yes |
| Boolean | boolean | true | Yes |
| Int32, Int16, Byte, SByte | integer, or a whole decimal | 42 | Yes |
| Date | datetime | 2026-09-01 | Yes |
| Int64 | integer, or a whole decimal | 42L | No |
| Decimal | integer or decimal | 1.5M | No |
| Double | integer or decimal | 1.50000000000000000e+000d | No |
| Single | integer or decimal | 1.500000000e+000f | No |
| DateTime | datetime | datetime'2026-09-01T08:00:00' | No |
| DateTimeOffset | datetime | datetimeoffset'2026-09-01T08:00:00Z' | No |
| TimeOfDay | datetime | time'08:00:00' | No |
| Duration | duration | duration'P0DT01H30M00S' | No |
| Guid | string | guid'…' | No |
An empty value is written as null. A text value containing a single quote is not escaped, so avoid quotes in string parameters.
Computed Columns
A dataset query can create a column by joining other columns and fixed text. Write concat(…) as Name inside $select:
ActiveSeparateSet?$filter=Objsite eq '2401'&$select=concat(MchCode, ' - ', EquipmentObjectSeq) as Entity,WoNo,RegDate,ErrDescr
This returns a column called Entity with values such as PUMP-01 - 1001, which can be matched to entity names in IFS OI Server. Rules:
- Arguments are property names, or text in single quotes. Write a quote inside text as two quotes, for example 'it''s'.
- Property names must be simple names (letters, digits and _), not paths.
- An empty (null) value is treated as empty text.
- Each computed column needs a unique name.
- Columns used only inside concat are fetched but not returned. To return one as well, list it separately in $select.
- Only $select is changed; $filter and the other options are sent to the service unchanged.
Examples
Dataset: Public Sample Service
A quick way to check the Generic OData Adaptor works. Create a datasource with Base URL https://services.odata.org/V4/Northwind/Northwind.svc and Authentication None, then add a dataset with this query:
Products?$select=ProductID,ProductName,UnitPrice&$top=20
Dataset: Filtered by a Parameter
The user chooses a category in Explorer; the list is sorted by name unless the sort is changed.
Products?$filter=CategoryID eq ODATAPARAM(category,integer,Int32) and Discontinued eq false&$select=ProductName,UnitPriceODATASORTBY(ProductName)
ODATASORTBY goes straight after the last query option, with no space, because it adds &$orderby=ProductName at that point.
Dataset: Text and Date Parameters
WorkOrders?$filter=Site eq ODATAPARAM(site,string,String) and RegDate ge ODATAPARAM(from,datetime,Date)
Time Series: Wide Production Table (OData v2)
Datasource settings
BaseURI: https://energysys.example.com/odata OdataServerVersion: v2 Authentication: Secure Login Table Name: WELL_DAILY WideMode: selected Name Field: NAME Timestamp Field: PRODUCTION_DATE Value Column(s): GAS_VOL,OIL_VOL,WATER_VOL,CHOKE Entity Attribute Delimiter: . Tag Discovery Table Name: WELL_TAGLIST Tag Discovery Column Names: TAGNAME,DESCRIPTION,UNITS,MINIMUM,MAXIMUM
Tags are named like Well 1.GAS_VOL. Set the datasource time zone to the zone the service uses for PRODUCTION_DATE.
Time Series: Narrow Readings Table (OData v4, OAuth 2.0)
Datasource settings
BaseURI: https://cloud.example.com/odata/v4 OdataServerVersion: v4 Authentication: OAuth 2.0 OAuth2 Client ID: (your client ID) OAuth2 Client Secret: (your client secret) OAuth2 TokenURI: https://cloud.example.com/oauth2/token Table Name: Measurements WideMode: cleared Name Field: TagName Timestamp Field: MeasuredAt Value Column(s): Value Confidence Column Name: Quality Additional Filters: Site eq '2401' Scan Days: 1
Set the datasource time zone to UTC, because this is a v4 service.
Troubleshooting
"Required parameter(s) for Secure Login unrecognised or not found"
Authentication is Secure Login (the default) but the user name or password is empty. Fill them in, or set Authentication to None if the service needs no sign-in.
"Certificate was not valid"
No certificate with that thumbprint was found in the Local Machine Personal store, or the Certificate Verification Endpoint didn't accept it. Check the thumbprint (capitals, no spaces), that the certificate is installed for the machine rather than a user, and that the adaptor's account can read its private key.
A tag shows "field does not exist"
A column in Value Column(s) doesn't exist in the table. Check the spelling and capitalization against the service. Other tags still return data.
Wide-mode tags show a delimiter error
The tag name doesn't contain the Entity Attribute Delimiter. Check that tags were created from this datasource and that the delimiter hasn't changed.
Readings are shifted by a few hours
Check the datasource time zone. For v4 services it should be UTC. For v1 to v3 services it should be the zone the service stores its times in. See Time Zones.
Tag browsing is slow or finds nothing
Without a tag list table, browsing scans the last Scan Days of readings. Increase Scan Days if entities report less often, or set up a Tag Discovery Table Name.
A dataset fails with "invalid computed column expression"
Check the concat(…) as Name syntax: commas between arguments, text in single quotes, and a simple name after as.
Errors from the service
When an OData v4 service returns an error, the message includes the service's error code and text. The full request URL and response are written to the server log.
Limitations
- Read-only. Neither adaptor writes data back to the service.
- The Time Series adaptor needs a service that supports $batch requests.
- Tag browsing without a tag list table can be slow for large tables.
- The Generic OData Adaptor reads the results in the service's response. If the service splits large results into pages, only the first page is returned; use $filter and $top to keep results within one page.
- Some ODATAPARAM types are written in the older OData format, which v4 services may reject. See OData Types for ODATAPARAM.
- Computed columns support concat only.
- The SQL keywords FIRSTROW(), LASTROW() and ENTITYNAME() are not supported in OData dataset queries.