In a previous blog post, you learned how to build sophisticated and complex search criteria by applying formulas in an ORDA query. To further provide you with complete and powerful development tools, a new ORDA method available: orderByFormula(). With the help of formulas, you can now order an entity selection using complex criteria in a project method or 4D expression.
In 4D v17 R6, ORDA queries are becoming increasingly more powerful and concise. This blog post is for those of you who need more sophisticated search criteria than just a simple syntax like “name = Smith‘”. With this R-release, you can use any project method or 4D expression in the query() member method by using formulas.
What better way to explain this feature than with an example? Let’s dig into the details.
ORDA has its share of features with 4D v17 R5, including various ways to write generic code.
Writing generic code allows you to centralize your code to facilitate updating it. Not only does it enable you to write reusable code that can be used in different use cases, freeing you from having to reinvent the wheel again and again, it also lets you add extra functionalities on top of what you’ve already done.
Using ORDA to access large tables (especially those with relations) in Client/Server mode has been greatly enhanced. With 4D v17 R5, you’ll see 2-3xs improved LAN performance and up to 30xs faster WAN performance. And best of all – there’s no need to change anything in your code, it’s all automatic. Interesting, isn’t it? Well, let’s delve into the details.
“How can I know the dataClass of an entity? I need it to write generic methods“. “I need information about a field in a dataClass: what is its type? Is it indexed? Is it unique?“. These are the kinds of questions we’ve heard you asking on the forum. 4D v17 R5 provides the answers: introducing new ORDA member methods to provide useful information about your database. Keep reading, because you’ll appreciate the benefits of reducing the size of your code and making it reusable and easy to maintain!
The ORDA features keep coming with 4D v17 R5! In a previous blog post, we showed you how to create generic queries with named placeholders for values. This post will focus on how to use placeholders for attribute paths (field names in tables).
By now you’ve surely noticed that ORDA queries are not only light and readable, they also make it easy to navigate through the entire data model using object-oriented concepts! In this blog post, we showed you how to write powerful and easy-to-maintain queries. One of the methods recommended was providing the query and values separately via placeholders. 4D v17 R5 takes placeholders a step further by allowing you to write generic ORDA queries: say hello to named placeholders for values!
Today’s episode is focused on the user interface to help you create nice looking lists and grids!
In the first and second episodes of this trilogy, we demonstrated the basics of ORDA using list boxes, entities, and entity selections. We also showed the way to use similar list boxes with distinct data sources and how to use Meta info expression to improve the list boxes’ graphics.
Today we’re going to have even more fun, with less code!
In the first episode of this trilogy, we demonstrated the basics of ORDA using list boxes, entities, and entity selections. Today, we’re going a bit deeper by running some queries that will take advantage of recursive relationships. We’ll also have a quick look at how to display list boxes nicely using the “meta info expression” property.
Got a question, suggestion or just want to get in touch with the 4D bloggers? Drop us a line!
* Your privacy is very important to us. Please click here to view our Policy