WorkunitMessages

STD.System.Workunit.WorkunitMessages ( wuid )

wuidA null-terminated string containing the WorkUnit IDentifier.
Return: WorkunitMessages returns a DATASET value.

The WorkunitMessages function returns a DATASET with this format:

EXPORT WsMessage_v2 := RECORD
  UNSIGNED4 severity;
  INTEGER4  code;
  STRING32  location;
  UNSIGNED4 row;
  UNSIGNED4 col;
  STRING16  source;
  STRING20  time;
  UNSIGNED4 priority;
  REAL8     cost;
  STRING    message{MAXLENGTH(1024)};
END;

This function returns all messages in the workunit. Each record in the returned dataset specifies a message in the workunit.

The severity value can be 1 for Warning, 2 for Error, or 3 for Information.

Note: The DATASET structure returned by WorkunitMessages added two fields (priority and cost) in version 9.10.0.

Example:

IMPORT STD;
OUTPUT(STD.System.Workunit.WorkunitMessages('W20250602-164946'));