Timestamp in column

QuestionsTimestamp in column
SaschaL asked 6 years ago

select_command = "SELECT FROM_UNIXTIME(`time`), `string` FROM `logs`";

How i'll get propper datetime-values in column formatted like this:

$col["formatter"] = "datetime";

In my example i'll get the values "undefined" in each row?

i use the free version of your awesome tool 🙂

Like it!

Kind regards
Sascha

PS: Sorry for my bad english

1 Answers
SaschaL answered 6 years ago

Solution:
– Given alias to column 'time'

"SELECT FROM_UNIXTIME(`time`) AS `Value`, `string` FROM `logs`"

– Use alias as ID in column

$col["name"] = "Value";

Works 🙂

Have a nice day!

Best Regards
Sascha

Your Answer

7 + 11 =

Login with your Social Id:

OR, enter

Attach code here and paste link in question.
Attach screenshot here and paste link in question.



How useful was this discussion?

Click on a star to rate it!

Average rating / 5. Vote count:

We are sorry that this post was not useful for you!

Let us improve this post!