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.

Record is missing error on createRecord

Featured Replies

This has really got me stumped. I am trying to create a new record from our website when someone fills out a form. I've done this before, but for some reason every time I try to do it I get a Filemaker Error 101 Record is missing. Here is what I have


$form = $fm->createRecord('Web.Forms');

if(isset($_POST['HomeNum'])) $form->setField('Contact.Home', $_POST['HomeNum']);

if(isset($_POST['MobileNum'])) $form->setField('Contact.Mobile', $_POST['MobileNum']);

if(isset($_POST['Email'])) $form->setField('Contact.Email', $_POST['Email']);

...

$result=$form->commit();

if (FileMaker::isError($result)) {

$error=$result->code;

echo "
Error $error: " . $result->getMessage() . "";

}else{

echo "Your answers have been saved. Thank you for your time.";}	

When I run this I get "Error 101: Record is missing". I checked and the login has fun access to create records in the table and the ability to access the layout via php. I also tried using $form = $fm->newAddCommand and $form->execute with the same results. Any suggestions?

Edited by Guest

  • Author

FYI for anyone with a similar problem, I solved the issue. The problem originated with the fields that had periods in their names. For instance the Contact.Email field. Once I changed the names to something without periods it works fine. That is pretty annoying considering I name fields that way often for organization. Oh well.

I would highly suggest using another convention.

A period is generally used in SQL to separate database names from table names from field names in queries.

e.g.

SELECT table1.name, table2.name FROM table1 JOIN table2 ON table1.ID = table2.table1_ID

You can always get around it by using text delimiters in your query (e.g. table1.`Contact.name` for MySQL; table1.[Contact.name] for SQL server) but that can be a real PIA to maintain and/or read and is a recipe for bugs down the road.

  • 2 weeks later...

If memory serves, you use a period in a field name via CWP to indicate that you want to edit a particular repetition of a field. Hence the error.

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.