Combine objects with similar characteristics

176 views
Skip to first unread message

Mr. Timax

unread,
Jan 18, 2024, 9:56:54 AMJan 18
to MapInfo-L
Hi, I have a table with big amount of rows(polylines). I need to use Combine Objects command to join rows that are in touch and have few similar values in new row in mapbasic. I saw old topic about program that will draw polyline and combine/merge separated lines in touch. But it is not enough for my volume of date to do it by hands

I find the way how to initialize needed rows, but dont know how to use
Run Command Objects Combine... I'm getting error: "Table selection is closed, you dont have access to it" Sth like that. So It will be solving part of the problem if somebody can help me how to put data in "Selection"

Sorry for my bad english and maybe uncorrect format of message. It's my first time using forums.

P. S. - I have MapInfoPro 12.5 and mapbasic 10.5(not sure about mapbasic) and havent possibillity to upgrade it :-(

Thanks

Message has been deleted

sim...@gmail.com

unread,
Jan 24, 2024, 1:20:19 AMJan 24
to MapInfo-L

Hi Mr Timax,

In MapInfo Pro, "Selection" is the default name for the result when you run an SQL query. For example, in the MiPro SQL query (GUI) or MapBasic window (command line) for the first row in a table you could run "select * from TABLE1 where rowid = 1 into Selection". You could substitute "Selection" to almost any name you like for the resulting selection.
You can then browse it using "browse * from Selection".

To do a non-spatial join between two tables based on a common id, you could also run an SQL query. For example: "select name from table1, table2 where table1.id=table2.id into Selection".

For a spatial join, and example is "select name from table1, table2 where table1.obj intersects table2.obj into Selection". You can then save the results as a new table.
Reply all
Reply to author
Forward
0 new messages