Hey Guys,
Some times we need to show the posted time or you can say when the data is inserted into the table.The idea of showing date in this format came from the social site post time display schemes eg. facebook,Google Plus, Linked In etc
for tracking the time we generally use the date column with default value of sysdate.
but it just show the time when it was inserted into the table.
If we want to display how much time before the record was posted or inserted we can use the apex_util.get_since function .
It will give you the round value in 19 hours ago format.It looks like user friendly and understandable.
select apex_util.get_since(created_on) from table;
Output:
Some times we need to show the posted time or you can say when the data is inserted into the table.The idea of showing date in this format came from the social site post time display schemes eg. facebook,Google Plus, Linked In etc
for tracking the time we generally use the date column with default value of sysdate.
but it just show the time when it was inserted into the table.
If we want to display how much time before the record was posted or inserted we can use the apex_util.get_since function .
It will give you the round value in 19 hours ago format.It looks like user friendly and understandable.
select apex_util.get_since(created_on) from table;
Output:
13 days ago |
13 days ago |
4 weeks ago |
13 days ago |
No comments:
Post a Comment
Please do not add any spam links or abusive comments.