Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I set DWDD to select DISTINCT values?

Status
Not open for further replies.

Andyfives

Programmer
Feb 22, 2002
46
DK
Hi there,

I am very new to Powerbuilder 11.5, but now I'm using it on a daily basis and I am on a mission to get my head around it. :)

This is probably a simple task, but I have a dropdown window that has a source that has duplicate values where they are not needed and I would like to get rid of these.

I see the SQL

Code:
SELECT USERS.USERID,   
         USERS.FIRST_NAME,   
         USERS.LAST_NAME  
    FROM USERS

but I can not change it in the DataSource (painter?) where can I set this to make a simple SELECT DISTINCT?

Thanks in advance.

I hope there is somebody out there....

Andy

 
Open the DDDW's DataWindow Painter. Go to the SQL source. Under the Design menu, select "Convert to Syntax" if you're not already there, and either use the SELECT DISTINCT clause or a GROUP BY clause.
 
That is perfect.

Thank you.

I couldn't see that for looking!

Andy
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top