note 74861 added to ref.mysql

From: Date: Tue, 01 May 2007 08:02:45 +0000
Subject: note 74861 added to ref.mysql
Groups: php.notes 
Request: Send a blank email to php-notes+get-126012@lists.php.net to get a copy of this message
to calculate the students' end of year mark in school data base with one query SELECT student.snumber AS 'Student Number', student.name AS 'First Name', student.lastname AS 'Last Name', SUM( smarks.smark ) AS 'Total Mark', COUNT( * ) AS 'Total Lesson', (SUM( smarks.smark ) / COUNT( * )) AS 'Marks End Of Year' FROM students AS student LEFT JOIN smarks ON smarks.student_id = student.id LEFT JOIN lessons AS lesson ON lesson.lesson_id = smarks.lesson_id GROUP BY student.snumber ORDER BY 'Marks End Of Year' DESC http://www.mysqlturkiye.org to check Turkish examples,take a look at this adress ---- Server IP: 85.111.6.23 Probable Submitter: 144.122.180.150 ---- Manual Page -- http://www.php.net/manual/en/ref.mysql.php Edit -- https://master.php.net/note/edit/74861 Del: integrated -- https://master.php.net/note/delete/74861/integrated Del: useless -- https://master.php.net/note/delete/74861/useless Del: bad code -- https://master.php.net/note/delete/74861/bad+code Del: spam -- https://master.php.net/note/delete/74861/spam Del: non-english -- https://master.php.net/note/delete/74861/non-english Del: in docs -- https://master.php.net/note/delete/74861/in+docs Del: other reasons-- https://master.php.net/note/delete/74861 Reject -- https://master.php.net/note/reject/74861 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#126012) next »