Workaround from http://d.hatena.ne.jp/yellow_73/20120221
Mapserver 6.0.4, when using CONNECTIONTYPE POSTGIS with a geography column results in the following error:
msPostGISLayerWhichShapes(): Query error. Error executing query: ERROR: function st_force_2d(geography) does not exist
LINE 1: select encode(ST_AsBinary(ST_Force_2D("the_geog"),'NDR'),'he...
^
HINT: No function matches the given name and argument types. You might need to add explicit type casts.
Function ST_Force2D (also aliased as deprecated ST_Force_2D) supports only geometry parameters. After adding the st_force_2d(geography) function, mapserver no longer shows that error.