title: SQL Server 2008 Master/Detail ( Using Delphi and ADOQuery )
body: <p>I have a SQL Server 2008 DataBase with 2 Table : Master and Detail</p>
  
  <p>Master Fields : ID and ... ;</p>
  
  <p>Detail Fields : ID , MasterID and ... ;</p>
  
  <p>I have been set the relationship between Master and Detail in SQL Server</p>
  
  <p>I want when I Select a record in Master DBGrid , Detail Query returns only records related to selected Master Record and Detail DBGrid Show only Related records</p>
  
  <p>I dont want to Requery Detail ADOQuery everytime I select a Master Record with such as SQL Code ( for Example ) :</p>
  
  <pre><code>SELECT * FROM Detail WHERE MasterID = Master.ID
  </code></pre>
  
  <p>how can i do this without using ADOTable ( Master Source ) !?</p>
  
  <p>in other words i want this Relationship be in DB Layer !</p>