Search records with matching object attributes in selection

4D v16 is providing you with an enhanced integration of object fields in your database.
If you have already pre-selected sets of an object field, you can now query these sets using only one 4D command: easy and fast!

The QUERY SELECTION BY ATTRIBUTE command works exactly the same as QUERY BY ATTRIBUTE existing command, except that the search is performed among the records currently selected by a previous query or a set for example.

// ask a city to the user for performing the query
$recordInSet:=Records in set("userSet")
// Is the set (selection) is empty?
If ($recordInSet>0)
// may be in 1st level attributes
QUERY BY ATTRIBUTE([Samples];[Samples]OB_Field;"City";"=";$value;*)  // query is not finished...
// or in a adress (with . path)
QUERY BY ATTRIBUTE([Samples]; | ;[Samples]OB_Field;"Address.City";"=";$value;*)  // query is still not finished...
// or in an adress array (with .[]. path)
QUERY SELECTION BY ATTRIBUTE([Samples]; | ;[Samples]OB_Field;"Address.[].City";"=";$value// now, query is executed !
//You can mix different query commands for defining the query
// the selection is empty, alert the user
ALERT("There is no selected contacts. Please select contacts in the list.")
End if

More details can be found in the QUERY SECTION BY ATTRIBUTE command documentation.

Vanessa Talbot

• Product Owner •

Vanessa Talbot joined 4D Program team in June, 2014. As a Product Owner, she is in charge of writing the user stories then translating it to functional specifications. Her role is also to make sure that the feature implementation delivered is meeting the customer need.

Since her arrival, she has worked to define key features in 4D. She has worked on most of preemptive multi-threading new features and also on a very complex subject: the new architecture for engined application. Vanessa has a degree from Telecom Saint-Etienne. She began her career at the Criminal Research Institute as a developer for the audiovisual department. She has also worked in media and medical fields as expert in technical support, production as well as documenting new features.