掲示板

When Service Builder's tables are created in database?

thumbnail
12年前 に Kravchenko Dmitry によって更新されました。

When Service Builder's tables are created in database?

Regular Member 投稿: 139 参加年月日: 10/10/04 最新の投稿
I have deleted a table of my service from (MySQL) database. And now have portlet error messages that table is not exist. How to initiate recreation? I had never created service tables manually. They were created automatically but now stopped.
12年前 に Jhansi Rani によって更新されました。

RE: When Service Builder's tables are created in database?

Junior Member 投稿: 32 参加年月日: 11/07/27 最新の投稿
Hi,

just follow ant commands build-db,clean,compile,deploy .
May be it works.

Regards
Jhansi P.
thumbnail
12年前 に Amos Fong によって更新されました。

RE: When Service Builder's tables are created in database?

Liferay Legend 投稿: 2047 参加年月日: 08/10/07 最新の投稿
I would suggest to create it manually (you can find the non-DB specific SQL from tables.sql) because it's the least intrusive way.

But if you want Liferay to do it automatically, what you can do is run this SQL:

delete from ServiceComponent where buildnamespace = '[your portlet table's namespace]';

Then on redeploy it will act as if your portlet has never been deployed before and try to create the tables. If done this way, I would backup your DB first.
thumbnail
12年前 に Hitoshi Ozawa によって更新されました。

RE: When Service Builder's tables are created in database?

Liferay Legend 投稿: 7942 参加年月日: 10/03/24 最新の投稿
I think it's better to delete a row from the ServiceComponent table because generated SQL command doesn't work without modification such as datatype and data length.
thumbnail
12年前 に Nagendra Kumar Busam によって更新されました。

RE: When Service Builder's tables are created in database?

Liferay Master 投稿: 678 参加年月日: 09/07/07 最新の投稿
Even i prefer doing it by delete a row from the ServiceComponent table

I have question regarding service builder (deleting a column from table/entity @ later stages not reflecting in DB )

Here is my use case

- suppose i have a created a table through service builder with suppose three columns like col1,col2,col3
- Later due to dependency on some external system table structure has been changed like deleted col3

I have not see this change will be reflecting in DB automatically. BTW i am using 5.2 EE SP3 right now (I have not checked this with latest version though)

Regards,
- Nagendra Kumar
thumbnail
9年前 に Charles Riley によって更新されました。

RE: When Service Builder's tables are created in database?

New Member 投稿: 5 参加年月日: 15/03/25 最新の投稿
hey thanks! this really helped me.
7年前 に Nicolas Rudelle によって更新されました。

RE: When Service Builder's tables are created in database?

New Member 投稿: 1 参加年月日: 17/02/15 最新の投稿
Thanks a lot !
thumbnail
12年前 に Aritz Galdos によって更新されました。

RE: When Service Builder's tables are created in database?

Expert 投稿: 416 参加年月日: 07/05/15 最新の投稿
Hi Kravchenko

In case Jhansi's method doesn´t work you can do as follows:

Liferay will not (re)create tables of your portlet as far as Liferay thinks they are already created. And why does Liferay think they are created? Just have a look to "servicecomponent" table. There will be some rows that refer in the buildNamespace to yours. This is why Liferay still thinks you component is already created.

Just delete rows refering to your component. The restart portal. And redeploy.

good luck!
thumbnail
12年前 に Tejas Kanani によって更新されました。

RE: When Service Builder's tables are created in database?

Liferay Master 投稿: 654 参加年月日: 09/01/06 最新の投稿
Try by deleting an entry from servicecomponent table. And redeploy your portlet.

delete FROM servicecomponent where buildNamespace="<your table namespace>"


Regards,
Tejas Kanani
11年前 に Uday Manvar によって更新されました。

RE: When Service Builder's tables are created in database?

New Member 投稿: 2 参加年月日: 13/01/31 最新の投稿
Thanks Tejas Kanani

your message will be helpfull to me.
thumbnail
12年前 に Kravchenko Dmitry によって更新されました。

RE: When Service Builder's tables are created in database?

Regular Member 投稿: 139 参加年月日: 10/10/04 最新の投稿
Thanks for telling about service component table!!! This is what I was looking for!
thumbnail
5年前 に Goran Marinkovic によって更新されました。

RE: When Service Builder's tables are created in database?

New Member 投稿: 12 参加年月日: 18/03/27 最新の投稿
You must delete references in both table : servicecomponent & release_

for those who do not know, go to the DB to query the table above servicecomponent and than chose right click, and than Scripts and than Select ... or
SELECT <names of columns> FROM <name of table>;
example:
SELECT name, subject, mark FROM students;
and than "thunder"

you can see that their are some reference with your name of project (buildnamespace, example college) but not a name of table

You delete this :

DELETE FROM public.servicecomponent WHERE <condition>;
example:
DELETE FROM public.servicecomponent WHERE buildnamespace='college';
and you will see that if you Select... again , there are not any ref with your name

And this is a half of work,

second is that you do the same but on the other table release_


after that you can start server on clipse and you will see that now in DB is one table more but empty, you can fill it on page with input details or ...

best regards from Serbia