8. 高度な検索

How do you search for blank fields, or fields whose value isn't "X"? It's not really very intuitive, especially if you are used to languages like PHP or JavaScript.

 

Blank Field Searching

To find all records where the field 'Person::First Name' is blank, we could use this reactor function call:

// Find all people who have a BLANK first name FRTB_FMFind( 'FM.link', // FM.link '"Person"', // Table Occurrence '"First Name"', // Fields to Find '"First Name" IS NULL', // What to Find getPersonRecord // Completion Function ); // Or using an FRTB Object style find: FRTB.Find( 'Person::First Name' ).filter( 'Person::First Name=' ).send( getPersonRecord )

 

Is Not Equal Searching

To find all records where the field 'Person::First Name' is not equal to "Sam" we could use this reactor function call:

// Find all people whos first name is NOT Sam FRTB_FMFind( 'FM.link', // FM.link '"Person"', // Table Occurrence '"First Name"', // Fields to Find '"First Name" <> \'Sam\'', // What to Find getPersonRecord // Completion Function ); // Or using an FRTB Object style find: FRTB.Find( 'Person::First Name' ).filter( 'Person::First Name<>Sam' ).send( getPersonRecord )

 

Wild Card Searching

To find all records where the field 'Person::First Name' begins with "Sam" we could use this reactor function call:

// Find all people who's name starts with Sam. // Will match 'Sam Kindle', 'Samantha', 'Samuel' etc.. FRTB_FMFind( 'FM.link', // FM.link '"Person"', // Table Occurrence '"First Name"', // Fields to Find '"First Name" LIKE \'Sam%\'', // What to Find (The wild card is a percent symbol here) getPersonRecord // Completion Function ); // Or using an FRTB Object style find: ( here the wildcard is a more familiar star symbol ) FRTB.Find( 'Person::First Name' ).filter( 'Person::First Name~Sam' ).send( getPersonRecord )

FRTB Object

6. FRToolBox関数のリファレンス