Normal Topic Mass Updating A Field to Another Field (Read 902 times)
actiontech
Full Member
***
Offline



Posts: 173
Joined: Apr 10th, 2016
Mass Updating A Field to Another Field
Nov 23rd, 2017 at 3:43am
Print Post Print Post  
Hello,

Might seem like a simple or easy problem, but I cannot figure out the code to mass update one LE field to another LE field that I created.

Say I have an LE called "City" but it's just a regular text field, and now I want to turn it into a combo box or dropdown field. I can't do that so I have to create a new LE called "City0".

Now that I have my new "City0" LE, I would like to mass update all the information in the original "City" LE to the new "City0" LE in every single record.

Does anyone know how to do that?

I remembered hearing something about binding the elements before as well. So that might be a possible solution too.

Thanks for your time.
  
Back to top
 
IP Logged
 
actiontech
Full Member
***
Offline



Posts: 173
Joined: Apr 10th, 2016
Re: Mass Updating A Field to Another Field
Reply #1 - Nov 23rd, 2017 at 3:44am
Print Post Print Post  
Also, I tried looking up about mass updating and some of the programming you can do for it with SBasic. I tried setting "City0" to = "City" and it doesn't work. It essentially erases the field in every single record. So, I guess I don't know what I'm doing.
  
Back to top
 
IP Logged
 
Bob_Hansen
Senior Member
Members
*****
Offline


WOW, They have the Internet
on computers now!

Posts: 1861
Location: Salem, NH
Joined: Nov 24th, 2002
Re: Mass Updating A Field to Another Field
Reply #2 - Nov 23rd, 2017 at 9:38pm
Print Post Print Post  
No MassUpdating (MUD) needed.

1. Rename City element to zCity (I use a z prefix for fields I plan to remove).
2. Make sure it is bound to an field (named City for this example)
3.  Add a new ComboBox element named City.
4.  Make sure new ComboBox, City, is bound to same field, named City.
5.  Done.   Check and see that all records have same value in both elements.
6.  When confirmed that it worked, you can then delete the old element zCity.
7.   Really done.

Double check any programming to confirm City references have not changed.  (Use Search and Replace, globally, to fix any changes).

You will still need to define the ComboBox choice options. You can do this with a right click or use some XLU commands.   Many examples are in the manuals.

If uncomfortable with this, make a backup copy of your application first.

(NOTE: These instructions are from memory, no access to test on Sesame at this time).
  



Bob Hansen
Sesame Database Manager Professional
Sensible Solutions Inc.
Salem, NH
603-898-8223
Skype ID = sensiblesolutions
Back to top
IP Logged
 
actiontech
Full Member
***
Offline



Posts: 173
Joined: Apr 10th, 2016
Re: Mass Updating A Field to Another Field
Reply #3 - Dec 24th, 2017 at 6:35pm
Print Post Print Post  
Much obliged.
  
Back to top
 
IP Logged