>Curtis,
>
>Is prim_key the unique id of the customer? And must this field reference a valid customer record?
>By grouping on this key you will not get all records in servcalls.
>
>how about something like...
>
>CREATE SQL VIEW CALLBACK AS ;
>SELECT ALL Servcalls.*, Customers.company;
>FROM appdata!servcalls INNER JOIN appdata!customers ;
>ON Servcalls.prim_key = Customers.prim_key ;
>ORDER BY Servcalls.callbacktime
>
>>When I run this SELECT command it only returns two records.
>>The left table Servcalls has many records and I want to return all of them in >a view. The right table Customers is the parent in a one to many relation with >servcalls.
>
>>CREATE SQL VIEW CALLBACK AS ;
>>SELECT ALL Servcalls.*, Customers.company;
>>FROM appdata!servcalls LEFT JOIN appdata!customers ;
>>ON Servcalls.prim_key = Customers.prim_key ;
>>GROUP BY Servcalls.prim_key;
>>ORDER BY Servcalls.callbacktime
>Is prim_key the unique id of the customer? And must this field reference a valid customer record?
Yes and Yes And,
Thank you Philip, That was the answer.
You've saved me from going crazy!
-Curtis
- jim durkin
"The universe is a big place, perhaps the biggest." Kurt Vonnegut