Did I find the right examples for you? yes no

All Samples(2070)  |  Call(1539)  |  Derive(0)  |  Import(531)
Represent a table in a database.

e.g.::

    mytable = Table("mytable", metadata, 
                    Column('mytable_id', Integer, primary_key=True),
                    Column('value', String(50))
               )

The Table object constructs a unique instance of itself based on its(more...)

src/k/i/kiwi-gtk-1.9.37/examples/search_sqlalch.py   kiwi-gtk(Download)
 
import datetime
 
import gtk
from sqlalchemy import Table, Column as SQLAColumn, DynamicMetaData, create_engine, \
meta = DynamicMetaData()
 
category_table = Table('category', meta,
    SQLAColumn('id', Integer, primary_key=True, autoincrement=True),
    SQLAColumn('name', String),
mapper(Category, category_table)
 
task_table = Table('task', meta,
    SQLAColumn('id', Integer, primary_key=True, autoincrement=True),
    SQLAColumn('title', String),

src/s/y/synthesis-1.1061/synthesis/dbobjects.py   synthesis(Download)
#!/usr/bin/env python
 
from sqlalchemy import create_engine, Table, Column, Integer, String, Boolean, MetaData, ForeignKey
from sqlalchemy.orm import sessionmaker, mapper, relation, clear_mappers
from sqlalchemy.types import DateTime, Date
    def system_configuration_map(self):
        table_metadata = MetaData(bind=self.pg_db_engine)
        #table_metadata = MetaData(bind=self.sqlite_db)
        system_configuration_table = Table(
        'sender_system_configuration', 
    def service_event_map(self):
        table_metadata = MetaData(bind=self.pg_db_engine)
        service_event_table = Table(
        'service_event',
        table_metadata,
    def need_map(self):
        table_metadata = MetaData(bind=self.pg_db_engine)
        need_table = Table(
        'need',
        table_metadata,
    def site_service_participation_map(self):
        table_metadata = MetaData(bind=self.pg_db_engine)
        site_service_participation_table = Table(
        'site_service_participation',
        table_metadata,

src/s/q/sqlalchemy-HEAD/examples/vertical/dictlike.py   sqlalchemy(Download)
 
if __name__ == '__main__':
    from sqlalchemy import (MetaData, Table, Column, Integer, Unicode,
        ForeignKey, UnicodeText, and_, not_)
    from sqlalchemy.orm import mapper, relation, create_session
 
    # Here we have named animals, and a collection of facts about them.
    animals = Table('animal', metadata,
                    Column('id', Integer, primary_key=True),
                    Column('name', Unicode(100)))
 
    facts = Table('facts', metadata,

src/w/e/Werkzeug-0.8.3/examples/plnt/database.py   Werkzeug(Download)
    :license: BSD.
"""
from sqlalchemy import MetaData, Table, Column, ForeignKey, Boolean, \
     Integer, String, DateTime
from sqlalchemy.orm import dynamic_loader, scoped_session, create_session, \
 
 
blog_table = Table('blogs', metadata,
    Column('id', Integer, primary_key=True),
    Column('name', String(120)),
)
 
entry_table = Table('entries', metadata,
    Column('id', Integer, primary_key=True),
    Column('blog_id', Integer, ForeignKey('blogs.id')),

src/s/q/sqlalchemy-HEAD/examples/inheritance/polymorph.py   sqlalchemy(Download)
from sqlalchemy import MetaData, Table, Column, Integer, String, ForeignKey
from sqlalchemy.orm import mapper, relation, create_session
import sets
 
# this example illustrates a polymorphic load of two classes
 
# a table to store companies
companies = Table('companies', metadata, 
   Column('company_id', Integer, primary_key=True),
   Column('name', String(50)))
 
# we will define an inheritance relationship between the table "people" and "engineers",
# and a second inheritance relationship between the table "people" and "managers"
people = Table('people', metadata, 
   Column('type', String(30)))
 
engineers = Table('engineers', metadata, 
   Column('person_id', Integer, ForeignKey('people.person_id'), primary_key=True),
   Column('status', String(30)),
   Column('engineer_name', String(50)),
   Column('primary_language', String(50)),
  )
 
managers = Table('managers', metadata, 

src/s/q/SQLAlchemy-0.7.10/examples/vertical/dictlike-polymorphic.py   SQLAlchemy(Download)
 
if __name__ == '__main__':
    from sqlalchemy import (MetaData, Table, Column, Integer, Unicode,
        ForeignKey, UnicodeText, and_, not_, or_, String, Boolean, cast, text,
        null, case, create_engine)
    metadata = MetaData()
 
    animals = Table('animal', metadata,
                    Column('id', Integer, primary_key=True),
                    Column('name', Unicode(100)))
 
    chars = Table('facts', metadata,

src/b/o/bots-HEAD/trunk/botsup/bots/modelstandalone.py   bots(Download)
from sqlalchemy import Table, Column, ForeignKey,String, Unicode, Integer, DateTime, Boolean, TIMESTAMP,PassiveDefault,text
from sqlalchemy.orm import relation
 
from bots.botsglobal import metadata, mapper
import bots.model as model
 
#*****************************************************************************
#*******Orders (well...order-desadv-invoic) **********************************
orderhead = Table(
    'orderhead', metadata,
 
orderline = Table(
    'orderline', metadata,
    Column('tr_id',Unicode(35),primary_key=True), 
    Column('linenr',Unicode(35),primary_key=True),

src/s/q/SQLAlchemy-0.7.10/examples/large_collection/large_collection.py   SQLAlchemy(Download)
 
from sqlalchemy import (MetaData, Table, Column, Integer, String, ForeignKey,
                        create_engine)
from sqlalchemy.orm import (mapper, relationship, sessionmaker)
 
 
meta = MetaData()
 
org_table = Table('organizations', meta,
    mysql_engine='InnoDB')
 
member_table = Table('members', meta,
    Column('member_id', Integer, primary_key=True),
    Column('member_name', String(50), nullable=False, key='name'),

src/s/q/sqlalchemy-HEAD/examples/large_collection/large_collection.py   sqlalchemy(Download)
 
from sqlalchemy import (MetaData, Table, Column, Integer, String, ForeignKey,
                        create_engine)
from sqlalchemy.orm import (mapper, relation, sessionmaker)
 
 
meta = MetaData()
 
org_table = Table('organizations', meta, 
    mysql_engine='InnoDB')
 
member_table = Table('members', meta,
    Column('member_id', Integer, primary_key=True),
    Column('member_name', String(50), nullable=False, key='name'),

src/s/q/sqlalchemy-HEAD/examples/vertical/dictlike-polymorphic.py   sqlalchemy(Download)
 
if __name__ == '__main__':
    from sqlalchemy import (MetaData, Table, Column, Integer, Unicode,
        ForeignKey, UnicodeText, and_, not_, or_, String, Boolean, cast, text,
        null, case)
    metadata = MetaData()
 
    animals = Table('animal', metadata,
                    Column('id', Integer, primary_key=True),
                    Column('name', Unicode(100)))
 
    chars = Table('facts', metadata,

  1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9  Next