Re: [GENERAL] a basic sql request

Поиск
Список
Период
Сортировка
От Bob Kline
Тема Re: [GENERAL] a basic sql request
Дата
Msg-id Pine.LNX.4.10.9911080749050.13782-100000@rksystems.com
обсуждение исходный текст
Ответ на a basic sql request  (Edouard DESSIOUX <edx@intrinsec.com>)
Список pgsql-general
On Mon, 8 Nov 1999, Edouard DESSIOUX wrote:

> Hello,
>
> I'm having problem with a request, I want to do a
> select * from crypto
> but I want the first field to be the name field.
> So i tried
> select name,* from crypto
> but I just got name both.
> Can someone tell me how to do this ?
>

The use of * in a SELECT statement requests all columns from the
table(s) in the FROM clause.  If you want control over which columns are
returned or the order in which they are returned or the name used to
label the column in the output, you must provide an explicit column
list.  This is a *very* basic SQL concept, and you should probably spend
some time with a good book on SQL or with the online tutorial
(http://www.postgresql.org/docs/tutorial/sql-language.htm#SELECT covers
your question nicely).

Hope this helps.

--
Bob Kline
mailto:bkline@rksystems.com
http://www.rksystems.com


В списке pgsql-general по дате отправления:

Предыдущее
От: Edouard DESSIOUX
Дата:
Сообщение: a basic sql request
Следующее
От: Fabrice Scemama
Дата:
Сообщение: Postgres on Linux Alpha