My original question was:
=== 
I have a question which I'm sure is a FAQ, but have not been 
able to locate the answer, my apologies if it's right in front of 
my face, but I just don't  see it. :)

I have some records in which I need to update a text field. 
How do I update them en mass?

The scenario: adding a text label/id to stream watersheds. 
Currently I select the relevant vectors, browse the selection 
table, paste an identical text string a few hundred times into 
the "ws_id" field.
===

Through a combination of experimentation and reading 
through the various suggestions emailed to me I eventually
discovered my error lay in misunderstanding how the 
expressions work. More specifically, use the concatenate 
operator (+).

Interactively:

- Select/Query the elements to operate on
- Table > Update Column
- Table to Update:   Selection or Query#
- Column to Update:   ws_id
- Get Value from Table:   Selection or Query#
* Value:   +"text string"


And to accomplish the same task in the map basic window:

   1.  Select the relevant vectors
   2.  In the Mapbasic window, type
           Update Selection Set ws_id = "text string"

Where 'Selection' is the table/query/selection and 'ws_id' is
the column and  ' "text string" ' is some sort of text. Define 
the column as Char in Maintain Table.

If the idea is to create a unique record ID, you could use this:

    Update tablename set columnname = rowid

or whatever you want to put instead (rowid+100000, 1, a,
centroidX(obj).....). 'rowid' is basically the row number.

Thanks to all the respondants. Everybody was kind with no
flames for not understanding something so simple. :)

cheers,

-matt
----------------------------------------------------------------------
To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put
"unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]

Reply via email to