J.D.
|
| Posted: 09/06/2002, 9:17 AM |
|
I have a grid page that lists several vlans. If the vlan is on multiple pieces of equipment, then it is displayed twice. How do I limit the output to only show the vlan once?
Thanks,
J.D.
Provident Bank
|
|
|
 |
TonyE
|
| Posted: 09/06/2002, 10:43 AM |
|
You need to use a custom querry
Modify the properties in your grid form as following.
Click in the title area of the grid
Change the Source Type to SQL
Click on the data source, so you can enter a custom querry
The most important part is the groub by statement. You would use GROUP BY vlans
Example querry that shows dublicate entries only once and also counts the dublicates. (It groups the item by customer)
SELECT rmas.item_id, c_name, COUNT(rmas.item_id) AS count
FROM rmas LEFT JOIN companies ON rmas.shipping_id = companies.company_id
WHERE rmas.item_id LIKE '{item_id}%'
Group by rmas.shipping_id
ORDER BY count DESC
Use a querry that reflects your own table. If you need to use a where clause you will also need to specify the parameters.
TonyE
|
|
|
 |
|