I am back to part of the report not appearing (sometimes). I completely rewrote the queries to make them faster. They seem to work fine and can populate my temporary tables 100% of the time. So therefore I do not think the issue is with RDS. I have tested it and the temporary table is being fully populated with the correct data from RDS.
That only leaves the datastore not being populated for some reason (sometimes). I tried to debug your source code but I don't think I am putting break points in the correct file. Will you continue to help me to get the datastore to populate, 100% of the time?