Opened 8 years ago

Closed 7 years ago

#1389 closed defect (fixed)

Rasql_Range constructor does not regard specific scalar values

Reported by: Bang Pham Huu Owned by:
Priority: major Milestone: 9.5
Component: rasql Version: development
Keywords: Cc: Dimitar Misev, Vlad Merticariu, bbell
Complexity: Medium

Description

Use case: create a 2D coverage with 3 bands (when 2 bands are filled with trivial scalar value and 1 band is calculated scalar value).

rasql -q 'SELECT encode({
  200, 
  MARRAY first in [51:150,0:99] 
  VALUES (first * (first > 50) + 250*(first > 150))
  , 250}, "png" , 
"nodata=250,0,0;xmin=51;ymin=0;xmax=150;ymax=99") FROM mean_summer_airtemp AS c' --out file

the output image has correct values for band 2 (calculated band) but values of band 1 and band 3 is '''0''', instead of 200 and 250 respectively.

Change History (4)

comment:1 by Bang Pham Huu, 7 years ago

Milestone: 9.39.4

comment:2 by Bang Pham Huu, 7 years ago

Cc: bbell added
Milestone: 9.49.5

comment:3 by Dimitar Misev, 7 years ago

Can you retest this query? Maybe it was fixed by the recent range constructor patch.

comment:4 by Bang Pham Huu, 7 years ago

Resolution: fixed
Status: newclosed

good work BBell.

output in png: red: 200, green: 118, blue: 250

Note: See TracTickets for help on using tickets.