You are here: How can I get all records for both tables with the latest begin date if exists? « MsSQL Server « IT news, forums, messages
How can I get all records for both tables with the latest begin date if exists?

Posted by TGEAR on 10/02/48 11:50

Itemlookup table
Field names : index_id (primary key), itemno, description.
It has a child table, which is ItemPriceHistory table
The relationship to the child table is one (parent table)-to-many
(child table). - It is possible to have no child record for some rows
in the parent table.

ItemPriceHistory table
Field names: index_id (primary key), itemlookupID (foreign key of the
Itemlookup table), date begin, price
It is a child table of the itemlookup table.

How can I get all records for both tables with the latest begin date if
exists?
I also need to show the records in the parent table if there is no
related record in the child table.

Please help

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация