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(at)gmx(dot)net
In response to
pgsql-interfaces by date
|Next:||From: Tom Lane||Date: 2002-02-17 21:21:41|
|Subject: Re: C++: headache with PgDatabase::GetValue (int, string) |
|Previous:||From: Carlos Moreno||Date: 2002-02-17 20:52:31|
|Subject: C++: headache with PgDatabase::GetValue (int, string) |