Cubic Compass Software

- Support Wiki

XOSQL provides a simple query language for databinding objects to user interface controls. The syntax for XOSQL is nearly identical to traditional SQL (Structured Query Language).

The local XOS database (eXtensible Object Store) is queried. This query method is preferred over cloud-based remote queries (such as using SOQL) and results in a performance optimization.

Queried objects and fields must be persisted in the local XOS database to be returned in result sets. See ETL Manager for replicating data from remote data sources.

Example:
<dlog:Repeater id="Repeater1" XOSQL="SELECT TOP 10 FROM Solution WHERE Status='Published' ORDER BY CreatedDate DESC"
NoResultsText="No solutions available">
   <HeaderTemplate>
      <table>
   </HeaderTemplate>
   <ItemTemplate>
      <tr><td> <dlog:Label id="ItemLabel" FieldName="SolutionName" />  </td></tr>
   </ItemTemplate>
   <FooterTemplate>
      </table>
   </FooterTemplate>
</dlog:Repeater>

Edit

XOSQL Supported Keywords

SELECT, TOP, FROM, WHERE, AND, OR, LIKE, CONTAINS, =, !=, >, >=, <, <=, ORDER BY, DESC, ASC

Edit

Replacement Symbols

The following symbols are replaced at query execution time based on the current object and user profile context. Symbols are not case sensitive.

Edit

Current object replacement tags

{!oid} {!CurrentObject.oid} {!Object.oid} {!ObjectID}

Edit

Parent of the current object

{!parentid} {!CurrentObject.parentid} {!Object.parentid}

Edit

Foreign ID of the current object

{!id} {!CurrentObject.id} {!Object.id} {!CurrentObject.ForeignObjectID} {!Object.ForeignObjectID}

Edit

Current User Replacement Tags

{!profile.id} {!profile.profileid} {!currentuser.id} {!currentuser.profileid}

Edit

Current User Replacement Tags (CRM ID)

{!contact.id} {!lead.id} {!profile.ForeignObjectID} {!profile.contact.ForeignObjectID}

Example:
<dlog:Repeater id="Repeater1" XOSQL="SELECT Id FROM Document WHERE ParentID='{!Profile.Id}'>
   <HeaderTemplate>
      <table>
   </HeaderTemplate>
   <ItemTemplate>
      <tr><td> <dlog:Label id="DocNameLabel" FieldName="Name" />  </td></tr>
   </ItemTemplate>
   <FooterTemplate>
      </table>
   </FooterTemplate>
</dlog:Repeater>


<dlog:Repeater id="Repeater2" XOSQL="SELECT Id FROM Case WHERE ContactId='{!Contact.Id}'>
   <HeaderTemplate>
      <table>
   </HeaderTemplate>
   <ItemTemplate>
      <tr><td> <dlog:Label id="ItemLabel" FieldName="SolutionName" />  </td></tr>
   </ItemTemplate>
   <FooterTemplate>
      </table>
   </FooterTemplate>
</dlog:Repeater>


<dlog:Repeater id="Repeater3" XOSQL="SELECT Id FROM CaseComment WHERE ParentId='{!CurrentObject.Id}'>
   <HeaderTemplate>
      <table>
   </HeaderTemplate>
   <ItemTemplate>
      <tr><td> <dlog:Label id="ItemLabel" FieldName="CommentBody" />  </td></tr>
   </ItemTemplate>
   <FooterTemplate>
      </table>
   </FooterTemplate>
</dlog:Repeater>

ScrewTurn Wiki version 2.0.35. Some of the icons created by FamFamFam.