Related to:
SQL-Toolkit. Time / date queries. Format.
Problem
Direct SQL Query on a database returns date in the following format
Result in Geneos dataview - this does not show the time in seconds format as per query above
Solution
The SQL query needs to be amended to include formatting codes.
Example - MYSQL query - should include FROM_UNIXTIME(e.timestamp,'%Y-%m-%d %H:%i:%S') instead of FROM_UNIXTIME(e.timestamp)
select e.ref,e.timestamp,FROM_UNIXTIME(e.timestamp),FROM_UNIXTIME(e.timestamp,'%Y-%m-%d %H:%i:%S')from event_table e,node_ref_table n where e.node_ref=n.ref order by timestamp desc limit 300, 500;
Note - this is an example MY-SQL query the syntax may differ across different database flavours.
If further clarification needed.
- Please contact with our Client Services team via the chat service box available in any of our websites or via email to support@itrsgroup.com
Comments
0 comments
Please sign in to leave a comment.