TupleInsertFromItem: Difference between revisions

From Planimate Knowledge Base
Jump to navigation Jump to search
(New page: == Operation == The operation will '''''insert'''''a row at the nominated position and '''''set''''' cells in that row to the item attribute vaules where the column name has the sam...)
 
No edit summary
 
Line 1: Line 1:
== Operation  ==
== Operation  ==


The operation will '''''insert'''''a row at the nominated position and '''''set''''' cells in that row to the item attribute vaules where the column name has the same name as the item attribute.  
The operation will '''''insert''''' a row at the nominated position and '''''set''''' cells in that row to the item attribute vaules where the column name has the same name as the item attribute.  


Note:  
Note:  
Line 8: Line 8:
*Matching item attribute and column names are NOT case sensitive.  
*Matching item attribute and column names are NOT case sensitive.  
*Columns that do not have a tuple match will contain the coluns default value.
*Columns that do not have a tuple match will contain the coluns default value.
'''''Report Tuple Deails''''' when pressed with load the default text reader and report the item attributes (by class if there are more than one item flow through the routine) that match the column names of the specified table.


== Example  ==
== Example  ==

Latest revision as of 15:48, 8 January 2009

Operation

The operation will insert a row at the nominated position and set cells in that row to the item attribute vaules where the column name has the same name as the item attribute.

Note:

  • Numerical values will be set regardless of the formatting of the columns (cells) or item attributes.
  • Matching item attribute and column names are NOT case sensitive.
  • Columns that do not have a tuple match will contain the coluns default value.

Report Tuple Deails when pressed with load the default text reader and report the item attributes (by class if there are more than one item flow through the routine) that match the column names of the specified table.

Example

An item has the following attributes (only):

i.ID = 1111

i.Colour = Blue

i.Size = Large

A table named Location exists as follows:

ID Name Colour Location
2345 Turner Red Hobart
3523 Lisbon Green Brighton


Applying the Routine Operation TupleInsertFromItem((t.Location.Row(2))

Would insert a row between row one and two and set the (new) second row values to the following:

ID Name Colour Location
2345 Turner Red Hobart
1111 {Default} Blue {Default}
3523 Lisbon Green Brighton

 

Note:

  • Column Location and Name will be set to the default column values as there is no item attributes called Location or Name.