Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Hi Guys,

I've been trying to get fx.php working, and everything was fine on my little test database of 50 records.

Now I am trying to test pulling data out of a real database with 5700 records, and for some reason it is ridiculously slow. Over 3 minutes to return the first ten records. Surely that can't be right?

Below is the php code I am using. This definitely works, but I need help to get the speed sorted out.

I doubt it's hardware related (the DB server and the web server are both very grunty machines seperate machines, and they are barely ticking over...), so hopefully I have just produced dodgy code. IWP is very fast.

Thanks in advance

Sean.


<?php

include_once('FX/FX.php');

include_once('FX/FMErrors.php'); 

include_once('FX/server_data.php'); 

set_time_limit(0); 

$instanceName=new FX($serverIP,$webCompanionPort);

$instanceName->setDBData('DBASENAME','LAYOUT','10'); 

$instanceName->SetDBUserPass('USER','PASSWORD'); 

$instanceName->FMSkipRecords('0');

$instanceResult=$instanceName->FMFindall();

?>

<html>

<head>

<title>OEN Assets Listing</title>

</head>

<body>



Error Code: <?php echo $instanceResult['errorCode']; ?> <br>

Found Count: <?php echo $instanceResult['foundCount']; ?> <br><br>

<hr>

<?php

//break delimited

foreach($instanceResult['data'] as $key=>$instanceData)

{

echo "asset_id: ".$instanceData['asset_id'][0]."<br>";

}

?>





</body>

</html>



  

  • Author

I think the problem is something on the layout.

Didn't think there was too much on there, but I created a new layout with just the relevant fields on it, and now it's lightning fast again.

Possibly its the fields set up to check for duplicate records via relationships.

Trap for newbies. I didn't realise the layouts elements made such a difference. Guess this means I'll have lots of web layouts.

Thanks :

  • 3 months later...

I find the first search of the day is slow on my solution as well. Almost like the database needs a coffee before it starts its day...

What most likely happens is the first search sorts the data and updates indexes. After the initial search things usually speed up.

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.