This is a query I use to write out the LAT/LON of points from data stored in State Plane (feet):

select 
residential_block_points.geoid_num
, st_x(st_centroid(st_transform(residential_block_points.geom, 4326))) as X
, st_y(st_centroid(st_transform(residential_block_points.geom, 4326))) as Y
from 
residential_block_points


and you could add this data as new fields in the existing table:

ALTER TABLE "residential_block_points" ADD x double precision;
ALTER TABLE "residential_block_points" ADD y double precision;
UPDATE "residential_block_points" SET x = st_x(st_centroid(st_transform(residential_block_points.geom, 4326)));
UPDATE "residential_block_points" SET y = st_y(st_centroid(st_transform(residential_block_points.geom, 4326)));


Convert the_geom to text and then transform
I've been trying to solve this for awhile and can't find a way.
Given $ S={(x,y,z) \in R^3 : z = x^2 - y^2 , x^2 + y^2 \leq 1 } $ and $\phi :R^3 \to R $ defined as $\phi (x,y,z)= (4z +8y^2 + 1)^{3/2}$, find $\iint_{S} \phi dS $.

I think I have to use $ \int_{0}^{2\pi} \int_{0}^{1} \phi (T(r,\theta)) \left \| T_{\theta} \times T_{r} \right \| dr d\theta $
So I first parametrized S with $x= r \cos \theta $, $y= r \sin \theta $ and $ z = r [2\cos^2 \theta - 1] $. So I had $ T(r,\theta)= (r\cos\theta , r\sin\theta, r[\cos^2\theta - 1]) $.     

If I'm not mistaken I have to use $ \int_{0}^{2\pi} \int_{0}^{1} \phi (T(r,\theta) \left \| T_{\theta} \times T_{r} \right \| dr d\theta $.  

Now I need to find $ || T_{r} \times T_{\theta} || = || (r\cos\theta[2\cos^2 \theta-1+2\sin\theta], r\sin\theta, -r) ||$   

Now, as you can imagine that ends up being one messed up thing once you square the first term, and I haven't found anyway to simplify anything, which leaves me with a pretty tough integral to solve.    

This is the integral I got, but Wolfram Alpha couldn't solve it and neither could I.    

$ \int_{0}^{2\pi} \int_{0}^{1} (8 r^2 \sin^2(\theta)+4 r(2 \cos^2(\theta)-1)+1)^{3/2} \sqrt((r \sin(\theta))^2+(2 r \cos^3(\theta)+2 r \sin^2(\theta) \cos(\theta)-r \cos(\theta))^2+(-r \cos^2(\theta)-r \sin^2(\theta)|^2) dr d\theta $   

I'm guessing I either used a wrong parametrization, or there's another way to solve this not using $ \iint_{S} \phi(T(r,\theta)) \left || T_{r} \times T_{\theta} \right || dS $.   

Any help would be greatly appreciated.   

EDIT: As Didier pointed out, $z = r^2 [2 \cos^2 \theta +1] $. But that doesn't make matters a whole lot simpler since now $ || T_{r} \times T_{\theta} || = || (-4r^2 \cos \theta \sin^2 \theta - 2 r^2 \cos\theta [2\cos^2 \theta +1], -4 r^{2} \cos^{2} \theta \sin \theta + 2r^2 \sin \theta [2\cos^2\theta +1], r) || $.   

EDIT2: Another retarded mistake, fixed by Didier.
$ || T_{r} \times T_{\theta} || = (-4r^2 \cos\theta\sin^2\theta-2r^2 \cos\theta[2\cos^2 \theta -1], 4r^2 \cos^2 \theta \sin\theta-2r^2\sin\theta[2\cos^2\theta-1], r) $, still not totally right though.

I must have another error somewhere but just can't seem to find it.
