Skip to content

Commit

Permalink
Merge pull request #1 from Tools4ever-NIM/msheldont4e-patch-1
Browse files Browse the repository at this point in the history
Update auditapp_last7days.json
  • Loading branch information
msheldont4e authored Apr 18, 2023
2 parents 9dcac46 + 00a516f commit 0c40c0f
Showing 1 changed file with 23 additions and 12 deletions.
35 changes: 23 additions & 12 deletions queries/auditapp_last7days.json
Original file line number Diff line number Diff line change
@@ -1,40 +1,51 @@
{
"name": "AuditApp_Last7Days",
"query": "SELECT \n\t\t O.KeyValue 'ID'\n , O.DisplayName 'Name'\n\t\t, AU.AttributeName 'Attribute'\n\t\t, AU.ValueOld 'Old'\n , AU.ValueNew 'New'\n , OP.Name 'Operation'\n , OM.DateTime 'Operation DT'\n , AC.DateTime 'Activity DT'\n , AT.Name 'Activity'\n , ST.SystemName 'System'\n , ST.TableName 'Table'\nFROM AttributeUpdates AU\nINNER JOIN ObjectMutations OM ON OM.ID = AU.ObjectMutationID\nINNER JOIN Operations OP ON OP.ID = OM.OperationID\nINNER JOIN Activities AC ON AC.ID = OM.ActivityID\nINNER JOIN ActivityTypes AT ON AT.ID = AC.ActivityTypeID\nINNER JOIN Objects O ON O.ID = OM.ObjectID\nINNER JOIN SystemTables ST ON ST.ID = O.SystemTableID\nWHERE datetime(om.DateTime) > CURRENT_TIMESTAMP-7\nORDER BY OM.DateTime DESC\nLIMIT 500",
"query": "SELECT \n\t\t O.KeyValue 'ID'\n , O.DisplayName 'Name'\n\t\t, AU.AttributeName 'Attribute'\n\t\t, AU.ValueOld 'Old'\n , AU.ValueNew 'New'\n , OP.Name 'Operation'\n , OM.DateTime 'Operation DT'\n , AC.DateTime 'Activity DT'\n , AT.Name 'Activity'\n , ST.SystemName 'System'\n , ST.TableName 'Table'\nFROM AttributeUpdates AU\nINNER JOIN ObjectMutations OM ON OM.ID = AU.ObjectMutationID\nINNER JOIN Operations OP ON OP.ID = OM.OperationID\nINNER JOIN Activities AC ON AC.ID = OM.ActivityID\nINNER JOIN ActivityTypes AT ON AT.ID = AC.ActivityTypeID\nINNER JOIN Objects O ON O.ID = OM.ObjectID\nINNER JOIN SystemTables ST ON ST.ID = O.SystemTableID\nWHERE datetime(om.DateTime) > DATE(CURRENT_TIMESTAMP, '-7 days')\nORDER BY OM.DateTime DESC\nLIMIT 500",
"params": [],
"columns": [
{
"name": "ID"
"name": "ID",
"type": 0
},
{
"name": "Name"
"name": "Name",
"type": 0
},
{
"name": "Attribute"
"name": "Attribute",
"type": 0
},
{
"name": "Old"
"name": "Old",
"type": 0
},
{
"name": "New"
"name": "New",
"type": 0
},
{
"name": "Operation"
"name": "Operation",
"type": 0
},
{
"name": "Operation DT"
"name": "Operation DT",
"type": 0
},
{
"name": "Activity DT"
"name": "Activity DT",
"type": 0
},
{
"name": "Activity"
"name": "Activity",
"type": 0
},
{
"name": "System"
"name": "System",
"type": 0
},
{
"name": "Table"
"name": "Table",
"type": 0
}
]
}

0 comments on commit 0c40c0f

Please sign in to comment.