Page 1 of 1

how to include single value from another table

Posted: Mon 06 Apr 2015 03:30
by inageib
I have two tables master table1 and detail table2

Table1 structure:

table1_id integer,
name varchar(20),
description varchar(50)


Table2 structure

table2_id integer,
table1_id integer,
price numeric(7,2),
Price_date date

I know how to link between them using join but the problem is that I want only to get the most recent price record linked to Table1 not all prices. in other words I dont want duplicates from table "Table2" but only one records contain the most recent price.

how I should write that SQL ?

Re: how to include single value from another table

Posted: Mon 06 Apr 2015 08:34
by ViktorV
This question doesn't concern to IBDAC functionality. Please refer to the used database SQL documentation. If you have any further questions concerning our components, please contact us.