Factry Historian
Events
Database views
postgres schema every organizations docid\ ie9bm zmn69tumtdfngbk in factry historian will have a corresponding schema in the postgres database with the same name a postgres user which can only access the schema is also created when creating an organization this user can only access the views and functions present in this schema, by default its search path is set to this schema renaming the organization will also rename this schema views there are 2 views which are present from the start and are not dependant on the configured event types & properties docid\ mg2d9wmvt4yzdepya sp6 events view this view can be used to get basic information of all the events in the organization it contains the following columns event uuid the uuid of the event asset uuid the uuid of the asset of the event event parent uuid the uuid of the parent event, may be null if no parent is configured event type the name of the event type of the event event type uuid the uuid of the event type of the event asset path the asset path of the asset of the event asset name the name of the asset of the event asset description the description of the asset of the event start time the start time of the event stop time the stop time of the event start time epoch the unix milliseconds of the start time of the event stop time epoch the unix milliseconds of the stop time of the event status the status of the event (open, incomplete or processed) source the source of the event (auto or manual) properties the properties of the event in json form duration the duration of the event in seconds assets view this view returns all assets in the organization it contains the following columns uuid the uuid of the asset name the name of the asset description the description of the asset status will be deleted if the asset is deleted parent uuid the uuid of the parent asset, null if the asset has no parent asset path the full asset path created by the uuid of the user that created the asset created at the timestamp when the asset was created updated by the uuid of the user that last updated the asset updated at the timestamp when the asset was last updated attributes / organization uuid the uuid of the organization the asset is part of generated views all event types will have up to 3 views generated depending on the configured properties all these views will have the following columns event uuid the uuid of the event event parent uuid the parent uuid of the event asset uuid the uuid of the asset of the event asset path the full asset path of the asset of the event asset name the name of the asset of the event asset description the description of the asset of the event start time the start time of the event stop time the stop time of the event start time epoch the unix milliseconds of the start time of the event stop time epoch the unix milliseconds of the stop time of the event status the status of the event (open, incomplete or processed) source the source of the event (auto or manual) duration the duration of the event in seconds all event types will have the following corresponding view v {event type name} event properties this view has an extra column for every configured simple event type property v {event type name} event samples this view has the following extra columns time offset the offset in seconds from the start time of the sample time of the periodic value sample time the sample time of the periodic value sample time epoch the unix milliseconds of the sample time name the name of the corresponding periodic property value the value of the corresponding periodic property at the sample time v {event type name} event samples joined this view has the following extra columns time offset the offset in seconds from the start time of the sample time of the periodic value sample time the sample time of the periodic value sample time epoch the unix milliseconds of the sample time a column for every periodic property configured with the corresponding value at the sample time (if any)