Article View: borland.public.cppbuilder.database.ado
Article #2589Re: SQL SELECT -- Combine 2 columns
From: Rainer Welzel
Date: Sun, 20 Apr 2003 05:54
Date: Sun, 20 Apr 2003 05:54
44 lines
2157 bytes
2157 bytes
This doesn't works.
I use Jet 4.0
with a ADOQuery and a DBGrid.
rainer
"Viatcheslav V. Vassiliev" <support@oledbdirect.com> schrieb im Newsbeitrag
news:3ea14f97@newsgroups.borland.com...
> This depends on your DBMS. In MS SQL Server use (pubs db):
>
> Select (au_lname + ', ' + au_fname) as [name] from authors
>
> ----------------------------------------------------------------
> Regards,
> Viatcheslav V. Vassiliev
> http://www.oledbdirect.com
> The fastest way to access MS SQL Server, MS Jet (MS Access)
> and Interbase (through OLEDB) databases.
>
> "Rainer Welzel" <rainer@fgg-welzel.de> �������/�������� � ��������
> ���������: news:3ea14b69@newsgroups.borland.com...
> > Hi ,
> > I failed to combine 2 fields with the following statement:
> >
> > ADOQueryIND->SQL->Add("SELECT Name, City & ', ' & Country AS Location
FROM
> > tblIndi");
> >
> > also
> >
> > ADOQueryIND->SQL->Add("SELECT Name, City || ', ' || Country AS Location
> FROM
> > tblIndi");
> >
> > this statement failed.
> >
> > Have anybody the right syntax ??
> >
> > thx rainer
> >
> >
> >
>
>
Technical Details
Message-ID:
<3ea23628@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-01!sn-xit-08!supernews.com!news-out.visi.com!petbe.visi.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mailReferences:
<3ea14b69@newsgroups.borland.com> <3ea14f97@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII X-Google-Thread: 10698b,2ea9fd8801400070 X-Google-Attributes: gid10698b,public X-Google-ArrivalTime: 2003-04-19 23:00:35 PST From: "Rainer Welzel" <rainer@fgg-welzel.de> Newsgroups: borland.public.cppbuilder.database.ado References: <3ea14b69@newsgroups.borland.com> <3ea14f97@newsgroups.borland.com> Subject: Re: SQL SELECT -- Combine 2 columns Date: Sun, 20 Apr 2003 07:54:52 +0200 Lines: 46 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2600.0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 NNTP-Posting-Host: 217.235.149.189 Message-ID: <3ea23628@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1050818088 217.235.149.189 (19 Apr 2003 22:54:48 -0700) Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-01!sn-xit-08!supernews.com!news-out.visi.com!petbe.visi.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail