VbzCart/docs/tables/orders/migration: Difference between revisions
Jump to navigation
Jump to search
imported>Woozle (extracted from main page) |
m (Woozle moved page VbzCart/VbzCart/tables/orders/migration to VbzCart/docs/tables/orders/migration without leaving a redirect: part 4/5) |
||
(One intermediate revision by one other user not shown) | |||
Line 1: | Line 1: | ||
===Migration=== | ===Migration=== | ||
This was used to migrate the data on 2016-03-06: | This was used to migrate the data on 2016-03-06: | ||
<mysql>INSERT INTO orders_new( | <source lang=mysql>INSERT INTO orders_new( | ||
`ID`, | `ID`, | ||
`Number`, | `Number`, | ||
Line 46: | Line 46: | ||
`WhenNeeded`, | `WhenNeeded`, | ||
`WhenClosed` | `WhenClosed` | ||
FROM orders</ | FROM orders</source>Note that "WhenEdited" was copied to "WhenRevised" in the new table, not to "WhenEdited". (2016-03-07 Update: it turns out that this can be done with a single SQL command, which MySQL Workbench can facilitate via some controls that are normally hidden in a drop-down area. Now I know...) |
Latest revision as of 01:57, 25 February 2024
Migration
This was used to migrate the data on 2016-03-06:
INSERT INTO orders_new(
`ID`,
`Number`,
`SortPfx`,
`ID_Cart`,
`ID_Pull`,
`ID_Buyer`,
`ID_Recip`,
`BuyerName`,
`RecipName`,
`RecipAddr`,
`PayType`,
`ID_BuyerCard`,
`ID_RecipAddr`,
`WebTotal_Merch`,
`WebTotal_Ship`,
`WebTotal_Final`,
`WhenStarted`,
`WhenPlaced`,
`WhenRevised`,
`WhenNeeded`,
`WhenClosed`
)
SELECT
`ID`,
`Number`,
`SortPfx`,
`ID_Cart`,
`ID_Pull`,
`ID_Buyer`,
`ID_Recip`,
`BuyerName`,
`RecipName`,
`RecipAddr`,
`PayType`,
`ID_BuyerCard`,
`ID_RecipAddr`,
`WebTotal_Merch`,
`WebTotal_Ship`,
`WebTotal_Final`,
`WhenStarted`,
`WhenPlaced`,
`WhenEdited`,
`WhenNeeded`,
`WhenClosed`
FROM orders
Note that "WhenEdited" was copied to "WhenRevised" in the new table, not to "WhenEdited". (2016-03-07 Update: it turns out that this can be done with a single SQL command, which MySQL Workbench can facilitate via some controls that are normally hidden in a drop-down area. Now I know...)