Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
SQl_QUEST_2_PRESENTATION_IMG_COUNT
CREATE TABLE EVENT_LOGS ( UserId INT, [TimeStamp] DATETIME ) GO INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (2, GETDATE()); INSERT INTO EVENT_LOGS VALUES (5, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (3, GETDATE()); INSERT INTO EVENT_LOGS VALUES (2, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (4, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (2, GETDATE()); INSERT INTO EVENT_LOGS VALUES (5, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (3, GETDATE()); INSERT INTO EVENT_LOGS VALUES (2, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (4, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (2, GETDATE()); INSERT INTO EVENT_LOGS VALUES (5, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (3, GETDATE()); INSERT INTO EVENT_LOGS VALUES (2, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (4, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (2, GETDATE()); INSERT INTO EVENT_LOGS VALUES (5, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (3, GETDATE()); INSERT INTO EVENT_LOGS VALUES (2, GETDATE()); INSERT INTO EVENT_LOGS VALUES (2, GETDATE()); INSERT INTO EVENT_LOGS VALUES (2, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); INSERT INTO EVENT_LOGS VALUES (4, GETDATE()); INSERT INTO EVENT_LOGS VALUES (1, GETDATE()); Go SELECT UserId, COUNT(UserId) AS IMAGE_COUNT FROM EVENT_LOGS GROUP BY UserId HAVING COUNT(UserId) BETWEEN 10 AND 20
run
|
edit
|
history
|
help
0
Demo here
TO find max marks of students
MyShopSchema
Using Variables
EmployeeDetails
Seq
Demo
Import CSV File Into SQL Server Using Bulk Insert
Demo
b