Docs for DAL.executesql

[ Python Tutorial ] [ Python Libraries ] [ web2py epydoc ]

Description


<type 'instancemethod'>






















placeholders is optional and will always be None when using DAL.
If using raw SQL with placeholders, placeholders may be
a sequence of values to be substituted in
or
, (if supported by the DB driver), a dictionary with keys
matching named placeholders in your SQL.

Added 2009-12-05 "as_dict" optional argument. Will always be
None when using DAL. If using raw SQL can be set to True
and
the results cursor returned by the DB driver will be
converted to a sequence of dictionaries keyed with the db
field names. Tested with SQLite but should work with any database
since the cursor.description used to get field names is part of the
Python dbi 2.0 specs. Results returned with as_dict=True are
the same as those returned when applying .to_list() to a DAL query.

[{
field1: value1, field2: value2}, {field1: value1b, field2: value2b}]

--
bmeredyk


Attributes


DAL.executesql.__call__ <type 'method-wrapper'> belongs to class <type 'method-wrapper'>
x.__call__(...) <==> x(...)

DAL.executesql.__class__ <type 'type'> extends (<type 'object'>,) belongs to class <type 'type'>
instancemethod(function, instance, class) Create an instance method object.

DAL.executesql.__cmp__ <type 'method-wrapper'> belongs to class <type 'method-wrapper'>
x.__cmp__(y) <==> cmp(x,y)

DAL.executesql.__delattr__ <type 'method-wrapper'> belongs to class <type 'method-wrapper'>
x.__delattr__('name') <==> del x.name

DAL.executesql.__doc__ <type 'str'> belongs to class <type 'str'>
str(object) -> string Return a nice string representation of the object. If the argument is a string, the return value is the same object.

DAL.executesql.__get__ <type 'method-wrapper'> belongs to class <type 'method-wrapper'>
descr.__get__(obj[, type]) -> value

DAL.executesql.__getattribute__ <type 'method-wrapper'> belongs to class <type 'method-wrapper'>
x.__getattribute__('name') <==> x.name

DAL.executesql.__hash__ <type 'method-wrapper'> belongs to class <type 'method-wrapper'>
x.__hash__() <==> hash(x)

DAL.executesql.__init__ <type 'method-wrapper'> belongs to class <type 'method-wrapper'>
x.__init__(...) initializes x; see x.__class__.__doc__ for signature

DAL.executesql.__new__ <type 'builtin_function_or_method'> belongs to class <type 'builtin_function_or_method'>
T.__new__(S, ...) -> a new object with type S, a subtype of T

DAL.executesql.__reduce__ <type 'builtin_function_or_method'> belongs to class <type 'builtin_function_or_method'>
helper for pickle

DAL.executesql.__reduce_ex__ <type 'builtin_function_or_method'> belongs to class <type 'builtin_function_or_method'>
helper for pickle

DAL.executesql.__repr__ <type 'method-wrapper'> belongs to class <type 'method-wrapper'>
x.__repr__() <==> repr(x)

DAL.executesql.__setattr__ <type 'method-wrapper'> belongs to class <type 'method-wrapper'>
x.__setattr__('name', value) <==> x.name = value

DAL.executesql.__str__ <type 'method-wrapper'> belongs to class <type 'method-wrapper'>
x.__str__() <==> str(x)

DAL.executesql.im_class <type 'type'> extends (<type 'dict'>,) belongs to class <type 'type'>
an instance of this class represents a database connection Example:: db = DAL('sqlite://test.db') db.define_table('tablename', Field('fieldname1'), Field('fieldname2'))

DAL.executesql.im_func <type 'function'> belongs to class <type 'function'>
placeholders is optional and will always be None when using DAL. If using raw SQL with placeholders, placeholders may be a sequence of values to be substituted in or, (if supported by the DB driver), a dictionary with keys matching named placeholders in your SQL. Added 2009-12-05 "as_dict" optional argument. Will always be None when using DAL. If using raw SQL can be set to True and the results cursor returned by the DB driver will be converted to a sequence of dictionaries keyed with the db field names. Tested with SQLite but should work with any database since the cursor.description used to get field names is part of the Python dbi 2.0 specs. Results returned with as_dict=True are the same as those returned when applying .to_list() to a DAL query. [{field1: value1, field2: value2}, {field1: value1b, field2: value2b}] --bmeredyk

DAL.executesql.im_self <type 'NoneType'> belongs to class <type 'NoneType'>

© 2010 by Massimo Di Pierro