0

At the moment we use the street 1 field for the house number in our Magento 2.3.5 store.

But we want to revert this and only use 1 street field for both the street and house number. So we need to move all values from the street 1 field after the current values into the street 0 field.

In the database it is not just a new field, its just a new line in the street column. So it seems that we just need to add it to the same line.

How can we easily and safely achieve this? Can we perform this using an sql?

1 Answer 1

0

I think you do easily do it using update query. Please review below reference query and update parameters based on your requirement

update DemoTable set UserFirstName=ListOfName where ListOfName is not null;

Here UserFirstName and ListOfName both are different field. Based on this example you can update the copy one column value to another column.

I hope this will help you.

Thanks.

1
  • Thanks! But in that case the problem is that the street 1 value is not a different column, it uses the same column in the database, but is only placed on a new line. So how can we solve that?
    – JGeer
    Sep 17, 2020 at 7:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.