User Tools

Site Tools


playground:playground

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
playground:playground [2025/01/06 07:32] – [Examples] yuriiplayground:playground [2025/01/06 08:15] (current) yurii
Line 1: Line 1:
-{{ transformations:RenameColumnsAction.png}} +{{ transformations:naturalmerge.png}} 
-====== RENAME COLUMNS ====== +====== NATURAL MERGE ====== 
-Category: Transform / Basic\\+Category: Transform / Advanced\\
  
 \\  \\ 
 =====Description===== =====Description=====
-This action changes the name of one or more columns.+This action merges two tables based on columns with the same name.
  
-Duplicating names are not allowed.\\+\\  
 +=====Examples===== 
 +**Example #1:**\\  
 +>Perform a //natural merge// on the following tables, based on their matching columns.\\ 
 + 
 +**Before (source table):** 
 + 
 +>**Table 1:** Names with addresses 
 + 
 +^FirstName  ^LastName  ^Address 
 +|Robert |Smith |123 Any Street | 
 +|Julie |Rodriguez |999 South Street | 
 +|Tammy |Thomas |454 North Avenue | 
 + 
 + 
 +>**Table 2:** Names with contact information\\ 
 + 
 +^FirstName  ^LastName  ^PhoneNum  ^Email ^ 
 +|Julie |Rodriguez |222-222-2222 |julie@myemail.com | 
 +|Tammy |Thomas |333-333-3333 |tammy@myemail.com | 
 +|Robert |Smith |111-111-1111 |robert@myemail.com |
  
 \\  \\ 
-=====Action settings===== +**After (result table):** 
-^Setting^Description+^FirstName  ^LastName  ^Address  ^PhoneNum  ^Email 
-|Column|Select the existing column name in the left drop-down+|Robert |Smith |123 Any Street |111-111-1111 |robert@myemail.com 
-|To|Specify the new column name in the right text box.| +|Julie |Rodriguez |999 South Street |222-222-2222 |julie@myemail.com 
-Additional columns can be renamed by clicking the //Rename more columns// option.+|Tammy |Thomas |454 North Avenue |333-333-3333 |tammy@myemail.com |
  
 \\  \\ 
-=====Examples=====+**Action parameters:**
  
-====Example #1====   +Other table is "Table 2" 
->Rename the column "Continentto the new column name "Location".+> Mode is "Lookup"
  
-===Before (source table)=== +\\ \\  
 +**EXAMPLE #2:**  Perform a //natural merge// on the following tables.  Note that the tables //do not contain any matching column names//.
  
-^River  ^Length (km)  ^Length (miles)  ^Continent  ^ +\\ 
-| Nile  |  6650|  4132|Africa +**Table 1:** Names with addresses\\
-| Amazon  |  6400|  3976|South America +
-| Yangtze  |  6300|  3917|Asia +
-| Mississippi  |  6275|  3902|North America  |+
  
-===After (result table)===+^FirstName  ^LastName  ^Address 
 +|Robert |Smith |123 Any Street | 
 +|Julie |Rodriguez |999 South Street | 
 +|Tammy |Thomas |454 North Avenue |
  
-^River  ^Length (km)  ^Length (miles)  ^**Location**  +\\ 
-Nile   6650 4132|**Africa**  +**Table 2:** Names with contact information\\ 
-Amazon   6400 3976|**South America**  + 
-Yangtze   6300 3917|**Asia** +^FName  ^LName  ^PhoneNum  ^Email 
-| Mississippi  |  6275|  3902|**North America**  |+|Julie |Rodriguez |222-222-2222 |julie@myemail.com 
 +|Tammy |Thomas |333-333-3333 |tammy@myemail.com 
 +|Robert |Smith |111-111-1111 |robert@myemail.com |
  
 \\  \\ 
-===Action parameters:===+**Action parameters:**
  
- Columns to rename: Continent +Other table is "Table 2" 
- Rename to: Location+Mode is "Lookup"
  
 \\  \\ 
