Can you describe your query a little bit more? Are you actually just trying to group the sums by department or are you looking to use a conditional within your query?
Specifically what is this supposed to be doing:
IF(dept = "Development", 1,0) ?
If you just want to sum up your rows by department just do a sum on the dept and group by dept.
If you want to use a conditional check the postgres docs for the CASE function. If you describe your question in more depth I may be able to help a bit more as well.
(I'm only available at the email address provided in my profile on weekdays, if you have questions or advice, during off hours use AIM). Also any views I provide here or on my website are mine and not representative of any views of my work, family, friends and sometimes even myself.