Re: [SQLObject] Re: Make table belong to a schema (PostgreSQL) without setting the whole table name?
SQLObject is a Python ORM.
Brought to you by:
ianbicking,
phd
From: Igor M. <dow...@gm...> - 2006-01-05 07:30:59
|
Hello, I am interested in implementing something like sqlmeta.schemaName =3D '...'= or sqlmeta.tablePrefix =3D '....' I haven't touched any of the sqlobject code yet except for using sqlobject... so would anyone have any suggestions where I can start looking to do this? Should be relatively simple since schemaName *is* essentially a prefix except in the CREATE INDEX scenario. Also, would mysql schemaName be better implemented as a table prefix or as = a "database" prefix? (i.e. schemaName =3D 'foo' could append a "foo." to the table name, resulting in queries going to the "foo" database in mysql?). Thanks, Igor On 31 Dec 2005 09:33:38 -0200, Jorge Godoy <go...@ie...> wrote: > > Oleg Broytmann <ph...@ma...> writes: > > > On Fri, Dec 30, 2005 at 12:01:12AM -0600, Igor Murashkin wrote: > > > When using PostgreSQL, I noticed you can do > > > > > > class sqlmeta: > > > table =3D 'schemaname.tablename' > > > > > > However, this almost defeats the purpose of the tablename being > > > automatically generated from the class name. Is there a way to specif= y > a > > > schema name, or maybe a prefix? How about some kind of namespace to > use the > > > schema? > > Besides that, it also causes problems when generating indexes because it > puts > the table name as a prefix and PostgreSQL doesn't accept "CREATE INDEX > schemaname.tablename_name_of_index ..." as valid. > > > -- > Jorge Godoy <go...@ie...> > > "Quidquid latine dictum sit, altum sonatur." > - Qualquer coisa dita em latim soa profundo. > - Anything said in Latin sounds smart. > > > > ------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. Do you grep through log > files > for problems? Stop! Download the new AJAX search engine that makes > searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! > http://ads.osdn.com/?ad_id=3D7637&alloc_id=3D16865&op=3Dclick > _______________________________________________ > sqlobject-discuss mailing list > sql...@li... > https://lists.sourceforge.net/lists/listinfo/sqlobject-discuss > |