Fórum

How to create a new column into the database table through service.xml?

thumbnail
Abhishek Jain, modificado 7 Anos atrás.

How to create a new column into the database table through service.xml?

Regular Member Postagens: 226 Data de Entrada: 20/08/16 Postagens Recentes
I made a custom entity named School3 with some columns like id,name,location,headquarter,place. Now I want to add another column named uuid into the table. For this , I added a column into service.xml and rebuilt the service. Then tables.sql got updated with the new column but there is no effect on the database table(there is no column named uuid in the database table). Please help..thanx in advance..
thumbnail
David H Nebinger, modificado 7 Anos atrás.

RE: How to create a new column into the database table through service.xml?

Liferay Legend Postagens: 14919 Data de Entrada: 02/09/06 Postagens Recentes
Liferay does not generate table alter scripts, these are totally up to you to alter your own tables post-deployment.
thumbnail
Juan Gonzalez, modificado 7 Anos atrás.

RE: How to create a new column into the database table through service.xml?

Liferay Legend Postagens: 3089 Data de Entrada: 28/10/08 Postagens Recentes
Hi Abhishek.

Which Liferay version are you using?
thumbnail
Abhishek Jain, modificado 7 Anos atrás.

RE: How to create a new column into the database table through service.xml?

Regular Member Postagens: 226 Data de Entrada: 20/08/16 Postagens Recentes
Sorry dear, I forgot to mention the version. The version is 7.0 ga1.
thumbnail
Juan Gonzalez, modificado 7 Anos atrás.

RE: How to create a new column into the database table through service.xml?

Liferay Legend Postagens: 3089 Data de Entrada: 28/10/08 Postagens Recentes
Abhishek Jain:
Sorry dear, I forgot to mention the version. The version is 7.0 ga1.


Ok so this feature had been implemented in master branch under this LPS: https://issues.liferay.com/browse/LPS-67688.

There a Maven plugin had been created so you could add to your projects and execute tasks for cleaning your development database.