Home » Liferay Portal » English » 3. Development

Combination View Flat View Tree View
Threads [ Previous | Next ]
Edson Lek Ma
Indexing Implementation in Join Table
December 21, 2012 5:44 AM

Edson Lek Ma

Rank: New Member

Posts: 6

Join Date: July 28, 2011

Recent Posts


How ar you? I want to ask if there's possibility to Index (using liferay lucene) a join table in Liferay.

My entity is showed ahead (got from my servive.xml):
<entity name="SistemaProducao_Topico_Conteudo" cache-enabled="false" remote-service="false" local-service="true">
<column name="relationId" type="long" primary="true" />
<column name="companyId" type="long" />
<column name="groupId" type="long" />
<column name="sistemaProducaoId" type="long" primary="true"/>
<column name="topicoId" type="long" primary="true" />
<column name="ordem" type="long" />
<column name="content_html" type="String" />


I implemented the Indexing class :
public class SPTopicoConteudoIndexer extends BaseIndexer { ... }

And put all configurations in portlet.xml and liferay-portlet.xml to make that model looks like a Portlet to be indexed.

After that, when I call the indexing methods... it shows Cast Exceptions. java.lang.ClassCastException: cannot be cast to java.lang.Long ........

Are there any way to do that?

Thanks in Advance