OpenStructure
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Data Structures | Functions
ost.table Namespace Reference

Data Structures

class  BinaryColExpr
 
class  TableCol
 
class  TableRow
 
class  Table
 

Functions

def MakeTitle
 
def IsStringLike
 
def IsNullString
 
def IsScalar
 
def GuessColumnType
 
def Merge
 

Function Documentation

def ost.table.GuessColumnType (   iterator)

Definition at line 38 of file table.py.

def ost.table.IsNullString (   value)

Definition at line 23 of file table.py.

def ost.table.IsScalar (   value)

Definition at line 27 of file table.py.

def ost.table.IsStringLike (   value)

Definition at line 14 of file table.py.

def ost.table.MakeTitle (   col_name)

Definition at line 11 of file table.py.

def ost.table.Merge (   table1,
  table2,
  by,
  only_matching = False 
)
Returns a new table containing the data from both tables. The rows are 
combined based on the common values in the column(s) by. The option 'by' can
be a list of column names. When this is the case, merging is based on
multiple columns.
For example, the two tables below

==== ====
x     y            
==== ====
 1    10
 2    15
 3    20
==== ====

==== ====
x     u
==== ====
  1  100
  3  200
  4  400
==== ====

when merged by column x, produce the following output:

===== ===== =====
x      y     u
===== ===== =====
1      10    100
2      15    None
3      20    200
4      None  400
===== ===== =====

Definition at line 3130 of file table.py.