Uffe,
A demo version would be great.
If it proves useful on 100 records then I will register to receive the full
program as detailed on your site.
Thank you very much.
PS - I do want to include the distance in the output! would this be included
with teh facility in your toolbox and how do I do it with SQL (I presume it
is an option or would I need to create a new column (or update the dummy
column) with thr details?
Sorry if this seems arather basic question but I am very new to all of this.
Many many thanks for your help...............it's all still confusing but I
am definately learning!
----- Original Message -----
From: "Uffe Kousgaard" <[EMAIL PROTECTED]>
To: "Lee Wold" <[EMAIL PROTECTED]>
Cc: "Mapinfo-L" <[EMAIL PROTECTED]>
Sent: Saturday, July 05, 2003 11:06 AM
Subject: Re: MI-L Calculate distance from Table of postcode points
> Hi Lee,
>
> You are correct, that 2 copies are needed. But before making the copy
> add an integer field ("dummyfield") with all 0's to the original table.
> Then run this query:
>
> select table1.id,table2.id
> where table1.dummyfield=table2.dummyfield and table1.id<table2.id and
> distance(centroidX(table1.obj),centroidY(table1.obj),centroidX(table2.ob
> j),centroidY(table2.obj),"mi")<20
>
> You may also like to include the distance in the output.
>
> This is slow: With just 1900 points it took 9 minutes, when 4892 records
> where returned on some random data.
>
> With mapbasic, it may be faster to run 1900 "select within radius"
> queries, but I haven' tried that.
>
> And now a commercial:
> In my ToolBox I have just added a function for doing this sort of
> selection "slightly" faster. It can select the n nearest points in one
> table for all points in another table, eventually combined with a
> distance-restriction as you have. On the same data as above, that took 5
> seconds, or 60 times faster.
>
> This function is still not available at the website (see signature), but
> I can send you a demo if needed - it will be restricted to 100 points in
> your dataset.
>
> Kind regards
>
> Uffe Kousgaard
> www.routeware.dk
>
>
> ----- Original Message -----
> From: "Lee Wold" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Saturday, July 05, 2003 11:27 AM
> Subject: MI-L Calculate distance from Table of postcode points
>
>
> I have a table with four columns as follows :
> Code Name Type Postcode
>
> It has approx 1900 points.
>
> I want to write an SQL query that takes each point in the table and
> compares it with every other point in the table and creates a new table
> where the distance between any two points is less than 20 miles.
>
> I am sure this is possible (and I think I will need two copies of the
> table to perform this query) but I am very new to Mapinfo and still
> learning!
>
> Any help would be greatly appreciated.
>
---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 7507