Thanks, Jeff. I'll tinker around with intersection function. Roppola, it seems putting the raster mesh in the database (BLOB data type?) is not feasible in this situation. I wonder if anyone has ever succeeded in intersecting polygon and raster before.