# Purposely Run Slow Querys to Save On Resources

**URL:** <https://forum.inductiveautomation.com/t/purposely-run-slow-querys-to-save-on-resources/72386>\
**Category:** Ignition\
**Tags:** ignition81, database\
**Created:** [April 13, 2023, 2:05am UTC](https://forum.inductiveautomation.com/t/purposely-run-slow-querys-to-save-on-resources/72386 "2023-04-13T02:05:57Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![matthew.tomlinson](https://avatars.discourse-cdn.com/v4/letter/m/dec6dc/32.png) [@matthew.tomlinson](https://forum.inductiveautomation.com/u/matthew.tomlinson)\
**Post date:** [April 13, 2023, 2:05am UTC](https://forum.inductiveautomation.com/t/purposely-run-slow-querys-to-save-on-resources/72386/1 "2023-04-13T02:05:57Z")

</div>

Hello,  
I have a pretty large historical tag database that users can export data to XLS files from. The issue I'm running into is users have requested to get more detail within their exports. They would like to be able to select the range of data to export as well as the time period of the data; this is fine, but if they select a large range of time and a small period the server is pretty intensely taxed. It takes a while to generate this data to be available to download as well as bogging down the server for anyone else using it.

I'd like to have the same system of data requests, but, instead of the export being instantaneous, make it a request. The server would receive this request and if the amount of data was large enough, would purposely run the query slower to not tax the server as much. Once the report was generated, rather than it downloading direct to the user's PC, it would email out the XLS dataset.

Is this a possibility with Ignition/SQL Express?

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [April 13, 2023, 2:08am UTC](https://forum.inductiveautomation.com/t/purposely-run-slow-querys-to-save-on-resources/72386/2 "2023-04-13T02:08:42Z")

</div>

Generally this sort of problem would be solved by using replication to make a read-only slave DB, and have the heavy queries use this slave. Consider using a more competent free database, like PostgreSQL or MariaDB, both of which can do this (still for free).

---

<div class="post-metadata">

**Author:** ![matthew.tomlinson](https://avatars.discourse-cdn.com/v4/letter/m/dec6dc/32.png) [@matthew.tomlinson](https://forum.inductiveautomation.com/u/matthew.tomlinson)\
**Post date:** [April 13, 2023, 2:15am UTC](https://forum.inductiveautomation.com/t/purposely-run-slow-querys-to-save-on-resources/72386/3 "2023-04-13T02:15:45Z")

</div>

Got it - Separate identical database on another server to save resources from the main one. Sounds easy enough in theory. Appreciate the response.
