[JBoss-user] [JBoss Seam] - Re: Help on converting to myfaces/tiles + JSF + EJB3 + Seam

2006-07-10 Thread gus888
Hi Gavin, Yes, I used myfaces/tiles in my project, and it is great. Now, I also want to use facelets, but I don't know whether it is possible to keep the myfaces/tiles and also use facelets functions. Thank you. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3

[JBoss-user] [JBoss Seam] - Re: Help on converting to myfaces/tiles + JSF + EJB3 + Seam

2006-07-10 Thread gus888
Petemuir and Gavin, Thank you very much for your directions, I fixed my problem after removing javax.faces.CONFIG and recoding my web.xml. I have one more question, did anyone ever combine faces/tiles with facelets? Or is it possible? Thank you. Best regards, GUS View the original post : h

[JBoss-user] [JBoss Seam] - Help on converting to myfaces/tiles + JSF + EJB3 + Seam

2006-07-06 Thread gus888
Hi everybody, I am newbie on seam and want to convert my project of myfaces/tiles + JSF + EJB3 to Seam. I worked several days, but could not figure it out. If I keep the following codes in web.xml | javax.faces.CONFIG_FILES | | /WEB-INF/faces-config.xml

[JBoss-user] [JBoss Seam] - Re: Stateful session bean vs. session Context, which one is

2006-06-29 Thread gus888
Thank you so much for your very detailed explanation. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=395#395 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=395 Using Tomcat but need to do more? Need to suppor

[JBoss-user] [JBoss Seam] - Re: Stateful session bean vs. session Context, which one is

2006-06-29 Thread gus888
Hi there, Thank you very much for your help. I want to whether the two group codes have the same functions, as follows: @PersistenceContext | private EntityManager em; @In(create=true) | private EntityManager entityManager; Thank you. View the original post : http://www.jboss

[JBoss-user] [JBoss Seam] - Stateful session bean vs. session Context, which one is bett

2006-06-29 Thread gus888
Hi all, I just begin to learn the seam technology. When learning the seam examples, I found there are two scenarioes to hold user's object, one is in issues example, which uses a sfsb "login", the other is in dvdstore, which uses a session context. I am wondering which one is better for a big p

[JBoss-user] [EJB 3.0] - Re: Migration 4.0.4.CR2 -> 4.0.4.GA problem

