Re: C++: headache with PgDatabase::GetValue (int,

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: C++: headache with PgDatabase::GetValue (int,
Дата
Msg-id Pine.LNX.4.30.0202171615500.683-100000@peter.localdomain
обсуждение исходный текст
Ответ на C++: headache with PgDatabase::GetValue (int, string)  ("Carlos Moreno" <moreno@mochima.com>)
Список pgsql-interfaces
Carlos Moreno writes:

> Say I have two unrelated tables with fields witht the same name
> (e.g., table Employees, with a field Name, and table Departments,
> also with a field Name).  I have a SELECT statement that returns
> data from both tables, and I need both Name fields:
>
>     "select Emp.Name, Dept.Name from Emp, Dept where ....... "
>
> Now, I (obviously) want to use GetValue (row, "field_name") to
> get the values.

You must use AS clauses to give the two fields different output names.

-- 
Peter Eisentraut   peter_e@gmx.net



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

Предыдущее
От: "Carlos Moreno"
Дата:
Сообщение: C++: headache with PgDatabase::GetValue (int, string)
Следующее
От: Hiroshi Inoue
Дата:
Сообщение: Re: odbc on unix