PerfromGetDBCount is used for paging.
So if you are not using paging and you are returning all the rows in the database table, so you may just do nothing in PerformGetDBCount or return e.CountainedCollection.Count
But if you use paging, then you need to pass the PageSize and the PageNumber to the Fetch method, thus fetching a subset of rows from the database not all the rows.
And also you need to display or know the number of pages a user might navigate within.
And to know the number of Pages, then you should execute another query to the database to get the Coutn(*) of rows.
You might wish to disable paging in the DataSource but enable it in the grid.
Thus letting the dataSource fetch all the records in the database and leave the paging stuff to the grid. In this case (which I don't recommend at all) you may use e.CountainedCollection.Count in the PerformGetDBCount method without executing another query.