>I have the following SELECT statement:
>
>SELECT DISTINCT field1 AS type1 ;
> field2 AS type2, ;
> 000000 AS valcnt, ;
> 000000 AS invcnt, ;
> 00000000.00 AS chq_tot, ;
> SPACE(40) AS descr, ;
> SPACE(20) AS cname, ;
> 000000.00 AS conv_amt, ;
> m.currpromo AS p_no, ;
> 000.000000000 AS conv_unit ;
> FROM PROM ;
> GROUP BY 1 ;
> INTO TABLE(m.tmp_path + "tmpfile.dbf")
> INDEX ON type1 TO c:\temp\tmpfile.idx COMPACT
>
>I want to SELECT two distinct fields (i.e. field1 & field2).
>
>How do I do this?
Ger,
Remove 'distinct', 'group by 1,2'.
PS: INDEX ON type1 tag type1
sounds to be better.
distinct would also work, then remove group by.
Cetin