/search.css" rel="stylesheet" type="text/css"/> /search.js">
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

In This Package:

Public Member Functions
DybPython::db::CSVFormat Class Reference

List of all members.

Public Member Functions

def __str__

Detailed Description

Provides the format string to create the CSV line
appropriate for the field types of the low level query result description 
It looks something like::

    %s,"%s","%s",%s,%s,%s,%s,%s,"%s","%s"

Usage example::

    llc = _mysql.connection(...) 
    llc.query("select * from ...")
    result = llc.store_result()
    csvf = CSVFormat( result.describe() ) 
    for row in result.fetch_row(0):
        print str(csvf) % tuple(row)

Definition at line 193 of file db.py.


Member Function Documentation

def DybPython::db::CSVFormat::__str__ (   self)

Definition at line 212 of file db.py.

00213                      :
00214         def field_fmt(fdesc):
00215             if fdesc[1] in string_types:
00216                 return "\"%s\""
00217             return "%s"
00218         return ",".join( map(field_fmt, self) )    
00219       


The documentation for this class was generated from the following file:
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

Generated on Fri May 16 2014 09:55:40 for DybPython by doxygen 1.7.4