SICISelect Protocol Reference

Conforms to NSObject
Declared in SICISelect.h

Overview

Exposes API’s to get tuples from table based on information provided.

– distinct required method

Used to specify DISTINCT condition.

- (id<SICISelect>)distinct

Return Value

SICICount Interface.

Discussion

Used to specify DISTINCT condition.

Declared In

SICISelect.h

– where: required method

Column name of which condition will be specified.

- (id<SICISelectClause>)where:(NSString *)column

Parameters

column

Name of column.

Return Value

SICISelectClause Interface.

Discussion

Column name of which condition will be specified.

Declared In

SICISelect.h

– whereClause: required method

Used to provide manually created Where clause, instead of using API’s.

- (id<SICISelect>)whereClause:(NSString *)whereClause

Parameters

whereClause

Manually created where clause.

Return Value

SICISelect Interface.

Discussion

Used to provide manually created Where clause, instead of using API’s.

Declared In

SICISelect.h

– and: required method

Used to specify AND condition between where clause.

- (id<SICISelectClause>)and:(NSString *)column

Parameters

column

Name of column on which condition need to be specified.

Return Value

SICISelectClause Interface.

Discussion

Used to specify AND condition between where clause.

Declared In

SICISelect.h

– or: required method

Used to specify OR condition between where clause.

- (id<SICISelectClause>)or:(NSString *)column

Parameters

column

Name of column on which condition need to be specified.

Return Value

SICISelectClause Interface.

Discussion

Used to specify OR condition between where clause.

Declared In

SICISelect.h

– orderBy: required method

Used to specify ORDER BY keyword to sort the result-set.

- (id<SICISelect>)orderBy:(NSArray *)columns

Parameters

columns

Name of columns which need to be sorted.

Return Value

SICISelect Interface.

Discussion

Used to specify ORDER BY keyword to sort the result-set.

Declared In

SICISelect.h

– ascendingOrderBy: required method

Used to specify ORDER BY ASC keyword to sort the result-set in ascending order.

- (id<SICISelect>)ascendingOrderBy:(NSArray *)columns

Parameters

columns

Name of columns which need to be sorted.

Return Value

SICISelect Interface.

Discussion

Used to specify ORDER BY ASC keyword to sort the result-set in ascending order.

Declared In

SICISelect.h

– descendingOrderBy: required method

Used to specify ORDER BY DESC keyword to sort the result-set in descending order.

- (id<SICISelect>)descendingOrderBy:(NSArray *)columns

Parameters

columns

Name of columns which need to be sorted.

Return Value

SICISelect Interface.

Discussion

Used to specify ORDER BY DESC keyword to sort the result-set in descending order.

Declared In

SICISelect.h

– limit: required method

Used to specify the range of data need to fetch from table.

- (id<SICISelect>)limit:(int)limit

Parameters

limit

LIMIT of data.

Return Value

SICISelect Interface.

Discussion

Used to specify the range of data need to fetch from table.

Declared In

SICISelect.h

– groupBy: required method

Used to specify GROUP BY statement in conjunction with the aggregate functions to group the result-set by one or more columns.

- (id<SICISelect>)groupBy:(NSArray *)columns

Parameters

columns

Name of columns.

Return Value

SICISelect Interface.

Discussion

Used to specify GROUP BY statement in conjunction with the aggregate functions to group the result-set by one or more columns.

Declared In

SICISelect.h

– having: required method

Used to specify HAVING clause to SQL because the WHERE keyword could not be used with aggregate functions.

- (id<SICISelectClause>)having:(NSString *)column

Parameters

column

Name of column on which condition need to be applied.

Return Value

SICISelectClause Interface.

Discussion

Used to specify HAVING clause to SQL because the WHERE keyword could not be used with aggregate functions.

Declared In

SICISelect.h

– havingClause: required method

Used to provide manually created Where clause, instead of using API’s.

- (id<SICISelect>)havingClause:(NSString *)havingClause

Parameters

havingClause

Where clause.

Return Value

SICISelect Interface.

Discussion

Used to provide manually created Where clause, instead of using API’s.

Declared In

SICISelect.h

– columns: required method

Used to provide name of column for which average will be calculated.

- (id<SICISelect>)columns:(NSArray *)column

Parameters

column

Name of column.

Return Value

SICISelect Interface.

Discussion

Used to provide name of column for which average will be calculated.

Declared In

SICISelect.h

– execute required method

Used to get average, this method should be called in last to calculate average.

- (id)execute

Return Value

Return average.

Discussion

Used to get average, this method should be called in last to calculate average.

Exceptions

SICDatabaseException

Throws exception if any error occur while calculating average.

Declared In

SICISelect.h