This picture shows the proper installation of the drain. The lower half of the "cast iron" drain flange should be flush with concrete and wood floors.
Plastic drain flanges are unacceptable.
Click on image to enlarge
Here you see the blocking installed. Blocking is typically 8" to 9" above finished floor. The use of 1/4" plywood on the face of the studs is also adequate.
When plumbing prevents the use of blocking a piece of sheet metal may be used to cover the opening.
The Dam, or Threshold, is typically three 2x4's stacked flat.