Click here to Skip to main content
15,922,894 members
Home / Discussions / Database
   

Database

 
GeneralRe: Set timezone for Database on remote server Pin
Ashfield3-Aug-08 20:54
Ashfield3-Aug-08 20:54 
GeneralRe: Set timezone for Database on remote server Pin
AlexeiXX34-Aug-08 5:42
AlexeiXX34-Aug-08 5:42 
GeneralRe: Set timezone for Database on remote server Pin
Ashfield4-Aug-08 9:14
Ashfield4-Aug-08 9:14 
QuestionRetrieving Count from Database Table Pin
Jacob Dixon3-Aug-08 7:36
Jacob Dixon3-Aug-08 7:36 
AnswerRe: Retrieving Count from Database Table Pin
Vimalsoft(Pty) Ltd3-Aug-08 9:01
professionalVimalsoft(Pty) Ltd3-Aug-08 9:01 
AnswerRe: Retrieving Count from Database Table Pin
Blue_Boy3-Aug-08 10:39
Blue_Boy3-Aug-08 10:39 
AnswerRe: Retrieving Count from Database Table Pin
Jacob Dixon3-Aug-08 15:14
Jacob Dixon3-Aug-08 15:14 
AnswerRe: Retrieving Count from Database Table Pin
Mycroft Holmes3-Aug-08 16:13
professionalMycroft Holmes3-Aug-08 16:13 
SELECT COUNT(*),
	UserName
FROM TicketTable
	INNER JOIN UserTable ON UserTable.UserID = TicketTable.UserID
		AND UserTable.OnLine <> 0
GROUP BY UserName
ORDER BY COUNT(*)

SQL Server has a BIT field = boolean (UserDable.OnLine <> 0)
The above code will give you the "online" user with the least number of tickets in the ticket table.
By playing with the filters on the usertable join you can manage the users.


Never underestimate the power of human stupidity
RAH

AnswerRe: Retrieving Count from Database Table Pin
PIEBALDconsult3-Aug-08 17:17
mvePIEBALDconsult3-Aug-08 17:17 
AnswerRe: Retrieving Count from Database Table Pin
Jacob Dixon3-Aug-08 17:20
Jacob Dixon3-Aug-08 17:20 
QuestionUnable to connect to database Pin
mrkeivan2-Aug-08 23:50
mrkeivan2-Aug-08 23:50 
AnswerRe: Unable to connect to database Pin
Blue_Boy2-Aug-08 23:56
Blue_Boy2-Aug-08 23:56 
GeneralRe: Unable to connect to database Pin
mrkeivan3-Aug-08 11:12
mrkeivan3-Aug-08 11:12 
QuestionHow to give right to other computer Pin
SamrahNed2-Aug-08 21:26
SamrahNed2-Aug-08 21:26 
AnswerRe: How to give right to other computer Pin
Reza Raad3-Aug-08 1:59
Reza Raad3-Aug-08 1:59 
Questionpivot table into anther table Pin
prithaa2-Aug-08 18:23
prithaa2-Aug-08 18:23 
AnswerRe: pivot table into anther table Pin
Mycroft Holmes3-Aug-08 16:20
professionalMycroft Holmes3-Aug-08 16:20 
GeneralRe: pivot table into anther table Pin
prithaa3-Aug-08 19:29
prithaa3-Aug-08 19:29 
GeneralRe: pivot table into anther table Pin
Mycroft Holmes3-Aug-08 19:37
professionalMycroft Holmes3-Aug-08 19:37 
GeneralRe: pivot table into anther table Pin
prithaa3-Aug-08 20:48
prithaa3-Aug-08 20:48 
GeneralRe: pivot table into anther table Pin
Mycroft Holmes3-Aug-08 21:13
professionalMycroft Holmes3-Aug-08 21:13 
GeneralRe: pivot table into anther table Pin
prithaa4-Aug-08 0:49
prithaa4-Aug-08 0:49 
GeneralRe: pivot table into anther table Pin
Mycroft Holmes4-Aug-08 0:56
professionalMycroft Holmes4-Aug-08 0:56 
GeneralRe: pivot table into anther table Pin
prithaa4-Aug-08 1:23
prithaa4-Aug-08 1:23 
GeneralRe: pivot table into anther table Pin
Mycroft Holmes4-Aug-08 2:20
professionalMycroft Holmes4-Aug-08 2:20 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.