Helpfulbox Now Offers Free POS Software for restaurants, kiosk, and any other retails business completely free used windows cashier system or as full blown POS. You will able to print to kitchen, display orders on the kitchen screen, manage inventory, employee, report, customer loyalty offers, employee management, delivery address track and much more, al for free.

add time in MYSQL Hello, I am trying get the sum of a field that has a datatype of time. This field contains the difference between 2 stored dates. In theory the difference between these 2 dates should never be more than 24 hours. What I want to do is get a sum of all the time logged in to the systm. Per the documentaion : TIME values may range from ?-838:59:59′ to ?838:59:59′. If the total of time exceeds 838:59:59 - how do I get the proper time? Should I be calculating this in PHP or in MYSQL? Thank you for your time. I am new to mySql and PHP.

By: Guest
Date: Unknown--
Response
0
I think I found your answer

To select from a date range with MySql timestamp using the unix_timestamp, then display in human readable format. This is great with php, when you use drop down date ranges.

The $starttime and $endtime are varibals that I passed in my php script. I also made the varibles into a unix_timestamp in php using the mktime()

select date_format(FieldWithMysqlTimestamp1, '%b-%d-%Y') as Field1, Field2, Field3, date_format(FieldWithMysqlTimestamp2, '%b-%d-%Y') as Field4 from TableName where unix_timestamp(FieldWithMysqlTimestamp1) between $starttime and $endtime

[d] By: Guest
Date: unknown---
Response
0
Version5php

I am new too.... however I am actively involved in it. I was wondering if we can discuss and exchange some knowledge and network.... occomputerfix.com

[d] By: Guest
Date: unknown---
Response
What is 1 + 100



Helpfulbox Now Offers Free POS Software

for restaurants, kiosk, and any other retails business completely free. It can be used as windows cashier system or as full blown POS. You will able to print to kitchen, display orders on the kitchen screen, manage inventory, employee, report, customer loyalty offers, employee management, delivery address track and much more, all for free.

Just Updated::