PSTransactSqlGenerator Class Reference

Implementation for a Transact-SQL generator, which generates a Transact-SQL statement from a parse tree. More...

Inherits Simba::SQLEngine::PSSql92Generator.

List of all members.

Public Member Functions

 PSTransactSqlGenerator ()
 Constructor.
virtual ~PSTransactSqlGenerator ()
 Destructor.

Protected Member Functions

virtual simba_wstring GenerateConvertScalarFn (PSNonTerminalParseNode *in_node)
 Generates the SQL syntax for a PS_NT_SCALAR_OR_AGGR_FN node of type CONVERT.
virtual simba_wstring GenerateScalarFn (PSNonTerminalParseNode *in_node)
 Generates the SQL syntax for a PS_NT_SCALAR_OR_AGGR_FN node.

Detailed Description

Implementation for a Transact-SQL generator, which generates a Transact-SQL statement from a parse tree.

Transact-SQL syntax conventions are documented here: http://msdn.microsoft.com/en-us/library/ms177563.aspx


Constructor & Destructor Documentation

Constructor.

virtual ~PSTransactSqlGenerator (  )  [virtual]

Destructor.


Member Function Documentation

virtual simba_wstring GenerateConvertScalarFn ( PSNonTerminalParseNode in_node  )  [protected, virtual]

Generates the SQL syntax for a PS_NT_SCALAR_OR_AGGR_FN node of type CONVERT.

CONVERT is a special case as its syntax differs in Transact-SQL.

Generates the following syntax: CONVERT(datatype, expression)

Exceptions:
SEInvalidArgumentException if the given PS_NT_SCALAR_OR_AGGR_FN node is not of type CONVERT or if the parameter list does not contain exactly 2 children.
Parameters:
in_node A PS_NT_SCALAR_OR_AGGR_FN node of type CONVERT.
Returns:
The SQL syntax for a CONVERT scalar function node.

Reimplemented from PSSql92Generator.

virtual simba_wstring GenerateScalarFn ( PSNonTerminalParseNode in_node  )  [protected, virtual]

Generates the SQL syntax for a PS_NT_SCALAR_OR_AGGR_FN node.

A PS_NT_SCALAR_OR_AGGR_FN node is generated for the ODBC and SQL-92 Scalar Functions as noted in http://msdn.microsoft.com/en-us/library/ms711813(VS.85).aspx.

Generates the following syntax: ScalarFn(...) where ScalarFn is any of the supported scalar functions, (...) represents a variadic number of arguments corresponding with the particular scalar function.

Parameters:
in_node A PS_NT_SCALAR_OR_AGGR_FN node. (NOT OWN)
Exceptions:
SEInvalidArgumentException if the given node is not of type PS_NT_SCALAR_OR_AGGR_FN.
Returns:
The SQL syntax for the PS_NT_SCALAR_OR_AGGR_FN node.

Reimplemented from PSSql92Generator.


The documentation for this class was generated from the following file:

Generated on Wed May 17 14:21:18 2017 for SimbaEngine 10.1.3.1011 by simba