2

I have several images from different times and for every time I have three types of image (temperatureA, temperatureB, pressure). Should I store them as

  • every time as band in a single raster with N bands => I will have (3) rows (one for every data type)

  • every time as a single raster with 1 band => I will have (times count * 3) rows (one for every data type and for every time)

  • all 3 types in bands of a single raster => I will have (times count) rows (one row for every time)

What is tbe best option?

I will mostly read from the database and update all data hourly. Users will be reading from PHP website values at [x, y] from a single time, but all three variables.

2

I would create three tables and add a time column for every raster. Then your queries always have a "WHERE time = x" or "WHERE time < y".

  • Especially if you are going to be doing updates frequently, you want your rows to be as small in size as possible. So more rows, but smaller size rows. – LR1234567 Oct 29 '15 at 20:16
2

I have created tests to see what is faster:

Selecting data from (1) band in (N) band raster - 240 ms
Selecting data from (1) band in (1) band raster - 70 ms

(Full results: PostGIS raster and bands tests)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.