cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Frank Zhu (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CAY-1731) how to fetch the data from the related tables by checking the condition on second table column?
Date Fri, 05 Oct 2012 03:59:47 GMT

    [ https://issues.apache.org/jira/browse/CAY-1731?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13470006#comment-13470006
] 

Frank Zhu commented on CAY-1731:
--------------------------------

You can achieve this by using SQLTemplate or named query in cayenne
                
> how to fetch the data from the related tables by checking the condition on second table
column?
> -----------------------------------------------------------------------------------------------
>
>                 Key: CAY-1731
>                 URL: https://issues.apache.org/jira/browse/CAY-1731
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Database integration
>    Affects Versions: 3.1M3
>         Environment: Struts2.3 with Apache cayenne and MySql database
>            Reporter: Sampath
>            Priority: Critical
>             Fix For: 3.1 (final)
>
>
> I am using apache cayenne 3.X with Struts2.3.4 version
> I have query:
> 	SELECT * FROM t_task_assignment_detail t0 where t0.user_id=112 and exists (select 'X'
from t_task_transaction_detail t1 where t1.id = t0.task_transaction_id and t1.task_status='INPROGRESS')

> In the above query the two tables having the relationship.
> T_task_transaction_detail
> T_task_assignement_detail
> I want fetch the data from T_task_assignement_detail table where task_status is “inprogress”.
> Now I am using the above query to fetch the data but how to achieve the same using cayenne?
> Thanks,
> Sampath Uppula.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message