openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Patrick Linskey" <plins...@gmail.com>
Subject Re: [jira] Updated: (OPENJPA-354) DB2 casts might not incorporate VARCHAR lengths often enough
Date Fri, 07 Sep 2007 16:05:12 GMT
Hi,

> The code may miss something outside these functions. Please send your test
> case to me so I can understand the missing. Your change looks good.

I don't have a test case; while working on some unrelated changes to
DB2Dictionary, I noticed that we weren't specifying a length in a
number of places.

Out of curiosity, how did we choose 1000 for the hard-coded value? In
particular, it seems like it'd be more appropriate to use the variable
that I used, so that people could customize this if need be.

-Patrick

On 9/7/07, Teresa Kan <tckan1@gmail.com> wrote:
> Patrick,
> The VARCHAR(1000) was added in the AbstractDB2Dictionary. See the following
> constants:
>
> toUpperCaseFunction = "UPPER(CAST({0} AS VARCHAR(1000)))";
>
> toLowerCaseFunction = "LOWER(CAST({0} AS VARCHAR(1000)))";
>
> stringLengthFunction = "LENGTH({0})";
>
> concatenateFunction = "(CAST({0} AS VARCHAR(1000)))||"
>
> + "(CAST({1} AS VARCHAR(1000)))";
>
> The code may miss something outside these functions. Please send your test
> case to me so I can understand the missing. Your change looks good.
>
> Thanks,
>
> Teresa
>
>
>
> On 9/6/07, Patrick Linskey (JIRA) <jira@apache.org> wrote:
> >
> >
> >     [
> > https://issues.apache.org/jira/browse/OPENJPA-354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel]
> >
> > Patrick Linskey updated OPENJPA-354:
> > ------------------------------------
> >
> >    Attachment: OPENJPA-354.patch
> >
> > > DB2 casts might not incorporate VARCHAR lengths often enough
> > > ------------------------------------------------------------
> > >
> > >                 Key: OPENJPA-354
> > >                 URL: https://issues.apache.org/jira/browse/OPENJPA-354
> > >             Project: OpenJPA
> > >          Issue Type: Bug
> > >    Affects Versions: 0.9.0, 0.9.6, 0.9.7, 1.0.0
> > >            Reporter: Patrick Linskey
> > >         Attachments: OPENJPA-354.patch
> > >
> > >
> > > Based on code inspection, it looks like OpenJPA might not be including
> > VARCHAR lengths often enough.
> >
> > --
> > This message is automatically generated by JIRA.
> > -
> > You can reply to this email to add a comment to the issue online.
> >
> >
>


-- 
Patrick Linskey
202 669 5907

Mime
View raw message