Hi Jackie,

Your problem here is that you how one or several records without an
"attached" geographical object, such as a line, polylinie, point or other.

I cannot tell you why but you should try this Select statement to get the
problem records:

Select * From MYTABLE Where Not OBJ into Selection

This selection should contain the records without object. Check them out
and delete them if they shouldn't be there.

To prevent this error later you can add a select statement with a
condition, so that only records wo�th an object will be selected:

Select * From MYTABLE Where OBJ Into MY_OBJ_TABLE NoSelect
Select * From MY_OBJ_TABLE Where ObjectLen(OBJ, "ft") > 25 Into Selection

You can not do the selection in a single select statement like this:
Select * From MY_OBJ_TABLE Where Obj and ObjectLen(OBJ, "ft") > 25 Into
Selection

MapInfos SQL interpreter (I guess) might optimize the statement and turn
the conditions around and then you are right where you started.
By the way I'm not sure whether or not MapInfo has an optimizer for the
select statement, does anyone else know ???
If you have a select statement with a geographical condition (as Within,
Intersect etc.) and a simple compare condition (=, <> etc) there is
quite a difference in what way you put the conditions. My experience is
that putting the geographical condition first makes the select quite a lot
faster.
Does anyone have other experiences with this ??

I hope this helps!

Peter
------------------------------------------------------------------------------------------------
Peter Horsb�ll M�ller, GIS-Developer
Kampsax A/S, GIS Software & Solutions, Rugaardsvej 55, DK-5000 Odense, Denmark
tlf: + 45 63 13 50 13, dir: + 45 63 13 50 08, fax: + 45 63 13 50 90
mail: [EMAIL PROTECTED], http://www.mapinfo.dk, http://www.kampsax.dk
------------------------------------------------------------------------------------------------

Jackie wrote:

This hopefully will be a very minor problem compared to most that I have
read here on the list. I am trying to run a query on my street table to
find all segments under the length of 25 feet.  The condition that I am
using is:  ObjectLen(obj, "ft") < 25 which returns the reply of: 1.
could not fetch object from the current row, argument ObjectLen.  What
does this mean and how do I fix the problem?  Any help is appreciated.



_______________________________________________________________________
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, send e-mail to [EMAIL PROTECTED] and
put "unsubscribe MapInfo-L" in the message body.

Reply via email to