You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -882,8 +884,6 @@ SELECT count(DISTINCT clients.id) AS count_all FROM clients
882
884
(clients.first_name = 'Ryan' AND orders.status = 'received')
883
885
</sql>
884
886
885
-
This code specifies +clients.first_name+ just in case one of the join tables has a field also called +first_name+ and it uses +orders.status+ because that's the name of our join table.
886
-
887
887
h4. Count
888
888
889
889
If you want to see how many records are in your model's table you could call +Client.count+ and that will return the number. If you want to be more specific and find all the clients with their age present in the database you can use +Client.count(:age)+.
0 commit comments