Jahia Template Forum > SQL2 JOIN in template

0 (0 Good)
0 (0 Bad)

SQL2 JOIN in template

by  gushil »  2012/10/04 07:01

Hello All,

I made a page to show all news content created by current login user. This is accomplished by using this jcr query in template :

select * from [jnt:news] as news where news.[jcr:createdBy]='${currentUser.name}' order by news.[date] desc

I have a question, how to get all news content created by user who has lastname such as Beckham? Can I join [jnt:news] with [jnt:user]? How?

Thanks

  (gushil)

Number of messages  1
Registration date
0 (0 Good)
0 (0 Bad)

Re: SQL2 JOIN in template

by  faissah »  2012/10/12 21:47

Hello,

You can use JOIN in SQL2. Have you taken a look at this apache documentation?

HERE

Regards,
Fabrice

Fabrice  (faissah)

Number of messages  262
Registration date
Contact
Share
Feedback

Get in touch

Whether you are a current user or if you are just evaluating Jahia, we are here to help.

Contact us

Share this page