sqlparser/functions.cpp
// XMLELEMENT in Oracle, DB2, Sybase ASA
XMLELEMENT in Oracle, DB2, Sybase ASA
XMLELEMENT in Oracle DB2 Sybase ASA
bool SqlParser::ParseFunctionXmlelement(Token *name, Token* )
{
	if(name == NULL)
		return false;
	STATS_DECL
	STATS_SET_DESC(SQL_FUNC_XMLELEMENT_DESC)
	 TOKEN_GETNEXTW("NAME");
	Token *element = GetNextToken();
	ParseExpression(element);
	while(true)
	{
		Token *comma = GetNextCharToken(',', L',');
		if(comma == NULL)
			break;
		Token *expn = GetNextToken();
		if(expn == NULL)
			break;
		ParseExpression(expn);
	}
	 (void) GetNextCharToken(')', L')');
	FUNC_STATS(name);
	return true;
}
bool SqlParser :: ParseFunctionXmlelement ( Token * name , Token * ) { if ( name == NULL ) return false ; STATS_DECL STATS_SET_DESC ( SQL_FUNC_XMLELEMENT_DESC ) TOKEN_GETNEXTW ( " " ) ; Token * element = GetNextToken ( ) ; ParseExpression ( element ) ; while ( true ) { Token * comma = GetNextCharToken ( ' ' , L' ' ) ; if ( comma == NULL ) break ; Token * expn = GetNextToken ( ) ; if ( expn == NULL ) break ; ParseExpression ( expn ) ; } ( void ) GetNextCharToken ( ' ' , L' ' ) ; FUNC_STATS ( name ) ; return true ; }
XMLELEMENT in Oracle, DB2, Sybase ASA
XMLELEMENT in Oracle DB2 Sybase ASA
/*open*/ // Optional NAME keyword /*Token *name_keyword */ // Parse element // Variable number of parameters // Parse next expression /*Token *close */