Foros de discusión
Service Builder needs to generate the SQL to create the tables
Debasis Padhi, modificado hace 11 años.
Service Builder needs to generate the SQL to create the tables
Junior Member Mensajes: 54 Fecha de incorporación: 23/03/12 Mensajes recientes
Step 1 : Create a file name as service.xml in the WEB-INF folder
Step 2 : Write the following
service.xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE service-builder PUBLIC
"-//Liferay//DTD Service Builder 6.0.0//EN"
"http://www.liferay.com/dtd/liferay-service-builder_6_0_0.dtd">
<service-builder package-path="com.name.portlets.package"> <!-- as your require package structure you want -->
<namespace>servicebuilder</namespace> <!-- prefix of the table -->
<entity name="Table_Name" local-service="true" remote-service="false"> <!-- entry name is name of table -->
<column name="Column_One" type="long" primary="true" id-type="identity" /> <!--column fields in table-->
<column name="Column_Two" type="String"></column>
<column name="Column_Three" type="String"></column>
</entity>
</service-builder>
Step 3 : Start the Ant build service in build .xml of project
then it will create the tables in the database and as well as create the java code in project with respective package structure
Step 2 : Write the following
service.xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE service-builder PUBLIC
"-//Liferay//DTD Service Builder 6.0.0//EN"
"http://www.liferay.com/dtd/liferay-service-builder_6_0_0.dtd">
<service-builder package-path="com.name.portlets.package"> <!-- as your require package structure you want -->
<namespace>servicebuilder</namespace> <!-- prefix of the table -->
<entity name="Table_Name" local-service="true" remote-service="false"> <!-- entry name is name of table -->
<column name="Column_One" type="long" primary="true" id-type="identity" /> <!--column fields in table-->
<column name="Column_Two" type="String"></column>
<column name="Column_Three" type="String"></column>
</entity>
</service-builder>
Step 3 : Start the Ant build service in build .xml of project
then it will create the tables in the database and as well as create the java code in project with respective package structure
Prakash Khanchandani, modificado hace 11 años.
RE: Service Builder needs to generate the SQL to create the tables
Expert Mensajes: 329 Fecha de incorporación: 10/02/11 Mensajes recientes
It will create the tables only when the portlet or hook containing this service is deployed.
Hitoshi Ozawa, modificado hace 11 años.
RE: Service Builder needs to generate the SQL to create the tables
Liferay Legend Mensajes: 7942 Fecha de incorporación: 24/03/10 Mensajes recientesthen it will create the tables in the database and as well as create the java code in project with respective package structure
It will create a sql commands under the sql directory.