[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

RE: [sqr-users] Distinct in SQR



Try running the sqr with the -S flag to get the SQL being created by
SQR.  Then compare that to what you think should happen (and run it in
Toad). 

You are only showing some of the fields.  Are you sure you are not
getting distinct results and the differences are in the fields you are
not printing?

 

-----Original Message-----
From: sqr-users-bounces+lroux=syr.edu@sqrug.org
[mailto:sqr-users-bounces+lroux=syr.edu@sqrug.org] On Behalf Of Hall,
Tara
Sent: Monday, September 24, 2007 1:38 PM
To: sqr-users@sqrug.org
Subject: [sqr-users] Distinct in SQR

Hi All,

I'm using the following code in an SQR but it is still not returning
distinct rows.  If I used the same code in TOAD, it returns distinct
rows of data:

BEGIN-SELECT DISTINCT
D.ROLEUSER                      (+1, 15)
F.OPRDEFNDESC   
D.ROLENAME                      (0, 60)
E.CLASSID                       (0, 100)
F.ACCTLOCK                      
 
       LET #MYOBJNAME = 1
       
    FROM PSROLEUSER D, PSROLECLASS E, PSOPRDEFN F
    WHERE D.ROLENAME = E.ROLENAME
       AND E.CLASSID = 'PSADMIN'
       AND D.ROLEUSER = F.OPRID
       AND F.ACCTLOCK = 0
  ORDER BY 1
end-select


Any suggestions?

Thanks,
Tara

_______________________________________________
sqr-users mailing list
sqr-users@sqrug.org
http://www.sqrug.org/mailman/listinfo/sqr-users

_______________________________________________
sqr-users mailing list
sqr-users@sqrug.org
http://www.sqrug.org/mailman/listinfo/sqr-users