[postgis-users] joining "nearest" data

Kirk Wythers kwythers at umn.edu
Tue Feb 20 05:47:57 PST 2007


On Feb 20, 2007, at 6:46 AM, Obe, Regina wrote:

> Hi Kirk,
>
> I meant substitute all references to ref_solar_station_id with  
> ref_weather_station_id.
>
> The idea is  to update the ref_weather_station_id of those that  
> don't have any weather for that year with those that do.  Basically  
> the first step sets  the ref_weather_station_id to the station_id  
> if the station has weather data for that year and null if it does  
> not and similarly ref_sol with station_id if the station has solar  
> data for that year.  So by the time you get to step 5 those that  
> have nulls in ref_weather_station_id have no weather for that year.  
> Those that have weather for that year (assuming I wrote the query  
> right - the ref_weather_station_id should be the same as the  
> station_id) .  Hope my explanation isn't even more confusing.
Not at all Regina. Thanks for all your assistance. I actually took a  
guess that you meant exactly that. I got your new table and the final  
query working and then had to give my attention to other projects. I  
will pick back up this week. I think one issue I have to playing with  
the 30 km boundary you set. I tired changing that to 50 km, and 100  
km, and 200 km just to see how many stations get picked up with the  
more flexible rule. Now that I have the filled after a 200 km INSERT,  
I think I need to delete all rows and start again with a more rigid  
rule (say 20 - 30 km).

Also, I think I'll add a 'longname' field for both the  
ref_weather_station_id and the ref_solar_station_id, so that a human  
can more immediately understand which stations are being lumped  
together.

Thanks again,

Kirk


> Thanks,
>
> Regina
>
>
> From: postgis-users-bounces at postgis.refractions.net [mailto:postgis- 
> users-bounces at postgis.refractions.net] On Behalf Of Kirk Wythers
> Sent: Friday, February 16, 2007 4:53 PM
> To: PostGIS Users Discussion
> Subject: Re: [postgis-users] joining "nearest" data
>
>
> On Feb 15, 2007, at 7:35 AM, Obe, Regina wrote:
>
>> Step 5 - Do the same as Step 4 except for ref_weather_station_id
>
> Do you mean substitute ref_weather_station_id for  
> ref_solar_station_id in line one only. Bottom line, are you saying  
> that you want to fill in in ref_weather_station_id with those that  
> have no solar data for that year, or with those that have no  
> weather data for that year?
>
>
>
>
> The substance of this message, including any attachments, may be
> confidential, legally privileged and/or exempt from disclosure
> pursuant to Massachusetts law. It is intended solely for the
> addressee. If you received this in error, please contact the sender
> and delete the material from any computer.
>
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20070220/3b3cfeb0/attachment.html>


More information about the postgis-users mailing list