2006-06-26 Thread gus888
As to changing List to SortedSet on JBoss 4.0.4. GA, I found that the dvdstore example in seam 1.0.1 GA used the List: @Entity | @Table(name="ORDERS") | public class Order | implements Serializable | { | ... | List orderLines = new ArrayList(); | ... | @OneToMany(mappedBy="

[JBoss-user] [EJB 3.0] - Re: Migration 4.0.4.CR2 -> 4.0.4.GA problem

2006-06-22 Thread gus888
I have a problem after changing List to Set. Since the data type of JSF dataTable should be List, Array or ResultSet, it is a little hard to change Set back to List to be displayed by dataTable, especially for Seam @DataModel. Anybody has some good idea? Thank you. View the original post : htt

[JBoss-user] [JBoss Seam] - Seam -> Web Beans ?

2006-05-23 Thread gus888
Hi Jboss experts, Recently, I plan to use Seam on my project, but I immediately found that JBoss proposed the new std framework of Web Beans. I am wondering whether the Web Beans will replace Seam in the future or not. Thank you. GUS View the original post : http://www.jboss.com/index.html?mo

[JBoss-user] [Tomcat, HTTPD, Servlets & JSP] - Possible to use two port numbers on one Tomcat?

2006-03-27 Thread gus888
Hi all, We currently have a problem for merging two Tomcat servers to one, because the two have different port number 4040, 5050. Since we do not want to combine the two port right away(we need to notify customers), is it possible to use two port number on one tomcat server? e.g. http://tomcat.

[JBoss-user] [EJB 3.0] - Re: How to pass object of web tier to slsb in ejb tier

2006-03-25 Thread gus888
Thank you so much Scott! GUS View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3932608#3932608 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3932608 --- This SF.Net e

[JBoss-user] [EJB 3.0] - Re: How to pass object of web tier to slsb in ejb tier

2006-03-23 Thread gus888
Hi Bill, Thank you very much for your response and help. You said anonymous wrote : You need to move your utility jars outside of it. It means I need to create another utility jar? I currently have one ejb jar and a web war. Should I put the utility jar into ejb jar or a independent jar. In a

[JBoss-user] [EJB 3.0] - Re: How to pass object of web tier to slsb in ejb tier

2006-03-23 Thread gus888
Hi Asack, Thank you for your response. The partial codes shown as follows: | [web tier] | public class ManageBean implements Serializable { | | private Test test; | | public void saveTo() { | Utils.getTestDAO.save(test); | } | ... | } | | pu

[JBoss-user] [EJB 3.0] - How to pass object of web tier to slsb in ejb tier

2006-03-22 Thread gus888
Hi all, When I tried to pass a object, which contains several entity beans, from web tier to stateless session bean (DAOBean), I alway get NoClassFound exception. Somebody can give me a help on it? I really appreciate it. Thank you in advance. View the original post : http://www.jboss.com/inde

[JBoss-user] [EJB 3.0] - Is it a bug on composite primary key

2006-03-09 Thread gus888
I ever posted a same question before. I use the composite primary key for my class @Entity | @Table(name="group_members") | @IdClass(MembershipPK.class) | public class Membership implements Serializable { | | private long groupId; | private long personId; | |

[JBoss-user] [EJB 3.0] - Re: I really need a help on the issue, please.

2006-03-09 Thread gus888
Thank you very much for the responses. I am using MySQL database. In fact, I always use upper case for column name when creating tables in database. I am wondering whether the two classes' (entity and embeddable) structures are correct. Did anybody ever experience this situation (the join table

[JBoss-user] [EJB 3.0] - I really need a help on the issue, please.

2006-03-08 Thread gus888
Hi all, I have a join table Party_member: | table party_member ( | party_id int; | person_id int; | joined_on date; | } then according to a example of CategorizedItem on Hibernate in Action, I created the following entity bean: | | @Entity | @Table(name="Party_members") |

[JBoss-user] [EJB 3.0] - Re: EJB3 to RC5 context lookup confusion

2006-03-08 Thread gus888
In addition, you also need to change persistence.xml to the new struture: | | java:/DatabaseDS | | | | | | | | | | | | and it is better to change xxx.ejb3 to xxx.jar Details

[JBoss-user] [EJB 3.0] - Re: EJB3 to RC5 context lookup confusion

2006-03-08 Thread gus888
TheInterface generateInt = (TheInterface) context.lookup("XXX/TheInterface/local"); it seems the "XXX/TheInterface/local" should be "XXX/TheInterfaceBean/local". View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3928885#3928885 Reply to the post : http://www.jbo

[JBoss-user] [EJB 3.0] - Re: How to write @ManyToMany/@JoinTable if join table has th

2006-03-08 Thread gus888
Hi all, I found a little idea in the Hibernate in Action book, it is on the section of Using a collection of components for a many-to-many association in Chapter 6. It seems that I need to create a new class for the joint table. Any further suggestion is appreciated. GUS View the original pos

[JBoss-user] [EJB 3.0] - Where to define the Test class in

2006-03-07 Thread gus888
Hi all, I never found the EJB 3 is so powerful, e.g. EJBQL select new Test(id,name,...) from my question is where to define the Test class in ejb tier or web tier, and it should be pojo class, slsb or sfsb. Thank you in advance. View the original post : http://www.jboss.com/index.html?mo

[JBoss-user] [EJB 3.0] - Re: How to write @ManyToMany if join table has third attribu

2006-03-07 Thread gus888
Hi all, Sorry for my question is unclear. My question is: if join table has extra attributes besides the two foreign key (shown above), how to map its @ManyToMany code in entity bean. Thank you very much in advance. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopi

[JBoss-user] [EJB 3.0] - How to write @ManyToMany/@JoinTable if join table has third

2006-03-06 Thread gus888
Hi All, I have a question on how to write @ManyToMany and @JoinTable code, e.g. a join table is table member_party ( | member_id, | party_id, | joined_date) how to modify the following codes: @ManyToMany(cascade = {CascadeType.PERSIST, CascadeType.MERGE}, fetch = FetchType.EAGER) |@J

[JBoss-user] [EJB 3.0] - Re: When to use EAGER / LAZY

2006-03-03 Thread gus888
That's great! I got it. Thank you so much. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3927880#3927880 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3927880 --- Th

[JBoss-user] [EJB 3.0] - Re: When to use EAGER / LAZY

2006-03-03 Thread gus888
Hi, thank you very much for your response. "Writing a getFiles method in your stateless bean" means to create another EJBQL to retrieve files using the passed folder object. Is it correct? Thanks. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3927865#3927865

[JBoss-user] [EJB 3.0] - Re: When to use EAGER / LAZY

2006-03-03 Thread gus888
Thank you all for your response. What I did is: First, I use JSF session bean to call local interface of dao stateless bean to get a folder instance using a EJBQL, then call the folder.getFiles() in the JSF session bean to try to get all files under the folder. If I set fetch=FetchType.LAZY, I

[JBoss-user] [EJB 3.0] - When to use EAGER / LAZY

2006-03-02 Thread gus888
Hi all, I currently have a quesion about using the EAGER/LAZY. I have a class: | public class Folder implements Serializable { | ... | @OneToMany (mappedBy="folder", cascade=CascadeType.ALL, fetch=FetchType.LAZY) | public List getFiles() { | return files; | }

[JBoss-user] [EJB 3.0] - Re: Auto create schema ?

2006-02-28 Thread gus888
Whether you may try CREATE at first, after import data.sql, then change to UPDATE. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3926820#3926820 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3926820 -

[JBoss-user] [EJB 3.0] - Re: JBoss4.0.4RC1: tables were dropped

2006-02-24 Thread gus888
I will try it. Thank you so much for your help. I really appreciate it. GUS View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3926101#3926101 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3926101

[JBoss-user] [EJB 3.0] - Re: JBoss4.0.4RC1: tables were dropped

2006-02-24 Thread gus888
When I restarted AS, some tables disappeared. However, when I completely removed the line All tables I recreated remain the same (no change). I do not understant why. Thank you for your response. GUS View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3926088#392

[JBoss-user] [EJB 3.0] - JBoss4.0.4RC1: tables were dropped

2006-02-23 Thread gus888
Hi all, It was very painful when I tried to migrate to JBoss4.0.4RC1 from EJB3.0RC3. Finally, it worked, but I found that all my data in database were deleted and tables were recreated. My persistence.xml was: | | java:/DVD_DS | | | |

[JBoss-user] [EJB 3.0] - Re: EJB-QL for @ManyToMany?

2006-02-22 Thread gus888
Hi Emmanul, I got the insert method. Thank you so much. GUS View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3925744#3925744 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3925744 ---

[JBoss-user] [EJB 3.0] - Re: EJB-QL for @ManyToMany?

2006-02-22 Thread gus888
Hi Emmanuel, you are great. Yes, the other codes in the Group class made the exceptions. Now I fixed, but I have a new question. That is how to insert new data into the joined table, e.g. add a new group into table groups(group_id,...) and table group_members (group_id, account_id). Thank you v

[JBoss-user] [EJB 3.0] - Re: EJB-QL for @ManyToMany?

2006-02-21 Thread gus888
Hi Emmanuel, I also have a problem with manytomany query. Following are my codes: public class Account { | ... | @ManyToMany(cascade = {CascadeType.PERSIST, CascadeType.MERGE}, | fetch = FetchType.LAZY, mappedBy="accounts") | public List getGroups() { |

[JBoss-user] [EJB 3.0] - Re: Help for Entity Query

2006-02-16 Thread gus888
Thank you very much, Emmanuel. That is really good help. GUS View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3924475#3924475 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3924475 ---

[JBoss-user] [EJB 3.0] - Re: Migration JBoss 4.0.3 --> JBoss 4.0.4

2006-02-16 Thread gus888
Yes, I have the same problem. I just want to wait for new release of DVD Store Demo Application, then check what should be changed. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3924474#3924474 Reply to the post : http://www.jboss.com/index.html?module=bb&

[JBoss-user] [EJB 3.0] - Re: Help for Entity Query

2006-02-15 Thread gus888
Sorry, I forgot post my entity bean: @Entity | @Table(name="CATEGORY") | public class Category implements Serializable { | | private long id; | | private String name; | | private Category parentCategory; | | private List childCategories; | |

[JBoss-user] [EJB 3.0] - Help for Entity Query

2006-02-15 Thread gus888
Hi Folks, I am new in EJB, and have a question about how to load a null parent_id into its Entity bean. I have a table as follows: CATEGORY +---+-+--+ | |ID |NAME |PARENT_ID | | |1 |Computer |Null | | |2 |PC |1 | | |3 |Mac |1 | I w

[JBoss-user] [EJB 3.0] - Re: Urgent help!!!

2006-02-08 Thread gus888
Thank you so much, all. I just found the bug. I did not define A (new A() in my managed session bean. Since I use jsf, myfaces, myfaces tiles and ejb3, I thought it was very difficult to debug. Now, I just realized I forgot to define the entity bean. Thanks again for your response and help! Sh

[JBoss-user] [EJB 3.0] - Urgent help!!!

2006-02-07 Thread gus888
Hi I recently got a very boring problem. I use JSF and EJB3. A super entity bean A, and sub entity bean B extends A. When I submit data from JSF page to the B (throug a manage session bean), it works. However, when I submit data from JSF page to the A, I always get the "Error during model data

[JBoss-user] [EJB 3.0] - Re: Need a help on IP_ADD_MEMBERSHIP failed exception

2006-02-01 Thread gus888
Could you please give me details? e.g. give a link to "How to" or documentation. I am new learner on EJB. Thank you. GUS View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3921114#3921114 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&m

[JBoss-user] [EJB 3.0] - Need a help on IP_ADD_MEMBERSHIP failed exception

2006-02-01 Thread gus888
Hi there, I am new EJB user. I use JSF and EJB3 in a test project. When I use stateless bean, it worked fine. However, when I added a stateful bean and deployed them to JBOSS 4.0.3 SP1, I got several exceptions: --- ObjectN