title: get the count from query
body: <pre><code>Select Count(*),
  (select Name from Tours Where Tours.ID = TourBooking.TourID) as Name,
  (select Url from Tours Where Tours.ID = TourBooking.TourID) as Url,
  (select Top 1 Name from TourImages Where TourImages.TourID = TourBooking.TourID Order By ID Asc) as ImageName,
  (Select Duration +' '+ CASE WHEN  DurationType = 'd' THEN 'Day(s)' WHEN  DurationType = 'h' THEN 'Hour(s)' END from Tours Where Tours.ID = TourBooking.TourID)as Duration,
  (select replace(replace('&lt;a&gt; Adult(s) - &lt;c&gt; Children','&lt;a&gt;', sum(case when [Type] = 1 then 1 else 0 end)                      ),
  '&lt;c&gt;', sum(case when [Type] = 2 then 1 else 0 end)) from TourPerson Where TourPerson.BookingId = TourBooking.ID) as TotalPassengers,
  StartDate,CreatedDate as BookingDate,ID as BookingID,[Status],ServicePrice
  from TourBooking
  </code></pre>
  
  <p>How to get the count from this query </p>