For Programmers: Free Programming Magazines  


Home > Archive > Java Beans > February 2005 > invalid SQL generated









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author invalid SQL generated
Dick Dijk

2005-02-01, 8:58 pm

I have an EntityBean mapped to an Oracle view, the view has no primary key.

When I try to access the data in the view ( read-only) invalid SQL is
generated:
SELECT DISTINCT FROM ws_personen t0_o WHERE (t0_o.AANHEF = 'MR')

You see: no column names!

Any idea how to fix this. Do I have to set specific things in the DD?

Dick
Marek Lange

2005-02-04, 8:57 pm

Dick Dijk wrote:

> I have an EntityBean mapped to an Oracle view, the view has no primary key.
>
> When I try to access the data in the view ( read-only) invalid SQL is
> generated:
> SELECT DISTINCT FROM ws_personen t0_o WHERE (t0_o.AANHEF = 'MR')
>
> You see: no column names!
>
> Any idea how to fix this. Do I have to set specific things in the DD?


Perhaps you forgot the declare your primary key for that entity in your
deployment descriptor?

..marek
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com