Subject query result
From Mustansir Ghor <mustan31@hotmail.com>
Date Sat, 18 Jul 2020 10:32:41 -0400
Newsgroups dbase.getting-started

Dear All

I am using following two queries in 2 grids in a similar fashion of seeing invoice no and date in grid 1 and and items details of a particular (a row of grid 1)  invoice in grid2.

this.QTEMPSAL = new QUERY(this)
   with (this.QTEMPSAL)
      left = 21.0
      database = form.dlocal
      sql = "select sno,sdate from sales where sdate between :mdate1 and
               :mdate2 group by sno,sdate"
      params["mdate1"] = {  /  /  }
      params["mdate2"] = {  /  /  }
      active = true
   endwith

  
   this.QSALES = new QUERY(this)
   with (this.QSALES)
      left = 15.0
      top = 1.0
      database = form.dnov
      sql = "select * from sales where sno=:sno"
      masterSource = form.qtempsal.rowset
      active = true
   endwith

In both grids initial results are fine. Even when I scroll down in grid one, the grid2 displays correctly for each row of grid 1. However after last row when i scroll up , the rows of grid 1 displays last row content in all. And grid 2 does not display based on grid 1

Since duplication of data were only 2 columns, I decided to keep records in one file and avoid using join.

Can anybody point out were the problem lies.

Thank you in anticipation

Best Regards
Mustansir