Taglib documentation for tag mak:object#
Description#
Like list, but the query can only have zero or one result. A zero value for maxCountVar and countVar indicate that the object does not exist.
.
Attributes#
Name | Required | Runtime expression | Description | Comments |
---|---|---|---|---|
from (from mak:list) |
true | false | MQL FROM section. If the query is nested, the keys from the parent's query are added to this FROM section in the resulting query
.![]() |
Mandatory.
.![]() |
variableFrom (from mak:list) |
false | false | supplementary, variable MQL FROM section.
.![]() |
Can contain #{ JSP EL expressions }
.![]() |
where (from mak:list) |
false | false | MQL WHERE section. If the query is nested, the WHERE section from the parent's query, is added to this in the resulting query
.![]() |
Can contain #{ JSP EL expressions }
.![]() |
groupBy (from mak:list) |
false | false | MQL GROUP BY section
.![]() |
Can contain #{ JSP EL expressions }
.![]() |
id (from mak:list) |
false | false | Tag's identifier
.![]() |
Can be used to distinguish otherwise identical tags on a page (to avoid confusion by Makumba's JSP analyser)
.![]() |
db (from mak:list) |
false | true | The makumba database to connect to. The format is Host_SQLEngineType_DatabaseName If not present, the default database is used. See database configuration and lookup.
.![]() |
Cannot contain attributes, for now. The default database is chosen if this argument is not set. Can only be set for top-level (root) query tags Can be a Rtexpr <%= ...%>
.![]() |
authorize (from mak:list) |
false | false | "binding" (or "auto") requires that the user has access (canRead() ) to all returned data. If that is not the case, an UnauthorizedException is raised. "filter" filters out the results for which canRead() is false. ![]() |
Experimental. Not yet used in production environments. Note that this applies to all objects involved in the query that have a canRead(), e.g. if label.relation.field is used, label.relation.canRead() will be honoured if it exists. ![]() |
countVar (deprecated) (from mak:list) |
false | false | The java.lang.Integer variable that will contain the number of the current iteration.
.![]() |
A new Java variable is created, so no other variable by the same name can exist in the Java scope at that point in the JSP. Deprecated: Use mak:count() expression language function instead
.![]() |
maxCountVar (deprecated) (from mak:list) |
false | false | The java.lang.Integer variable that will contain the total number of iterations.
.![]() |
A new Java variable is created, so no other variable by the same name can exist in the Java scope at that point in the JSP. Deprecated: use mak:maxCount() expression language function instead
.![]() |
See also#
Examples#
<mak:object from="company.Employee e" where="e=$employee"> ... </mak:object>
