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.

query multiple FM servers

Featured Replies

Is it possible with the PHP API to do a find on two FM servers?

My first find works fine

$fm_it = new FileMaker();

	$layoutName = 'webview_kell';

	$fm_it->setProperty('database', 'db_name');

	$fm_it->setProperty('host', '10.1.4.5');

    $fm_it->setProperty('username', 'test_php');

    $fm_it->setProperty('password', 'temp_pw');

I have tried to change the IP address in the host property for my second find to be the other FM server, and I get error 802(Unable to open file)

The second server has the WPE enabled, firewalls/ports are not an issue as these are on the same network.

Any thoughts or ideas would be great.

I am trying to redo a page that was done in XSLT using relationships to get the data out of the second DB(this method never really worked right)

Edited by Guest

There's something wrong with your second server and / or your WPE deployment on your second server and / or file / permissions on the second server. Take the first one out of the picture and you'll get the same result.

A good idea might be to try and place your working file that's on the first server to the second server (should guarrantee permissions etc), ensure the file is open and see if you can connect.

  • Author

thanks, Genx,

I got all the permissions worked out(there were a few.)

Now we need to move it to a remote server that is the same setup as the internal one it currently work on.

So my scenario is this:

Apache server as web server(Web1)(behind firewall at location A)

FM server advanced(FM1)(behind firewall at location A)

FM server advanced(FM2)(behind firewall at Location B )

FM1 and Web1 are on the same network, and this find request works correctly.

the find request from the page on Web1 to FM2 does not - gets an 802 error.

I assume it is a firewall issue because when I put the file on a different internal test server, both finds work.

At Location B, we have ports 16000,16018 and 16016, and 5003 forwarded to the FM server by the firewall. From what I found in the FM documentation, this was all it mentioned.

Am I missing something glaring?

Edited by Guest

Well, you need port 80 forwarded if that's what you're running Apache on.

  • Author

Port 80 on location A, where apache is is open. Location B is the problem, do I need 80 open on that too?

I would have to say yes... yes you would.

  • Author

Port 80 open at location B... still no go. I still get error 802.

What am I missing?

A bit more info would help especially on where your web server is.

Is the database actually open and ready for hosting on the machine behind FireWall B?

  • Author

Yes.

Are you able to try and connect to it behind the firewall?

  • Author

Yes, from a test server, the page works just fine.

Only from the apache server it does not work.

Which makes me think it is port issue, but I don't know what other ones I would need to open.

You really shouldn't need anything other than 80 because that's what the request is made via... Is Apache (or IIS) running on port 80 on the server behind firewall B?

  • Author

Yes, there is no site at that address, so you get the standard IIS under construction page, but it is running.

Okay well that means port 80 is forwarded correctly. Now if the filter's been install correctly then you should at least be able to get a basic XML result back from a simple query such as:

http://<>/fmi/xml/fmresultset.xml?-dbnames




and / or locally: 


http://localhost/fmi/xml/fmresultset.xml?-dbnames

  • Author

Ok,

That didn't work. I get a page not found error. Even when I run it from the localhost.

weird.

Right, so I read your diagram wrong apparently FM means FM not FMS...

In that case, try open up port 16004 between your servers. If that's still failing, I'd recommend you possibly try and re-deploy your WPE.

  • Author

I was thinking about this last night, and I think that I may redeploy the server first.

We have 2 other remote FM Servers where the URL you gave me works just fine without port 16004 open.

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.