🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.interbase.sql
Article #152

Re: need advice about sql for data mining

#152
From: Craig Stuntz TeamB
Date: Tue, 10 Jun 2008 13:23
32 lines
1674 bytes
Maxim Shiryaev wrote:

>   select date
>     from purchase
> 
>     union all
> 
>     select date
>     from sales
> 
>     group by 1

	This isn't valid InterBase SQL.

Instead, do:

SELECT DISTINCT
  date
FROM
  purchase
UNION 
SELECT DISTINCT
  date
FROM
  sales
INTO ...

-- 
Craig Stuntz [TeamB] � Vertex Systems Corp. � Columbus, OH
  Delphi/InterBase Weblog : http://blogs.teamb.com/craigstuntz
Want to help make Delphi and InterBase better?  Use QC!
  http://qc.borland.com -- Vote for important issues
Technical Details
Message-ID: <484e805a$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!proxad.net!feeder1-2.proxad.net!194.25.134.126.MISMATCH!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <484db5e2@newsgroups.borland.com> <484e2f00$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 114a0e,b4be59b23378bfae
X-Google-Attributes: gid114a0e,domainid0,public,usenet
X-Google-Language: ENGLISH,ASCII
From: "Craig Stuntz [TeamB]" <craig_stuntz@nospam.please [a.k.a. acm.org]>
Subject: Re: need advice about sql for data mining
Newsgroups: borland.public.interbase.sql
References: <484db5e2@newsgroups.borland.com> <484e2f00$1@newsgroups.borland.com>
Organization: Vertex Systems Corporation
User-Agent: XanaNews/1.18.1.9
X-Face: "huzh55Xi]!ZNni78>a*5+).`SK?<^q2MlHk-C]Z2M9T@\J5ZCB$95Ey+s"XQuhGFA[eutZ:0^AV!Q;t>gE`1-=8d;HZ6~*o1dH<X9\b$!|(}+I'!Xq)@3Op}%0ArW&nf'Qh*EwR
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8bit
NNTP-Posting-Host: 64.199.116.234
Message-ID: <484e805a$1@newsgroups.borland.com>
Date: 10 Jun 2008 06:23:38 -0700
X-Trace: newsgroups.borland.com 1213104218 64.199.116.234 (10 Jun 2008 06:23:38 -0700)
Lines: 32
X-Authenticated-User: cstuntz
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!proxad.net!feeder1-2.proxad.net!194.25.134.126.MISMATCH!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail