Forums

Home » Liferay Portal » English » 3. Development

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
sunil kumar biswal
service builder
July 8, 2012 4:26 AM
Answer

sunil kumar biswal

Rank: New Member

Posts: 19

Join Date: March 24, 2012

Recent Posts

hello,
i hav developed one project with service builder.but during build service i getting this code with orange color.r these errors ???????????



Note: D:\liferay-plugins-sdk-6.0.6-20110225\portlets\ServiceBuilder1-portlet\docroot\WEB-INF\service\com\test\service\CustomersLocalServiceUtil.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Hitoshi Ozawa
RE: service builder
July 8, 2012 5:34 AM
Answer

Hitoshi Ozawa

Rank: Liferay Legend

Posts: 7952

Join Date: March 23, 2010

Recent Posts

They are just warning. Are you developing fro liferay 6.0.6 or 6.1.0? Liferay sdk version has to match the liferay version you're using.

CustomersLocalServiceUtil.java uses or overrides a deprecated API.


You're probably trying to overwrite a deprecated API. Which CustomersLocalServiceUtil are you using or overwrite?
sunil kumar biswal
RE: service builder
July 8, 2012 5:51 AM
Answer

sunil kumar biswal

Rank: New Member

Posts: 19

Join Date: March 24, 2012

Recent Posts

m using liferay 6.0.6.thanks for reply.i want to delete records from the table.what r the codes i hav to write & in which implementation class i hav to write????
Hitoshi Ozawa
RE: service builder
July 8, 2012 5:57 AM
Answer

Hitoshi Ozawa

Rank: Liferay Legend

Posts: 7952

Join Date: March 23, 2010

Recent Posts

i want to delete records from the table.what r the codes i hav to write & in which implementation class i hav to write????


Which records? What implementation classes? You haven't given us any information on your custom portlet nor about your service.xml
and what you're really doing.

As a general answer, use the delete(id) method.
sunil kumar biswal
RE: service builder
July 8, 2012 7:02 AM
Answer

sunil kumar biswal

Rank: New Member

Posts: 19

Join Date: March 24, 2012

Recent Posts

my 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.test">
<author>sunil</author>
<namespace>c</namespace>

<entity name="Customers" local-service="true" remote-service="false">

<!-- PK fields -->

<column name="customerId" type="long" primary="true" />

<!-- Audit fields -->


<column name="customerName" type="String" />
<column name="address" type="String" />
<column name="state" type="String" />
<column name="pin" type="int"/>
<column name="age" type="int"/>
<column name="gender" type="String"/>




</entity>
</service-builder>
i have inserted my data .nw i want to delete data from customes table.please give me some information regarding what are the methods i hav to write to delete data from the table
Jack Bakker
RE: service builder
July 8, 2012 8:47 AM
Answer

Jack Bakker

Rank: Liferay Master

Posts: 755

Join Date: January 3, 2010

Recent Posts

service builder itself is a orm and code generation tool

are you perhaps looking for how to do CRUD through that generated ?
sunil kumar biswal
RE: service builder
July 8, 2012 9:05 AM
Answer

sunil kumar biswal

Rank: New Member

Posts: 19

Join Date: March 24, 2012

Recent Posts

Hello,
thank u sir for ur reply.yes i hav to do the crud operation.i hav already inserted data into the database.by the way i want to know how to do other operations.pl give all details.i am in a big problem
Jack Bakker
RE: service builder
July 8, 2012 9:39 AM
Answer

Jack Bakker

Rank: Liferay Master

Posts: 755

Join Date: January 3, 2010

Recent Posts

if you inserted using service builder generated Util from a portlet then you likely can find how to delete update

I recommend you pick up a book like Liferay in Action to learn the essentials before asking here in the forums for every step
Hitoshi Ozawa
RE: service builder
July 8, 2012 2:17 PM
Answer

Hitoshi Ozawa

Rank: Liferay Legend

Posts: 7952

Join Date: March 23, 2010

Recent Posts

Liferay's online developer's document does a very well explanation. Have you read it?

http://www.liferay.com/documentation/liferay-portal/6.1/development/-/ai/service-build-5