Skip to Content
avatar image
Former Member

How to deal with relation

Hi

I am trying to import two beans(TestBean and HelperBean)into my Web Dynpro project to create a model. These beans are dealing with a List(ArrayList). This List is considered as a Relation. I am facing problem in handling this relation.

I am having both the TestBean and HelperBean in the same package. Below is the code of TestBean. This bean is in turn calling HelperBean ,which is returning a List.

I am getting an error while creating model -


<b>[Error]: There are one or more relations unresolved. Importing the model without resolvoing the relations might result in erratic output.</b>

<u><b>Code For TestBean</b></u>

public class TestBean implements Serializable{
	private List customerList= null;
	HelperBean helper = new HelperBean();
 
	
		public void execute(){
		
		try{
								customerList = (ArrayList)helper.getCustomerList();
		
			
			}
			catch(Exception ex){
			
				ex.printStackTrace();
			
			}
		}
 
	
	/**
	 * @return
	 */
	public List getCustomerList() {
		return customerList;
	}
 
	/**
	 * @param list
	 */
	public void setCustomerList(List list) {
		customerList = list;
	}

I am new to Web Dynpro and don't know how to deal with relation.Please inform if there is some solution.

regards,

Sujit

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Oct 24, 2006 at 07:33 AM

    Sujit,

    Not every bean becomes model class during import. So your HelperBean is irrelevant here. But you miss other bean, namely Customer bean. You must add it as model class during import, then select problematic 0..n relation and resolve it to model class Customer.

    Valery Silaev

    SaM Solutions

    http://www.sam-solutions.net

    Add comment
    10|10000 characters needed characters exceeded