I need to build a piece of code do calculate the total working time of a
I have the tables:
# Table structure for table 'card_ticks'
CREATE TABLE card_ticks (
cod bigint(20) unsigned NOT NULL auto_increment,
tick datetime ,
employee int(10) unsigned NOT NULL DEFAULT '0' ,
PRIMARY KEY (Cod)
# Table structure for table 'employes'
CREATE TABLE employes (
cod int(3) unsigned NOT NULL auto_increment,
nameme char(30) NOT NULL DEFAULT '' ,
pass char(50) NOT NULL DEFAULT '' ,
PRIMARY KEY (cod)
The table card_ticks is "feeded" by a system connected to a serial port
where each time the employee pass a card into a machine a record is inserted
on the table.
Generally, a employee has 4 card_tick's by day, for example
I have to write the code to do something like this
Calculate the total working time in a month for employee 3.
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php