Foros de discusión

Lost data on existing tables when re-deploy service builder on Liferay 6.1

Joe D, modificado hace 11 años.

Lost data on existing tables when re-deploy service builder on Liferay 6.1

New Member Mensajes: 12 Fecha de incorporación: 19/04/12 Mensajes recientes
Hi,

I'm using SB on Liferay 6.1. Every time I added new tables and re-deploy the service builder all data on existing tables were deleted. Does anyone know if the service builder drop the tables and re-create them? Do I need to modify the table.sql in the sql folder and remove "create" on existing tables or is there a config that I could set up?

Thanks in advantage.
thumbnail
Sushil Kumar Saini, modificado hace 11 años.

RE: Lost data on existing tables when re-deploy service builder on Liferay

Regular Member Mensajes: 104 Fecha de incorporación: 27/07/11 Mensajes recientes
Hi Joe,

SB generates the properties file service.properties in the src directory of your service. You can set the following property in this file to false so that it will not update the schema.


build.auto.upgrade=false


And it is recommended don't modify the service.properties file directly. Create a service-ext.properties file in the src folder. And add the property build.auto.upgrade to file set it to false.

Cheers
Sushil Saini
Joe D, modificado hace 11 años.

RE: Lost data on existing tables when re-deploy service builder on Liferay

New Member Mensajes: 12 Fecha de incorporación: 19/04/12 Mensajes recientes
Thanks Sushil