🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: pl.comp.lang.delphi.bazy-danych
Article #70164

Re: zapytanie...może LIKE ?

#70164
From: Morff
Date: Mon, 18 Jun 2007 17:51
25 lines
1474 bytes
Dnia 18-06-2007 o 16:19:32 romekp <romekp2@wp.pl> napisał:

> Witam serdecznie.
...
> Wybierz z pola indeks_mat pierwsze (wszystkie) rekordy 4 znaki, które
> odpowiadaj± 4 pierwszym znakom z pola Indeks.

select * from tabela
where
substring(indeks_mat from 1 for 4) = substring(indeks from 1 for 4)

> Oraz drugie zapytanie poka¿ wszystkie rekordy z pola indeks_mat i indeks,
> których pierwsze 4 znaki s± ró¿ne od siebie.

select * from tabela
where
substring(indeks_mat from 1 for 4) <> substring(indeks from 1 for 4)

dla firebirda.

-- 
Pozdrawiam
Morff
--------------------
AQQ 141151
Technical Details
Message-ID: <op.tt4o7poyq0kutt@xp_januszk.wag54gs>
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!newsfeed.gazeta.pl!news.nask.pl!news.nask.org.pl!newsfeed.tpinternet.pl!nemesis.news.tpi.pl!atlantis.news.tpi.pl!news.tpi.pl!not-for-mail
References: <f564ce$svj$1@inews.gazeta.pl>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!newsfeed.gazeta.pl!news.nask.pl!news.nask.org.pl!newsfeed.tpinternet.pl!nemesis.news.tpi.pl!atlantis.news.tpi.pl!news.tpi.pl!not-for-mail
From: Morff <morff1@wp.pl>
Newsgroups: pl.comp.lang.delphi.bazy-danych
Subject: Re: zapytanie...może LIKE ?
Date: Mon, 18 Jun 2007 19:51:15 +0200
Organization: tp.internet - http://www.tpi.pl/
Lines: 25
Message-ID: <op.tt4o7poyq0kutt@xp_januszk.wag54gs>
References: <f564ce$svj$1@inews.gazeta.pl>
NNTP-Posting-Host: bzn107.neoplus.adsl.tpnet.pl
Mime-Version: 1.0
X-Trace: atlantis.news.tpi.pl 1182189157 21358 83.30.59.107 (18 Jun 2007 17:52:37 GMT)
X-Complaints-To: usenet@tpi.pl
NNTP-Posting-Date: Mon, 18 Jun 2007 17:52:37 +0000 (UTC)
User-Agent: Opera Mail/9.21 (Win32)
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit