I am wondering what the easiest way would be to prevent my server from being stressed when I wish to get lots of data using PHP.

Convert my data for an XML sheet? Use caching?

The information originates from a variety of databases and various tables.

Any ideas?

Thanks ahead of time

  1. Before you decide to do anything whatsoever, stress it until it breaks.

  2. If this breaks, profile it to recognize the breaking point, and focus on that.

  3. Repeat from point 1 before the performance limits are acceptable.

Neither.

Both add significant complexity in your PHP code. Transforming to XML has simply no added value - indeed it's not only one more cost encoding in XML, you then have a cost for decoding. For actucally storing your computer data in XML - this really is plain absurd.

The MySQL DBMS provides extremely effective result caching. The actual OS ought to provide excellent I/O caching. You will get nothing with the addition of your personal caching layer aside from reduced code and warmer processor chips.

For those who have an OLTP type database and therefore are routinely collating large teams of data, then you might like to consider pre-bringing together it or applying an OLAP schema in your database.

OTOH should you only desire to enhance the performance of the system, take a look aleswhere - particularly your computer data scema.

C.

I believe caching is going to be what you want , until this data does not change very frequently :)