>> > I assume you have a reason not to use:
>> >
>> > class x(SQLObject):
>> > ys = ForeignKey( 'y' )
>>
>> Well, in the real life example I have the two objects 'x' and 'y' are
>> kinda like 'article' and 'tag'. A tag can be attached to several
>> articles and an article can have several tags
On Mon, Nov 11, 2013 at 09:57:53AM +0100, Daniel Fetchinson
wrote:
> On 11/11/13, Simon Cross wrote:
> > I assume you have a reason not to use:
> >
> > class x(SQLObject):
> > ys = ForeignKey( 'y' )
>
> Well, in the real life example I have the two objects 'x' and 'y' are
> kinda like 'arti
On 11/11/13, Simon Cross wrote:
> I assume you have a reason not to use:
>
> class x(SQLObject):
> ys = ForeignKey( 'y' )
Well, in the real life example I have the two objects 'x' and 'y' are
kinda like 'article' and 'tag'. A tag can be attached to several
articles and an article can have sev
>> Perhaps it is by design but I was kind of surprised to see that if I have
>>
>> class x(SQLObject):
>> ys = RelatedJoin( 'y' )
>>
>> class y(SQLObject):
>>
>>
>> then I'm allowed to add several times the same 'y' object to 'x' via
>>
>> myx = x.get( 1 )
>> myy = y.get( 1 )
>> x.addY
I assume you have a reason not to use:
class x(SQLObject):
ys = ForeignKey( 'y' )
?
--
November Webinars for C, C++, Fortran Developers
Accelerate application performance with scalable programming models. Explore
tec
Hi!
On Sun, Nov 10, 2013 at 10:21:21PM +0100, Daniel Fetchinson
wrote:
> Perhaps it is by design but I was kind of surprised to see that if I have
>
> class x(SQLObject):
> ys = RelatedJoin( 'y' )
>
> class y(SQLObject):
>
>
> then I'm allowed to add several times the same 'y' ob
On Sat, May 17, 2008 at 07:24:57PM +0200, Luis Javier Peris wrote:
> Thanks for the accurate answer, it have a lot of sense to have an add method
> but I didn't know that it existed.
>
> 2008/5/17 Oleg Broytmann <[EMAIL PROTECTED]>:
> > term.addQuestion(q)
> >
> > or
> >
> > q.addTerm(term)
Thanks for the accurate answer, it have a lot of sense to have an add method
but I didn't know that it existed.
2008/5/17 Oleg Broytmann <[EMAIL PROTECTED]>:
> On Sat, May 17, 2008 at 01:59:03AM +0200, Luis Javier Peris wrote:
> > 'm working with SQLObject and I'm getting frustated because of lac
Thanks for the example.
2008/5/17 Luke Opperman <[EMAIL PROTECTED]>:
>
> First off, let me say I feel RelatedJoin and MultipleJoin should be
> deprecated
> to be renamed RawRelatedJoin/RawMultipleJoin, there are two better
> alternatives
> available since at least 0.8:
> * SQLRelatedJoin and SQL
On Sat, May 17, 2008 at 01:59:03AM +0200, Luis Javier Peris wrote:
> 'm working with SQLObject and I'm getting frustated because of lack of
> examples. First of all, I'm having problems creating tables with
> many-many relationships
> by means of RelatedJoin. I want to create and know how work the
First off, let me say I feel RelatedJoin and MultipleJoin should be deprecated
to be renamed RawRelatedJoin/RawMultipleJoin, there are two better alternatives
available since at least 0.8:
* SQLRelatedJoin and SQLMultipleJoin
* ManyToMany and OneToMany
Yes, the docs need a massive overhaul on
On Wed, Nov 21, 2007 at 12:42:58PM +0100, Bert Wesarg wrote:
> Is there an other 'join' I
> should use for the case, where I only want in one class to get a
> 'addRole' function, but not a 'addPerson' function?
No. But if you don't need addPerson - just don't call it. add*s are
symmetric, you m
On Nov 21, 2007 11:34 AM, Oleg Broytmann <[EMAIL PROTECTED]> wrote:
> On Wed, Nov 21, 2007 at 11:07:01AM +0100, Bert Wesarg wrote:
> > Note, the only difference is the name of the second table. but in the
> > second case the table 'bla_person' is not created.
>
>SQLObject sorts RelatedJoins tab
On Wed, Nov 21, 2007 at 11:07:01AM +0100, Bert Wesarg wrote:
> Note, the only difference is the name of the second table. but in the
> second case the table 'bla_person' is not created.
SQLObject sorts RelatedJoins tables alphabetically to avoid creating
the same intermediate table twice... and
Fred C escribió:
> Hi,
>
> I have a class User and I want to have a friends relation ship
> between users in that table.
> Is it possible to do it like in the snippet bellow. Is there a better
> way to do it with SQLObject?
>
> I have tested this. and it works, but this construction doesn't fee
On Mon, Aug 06, 2007 at 03:24:28PM -0500, Jim Steil wrote:
> class RailCategory(SQLObject):
> class sqlmeta:
> style = Style(longID=True)
> idName = 'railCategoryId'
>
> name = UnicodeCol(length=50)
> description = UnicodeCol()
> railCars = RelatedJoin("RailCar",
I before could not solve this problem.
Directly I was defining:
class centro(SQLObject):
_connection=connection
descripCentro=StringCol()
practicas = RelatedJoin('practica')
class practica(SQLObject):
_connection=connection
descripPractica=StringCol()
valorTotalPractica=Fl
Ah, I should have mentioned that I use Postgres 7.x with this.
I haven't used MySQL with this before.
Were you able to resolve this? What was different?
--
Rick
On Thu, 26 Oct 2006, marcelo schiavone wrote:
> Hola Rick
> I did what you said to me.
> Thank you all good worked.
>
> I worked with P
Hola Rick
I did what you said to me.
Thank you all good worked.
I worked with PostgreSQL 8.0.3 and MySQL 5.0.
In PostgreSQL it worked correctly.
In MySQL on having entered:
" PracticaCentro.createTable () "
It showed the following error:
" ProgrammingError: (1064, " You have an mistake in your
Thank you Rick.
The 'createRelatedTable' did not work but I am looking for it.
That advantages has the SQLRelatedJoin?
Regards
On 10/25/06, Rick Flosi <[EMAIL PROTECTED]> wrote:
>
> Add 'createRelatedTable=False' to your RelatedJoins like:
> practica=RelatedJoin('practica', createRelatedTa
Add 'createRelatedTable=False' to your RelatedJoins like:
practica=RelatedJoin('practica', createRelatedTable=False)
This might only be in 'SQLRelatedJoin' so you might have to use that over
'RelatedJoin'. 'SQLRelatedJoin' has some other advantages so you probably
want to use that anyways.
You could use a SQLRelatedJoin, and then do:
coll.members.count()
- Luke
Quoting Oleg Broytmann <[EMAIL PROTECTED]>:
On Thu, Apr 20, 2006 at 03:54:18PM +0300, Max Ischenko wrote:
Is there a way to use a COUNT(*) query in context like these?
There is no currently.
Oleg.
--
Oleg Bro
On Thu, Apr 20, 2006 at 03:54:18PM +0300, Max Ischenko wrote:
> Is there a way to use a COUNT(*) query in context like these?
There is no currently.
Oleg.
--
Oleg Broytmannhttp://phd.pp.ru/[EMAIL PROTECTED]
Programmers don't die, they just GOSUB withou
23 matches
Mail list logo