Skip to content
This repository was archived by the owner on Jan 23, 2025. It is now read-only.

Update for srm practice problems api #378

Merged
merged 1 commit into from
Oct 16, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions queries/get_practice_problems
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ SELECT
WHEN (p.problem_type_id = 1 AND p.proposed_difficulty_id = 3) THEN 'Hard'::nvarchar(50)
END AS difficulty
, rc.points
, CASE WHEN EXISTS (
, NVL(CASE WHEN EXISTS (
SELECT 1
FROM component_state cs
WHERE cs.status_id < 120
Expand Down Expand Up @@ -57,7 +57,7 @@ SELECT
AND pcs.status_id != 150
AND pcs.coder_id = @userId@
) THEN 'Viewed'::nvarchar(50)
END AS status
END, 'New') AS status
, NVL((
SELECT
points
Expand Down
4 changes: 2 additions & 2 deletions queries/get_practice_problems_count
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ SELECT
WHEN (p.problem_type_id = 1 AND p.proposed_difficulty_id = 3) THEN 'Hard'::nvarchar(50)
END AS difficulty
, rc.points
, CASE WHEN EXISTS (
, NVL(CASE WHEN EXISTS (
SELECT 1
FROM component_state cs
WHERE cs.status_id < 120
Expand Down Expand Up @@ -54,7 +54,7 @@ SELECT
AND pcs.status_id != 150
AND pcs.coder_id = @userId@
) THEN 'Viewed'::nvarchar(50)
END AS status
END, 'New') AS status
, NVL((
SELECT
points
Expand Down