Do I need to subscribe to the list?
On Thu, 2002-06-06 at 11:26, Bill Schneider wrote:
> Marty:
>
> Please send a patch to the developers' list. I agree, it doesn't make sense
> to have infinite recursion and blow up your stack if there's no primary key.
>
> -- Bill
> ----- Original Message -----
> From: "Marty Phee" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Thursday, June 06, 2002 12:11 PM
> Subject: Torque bug including 3.0-b2
>
>
> > I just ran into this with an earlier version, so I check the latest
> > download. I was trying to create the OM object from a current
> > database. The database is part of a product we bought, and is
> > horrible! Well anyway, none of the tables have primary keys. They have
> > unique keys, but no primary keys.
> >
> > What happened is that torque created the class with the object.vm, and
> > as you can see below it get into a recursive function call. Eventually
> > throwing a stack exception.
> >
> > My change was to do a "return null". I can send a diff if you want?
> >
> >
> > public ObjectKey getPrimaryKey()
> > {
> > #if ($table.PrimaryKeys.size() == 1)
> > return get${table.PrimaryKeys.get(0).JavaName}();
> > #elseif ($table.PrimaryKeys.size() > 1)
> > #set ($i = 0)
> > #foreach ($pk in $table.PrimaryKeys)
> > pks[$i] = get${pk.JavaName}();
> > #set ($i = $i +1)
> > #end
> > return comboPK;
> > #else
> > return getPrimaryKey();
> > #end
> > }
> >
> >
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
> <mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
> >
>
>
> --
> To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
>
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>