Default SQL Map contents

The default SQL map provides standard set of SQL Map IDs for various functionalities. Within a Logical Data Source all the SQL Map IDs are expected to be unique,because duplicate IDs result in initialization error. Hence, you should take care to ensure that all SQL Map IDs defined by you do not conflict with the existing Map IDs.


While there is no compulsion for the application to use the SQL fragments provided by default, not using some of these fragments may result in loss of functionality or indeterminate functionality when the result provided does not match to the expectations from the corresponding layers within the framework. With no more ado, let us look into the default set of fragments that are provided -


SQL Map Key

Purpose

Comments

Category: Default queries

DEFAULT_SELECT

This is the default SQL Map ID that is used by the Database request if the developer misses providing it.

Ideally this should never get executed

VIEW_MGR_FRMWK_MNT_SELECT_DEFAULT_VIEW_DATA

All Apps configured through the CT Studio Wizard ends up using this SQL Map ID.

This dynamically constructs the query based on the inputs provided in the wizard and fetches the data for the App using the query.

Category: Query Construction Reusable snippets 

NEW_PAGINATION_BEGINS

Provides the Paging query construct on top an existing query

Refer to the examples in Section 3 on how to assemble the query.

NEW_PAGINATION_ENDS

Provides the Paging query construct on top an existing query

Refer to the examples in Section 3 on how to assemble the query.

TOTALROWS_FOR_PAGINATION

Provides the Paging query construct on top an existing query

Refer to the examples in Section 3 on how to assemble the query.

NEW_DEFAULT_ORDERBY_CLAUSE

Constructs the dynamic sort conditions that works along with the Paging query construct

Refer to the examples in Section 3 on how to assemble the query.

FILTER_CLAUSE

Constructs the dynamic filter conditions


TOTALCOUNT_FOR_PAGINATION

Provides the Paging query construct on top an existing query

This is similar to the TOTALROWS_FOR_PAGINATION except that it returns the Total records in result set under the right Column name that can cascade back to framework. Refer to explanation provided for query construction below for more details.

Category: Internal Keys 

PAGINATION_BEGINS

Constructs the Paging query construct

This is deprecated. Use theNEW_PAGINATION_BEGINS instead.

PAGINATION_ENDS

Ending construct for the Paging query construct

This is deprecated. Use the NEW_PAGINATION_ENDS instead.

DEFAULT_ORDERBY_CLAUSE

Constructs the dynamic sort conditions

This is deprecated. Use the NEW_DEFAULT_ORDERBY_CLAUSE instead.

NEW_ORDERBY_CLAUSE

Constructs the dynamic sort conditions

This is deprecated. Use the NEW_DEFAULT_ORDERBY_CLAUSE instead.

FILTER_CLAUSE_FOR_STRING

Constructs dynamic filter for String

Internal keys. Not to be used directly

FILTER_CLAUSE_FOR_NUMSTR

Constructs dynamic filter for numeric string

Internal keys. Not to be used directly

FILTER_CLAUSE_FOR_TIME

Constructs dynamic filter for time

Internal keys. Not to be used directly

FILTER_CLAUSE_FOR_DATE

Constructs dynamic filter for date

Internal keys. Not to be used directly

FILTER_CLAUSE_FOR_NUMBER

Constructs dynamic filter for numeric (including amounts)

Internal keys. Not to be used directly

FILTER_CLAUSE_FOR_RATE

Constructs dynamic filter for Rate

Internal keys. Not to be used directly