All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class Zql.ZQuery

java.lang.Object
   |
   +----Zql.ZQuery

public class ZQuery
extends Object
implements ZStatement, ZExp
ZQuery: an SQL SELECT statement


Constructor Index

 o ZQuery()
Create a new SELECT statement

Method Index

 o addFrom(Vector)
Insert the FROM part of the statement
 o addGroupBy(ZGroupBy)
Insert a GROUP BY...HAVING clause
 o addOrderBy(Vector)
Insert an ORDER BY clause
 o addSelect(Vector)
Insert the SELECT part of the statement
 o addSet(ZExpression)
Insert a SET clause (generally UNION, INTERSECT or MINUS)
 o addWhere(ZExp)
Insert a WHERE clause
 o getFrom()
Get the FROM part of the statement
 o getGroupBy()
Get the GROUP BY...HAVING part of the statement
 o getOrderBy()
Get the ORDER BY clause
 o getSelect()
Get the SELECT part of the statement
 o getSet()
Get the SET clause (generally UNION, INTERSECT or MINUS)
 o getWhere()
Get the WHERE part of the statement
 o isDistinct()
 o isForUpdate()
 o toString()

Constructors

 o ZQuery
 public ZQuery()
Create a new SELECT statement

Methods

 o addSelect
 public void addSelect(Vector s)
Insert the SELECT part of the statement

Parameters:
s - A vector of ZSelectItem objects
 o addFrom
 public void addFrom(Vector f)
Insert the FROM part of the statement

Parameters:
f - a Vector of ZFromItem objects
 o addWhere
 public void addWhere(ZExp w)
Insert a WHERE clause

Parameters:
w - An SQL Expression
 o addGroupBy
 public void addGroupBy(ZGroupBy g)
Insert a GROUP BY...HAVING clause

Parameters:
g - A GROUP BY...HAVING clause
 o addSet
 public void addSet(ZExpression s)
Insert a SET clause (generally UNION, INTERSECT or MINUS)

Parameters:
s - An SQL Expression (generally UNION, INTERSECT or MINUS)
 o addOrderBy
 public void addOrderBy(Vector v)
Insert an ORDER BY clause

Parameters:
v - A vector of ZOrderBy objects
 o getSelect
 public Vector getSelect()
Get the SELECT part of the statement

Returns:
A vector of ZSelectItem objects
 o getFrom
 public Vector getFrom()
Get the FROM part of the statement

Returns:
A vector of ZFromItem objects
 o getWhere
 public ZExp getWhere()
Get the WHERE part of the statement

Returns:
An SQL Expression or sub-query (ZExpression or ZQuery object)
 o getGroupBy
 public ZGroupBy getGroupBy()
Get the GROUP BY...HAVING part of the statement

Returns:
A GROUP BY...HAVING clause
 o getSet
 public ZExpression getSet()
Get the SET clause (generally UNION, INTERSECT or MINUS)

Returns:
An SQL Expression (generally UNION, INTERSECT or MINUS)
 o getOrderBy
 public Vector getOrderBy()
Get the ORDER BY clause

Parameters:
v - A vector of ZOrderBy objects
 o isDistinct
 public boolean isDistinct()
Returns:
true if it is a SELECT DISTINCT query, false otherwise.
 o isForUpdate
 public boolean isForUpdate()
Returns:
true if it is a FOR UPDATE query, false otherwise.
 o toString
 public String toString()
Overrides:
toString in class Object

All Packages  Class Hierarchy  This Package  Previous  Next  Index