Hi Jo Ellen,
here what I think:
In step 4, you're not breaking the roads. Your query simply compute
proportional road lenght. One way to see this is to select one row in the
browser, you'll see that other rows are selected as well. In that case, all
computed parts of the road are selected. It means that the road is still one
entity.
If you really want to break the road in respect of county
boundaries, here's how.
- Make a backup copy of your road table and use this newly
created table (its name, "roadseg").
- In a mapper, make roadseg editable and viewable. Make the
county table viewable as well.
- Select all objects in roadseg.
- Define the selection as the target.
- Select all counties.
- Split the target.
Now, you have a table where roads are segmented according to county
boundaries. You could use a query or add a column to compute the length of
each new sections.
>From here, you can use Step 6 to compute segmented road length in each grid
cells.
Hope this will answer your query. Good luck
Yannick Leduc
[EMAIL PROTECTED]
> -----Message d'origine-----
> De: Jo Ellen Brandmeyer [mailto:[EMAIL PROTECTED]]
> Date: 20 janvier, 1999 13:21
> �: [EMAIL PROTECTED]
> Objet: MI: need help breaking lines into segments & storing resulting
> objects
>
>
> I am currently trying to perform the following steps in a MapBasic 5.0
> program for MapInfo Professional 5.0:
>
> 1. open road coverage (polylines)
> 2. open county coverage (polygons)
> 3. open modeling grid coverage (polygons)
> 4. use Select statement to overlay county coverage onto road coverage,
> with the goal of breaking all roads at county boundaries:
>
> Select [field list], ObjectLen(road.obj,"mi") "calcroad",
> ObjectLen(Overlap(road.obj,county.obj),"mi") "seglength"
> from road, county
> where county.obj contains part road.obj
> into ctyroad
>
> 5. commit ctyroad, close ctyroad, open ctyroad to make ctyroad a base
> table
>
> 6. use Select statement to overlay modeling grid coverage onto ctyroad
> coverage
>
> Select [field list], ObjectLen(ctyroad.obj, modelgrd.obj),"mi")
> "gridctyrdmi"
> from ctyroad, modelgrd
> Where modelgrd.obj contains part ctyroad.obj
> into gridctyroad
>
> The lengths I am getting in (6) are the lengths of the
> original roads in
> the grid cell, not the length of the road segments in the grid cell.
>
> I need to resolve this matter because I need to overlay the county
> boundaries on the roads only once, but then I have multiple
> grids that I
> need to overlay onto the road segments. Later calculations depend on
> road segments by county and grid cell, not just roads by grid cell.
>
> What am I missing? How can I get step (4) to save objects that are the
> road segments, instead of the full roads for each road segment?
>
> TIA,
>
> Jo Ellen Brandmeyer
> ----------------------------------------------------------------------
> To unsubscribe from this list, send e-mail to
> [EMAIL PROTECTED] and put
> "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
>
----------------------------------------------------------------------
To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put
"unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]