-====Community examples==== +**Result:**\\ 
-  * [[https://community.easymorph.com/t//1273/6|Split Excel spreadsheets into multiple spreadsheets]] ([[https://community.easymorph.com/uploads/short-url/6iWYdZJc4yAvqYMbTGZWXtVFmvL.morph|Project]]; Module: //Main//; Group: //Tab 1//; Table: //Table 1//; Action position: //3//) +^FirstName  ^LastName  ^Address  ^FName  ^LName  ^PhoneNum  ^Email ^ 
-  * [[https://community.easymorph.com/t//1649/14|Update existing data in a database table]] ([[https://community.easymorph.com/uploads/short-url/hauw3ZALjf9UqXAOP8prtLUNbxH.morph|Project]]; Module: //Main//; Group: //Tab 1//; Table: //Where clause//; Action position: //5//) +|Robert |Smith |123 Any Street |  |  |  |  
-  * [[https://community.easymorph.com/t//1686/2|Aggregation of consecutive date ranges]] ([[https://community.easymorph.com/uploads/short-url/xyC5nPd52hGrMiRXjp5w1RVUTYL.morph|Project]]; Module: //Main//; Group: //Tab 1//; Table: //Easymorph Patient Example Data.xlsx//;\\ Action position: //12//) +|Julie |Rodriguez |999 South Street |   |  |  
-  * [[https://community.easymorph.com/t//1854/2|Product of Rows in a Column]] ([[https://community.easymorph.com/uploads/short-url/8o7F1FHzlEr0hUV2BgCLFNEMKqk.morph|Project]]; Module: //Main//; Group: //Tab 1//; Table: //Initial state//; Action position: //2//) +|Tammy |Thomas |454 North Avenue |    |  | 
-  * [[https://community.easymorph.com/t//2156/1|How to process parent-child data structures]] ([[https://community.easymorph.com/uploads/short-url/zmylfn4Qr0ovzu3e5rybl0LVMNG.morph|Project]]; Module: //Module 1//; Group: //Tab 1//; Table: //Longest folder path//; Action position: //9//) + 
-  * [[https://community.easymorph.com/t//2646/4|Iterate same row in table a known number of times]] ([[https://community.easymorph.com/uploads/short-url/vfoRlVfxozi5f8GpH7ISOtSsquO.morph|Project]]; Module: //Main//; Group: //Group 1//; Table: //Table 1//; Action position: //7//)+ 
 + 
 + 
 +\\ 
 +=====Use cases===== 
 +Use this action auto-merge two tables without having to manually select specific columns.
  
 \\  \\ 
-=====Shortcuts===== +=====Action settings===== 
-Fast ways to create the action:\\+^Setting ^Description ^ 
 +|Other table |Select the second table to merge into the current dataset. | 
 +|Mode |Options:\\ //Lookup// (for each row in this table, get any one matching row from the other table and ignore other rows),\\ //Inner join// (mere only rows with values that exist in both tables),\\ //Left join// (for each row get all matching rows from the other table),\\ //Full join// (merge all matching and non-matching rows from the other table).|
  
-  *Right-click on the column heading and select //Rename...// from the context menu+\\  
-  *Click the drop-down arrow in the column heading and select //Rename...// from the context menu.+=====Remarks===== 
 +Merges are based on column names that match //precisely// between the two tables.  All columns, aside from the matching columns, are appended to the original dataset based on matching values
 + 
 +If there are no matching columns between the two tables, all columns from the //other table// will be appended to the original table, without values.
  
  
Line 64: Line 97:
 =====See also===== =====See also=====
  
-  * [[transformations:keepremovecolumns|Keep/Remove columns]] +  * [[transformations:crossmerge|Cross merge]] 
-  * [[transformations:replacecolumns|Modify column(s)]] +  * [[transformations:intervalmerge|Interval merge]] 
-  * [[transformations:reorder|Reorder columns]] +  * [[transformations:merge|Merge another table]]
playground/playground.txt · Last modified: by yurii

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki