Hi guys,
I'm having trouble extracting data from the typed list that I created. My code is:
**Dim typedList As New MyTypedList
Dim fields As IEntityFields2 = MyTypedList.GetFieldsInfo()
Dim bucket As New RelationPredicateBucket
bucket.PredicateExpression.Add(PredicateFactory.CompareValue( _
EmployeeTblFieldIndex.EmployeeId, _
ComparisonOperator.Equal, employeeId))
Dim adapter As New DataAccessAdapter
adapter.FetchTypedList(fields, MyTypedList, bucket)**
If I run this code, i get the following SqlException:
The column prefix 'dbo.CUSTOMER_TBL' does not match with a table name or alias name used in the query.
I did some researching and found another approach using the GetRelationInfo property of the typedlist so i modified my bucket definition as:
Dim bucket As IRelationPredicateBucket = MyTypedList.GetRelationInfo()
What happens is I get rid of the exception but the typedlist does not contain anything (returns just the headers)
Is there something wrong with my code or with the way I formed the typedlist?