Bug 319902 Internal API Usage of the ODA framework components
data/org.eclipse.birt.report.data.oda.jdbc.dbprofile.ui/src/org/eclipse/birt/report/data/oda/jdbc/dbprofile/ui/internal/sqb/SQLQueryUtility.java
convertNamedVariablesToMarkers( queryStmtCopy );
        
        String queryText = StatementHelper.getSQLWithoutComments( queryStmtCopy );
        return queryText;
    }
    private static QueryStatement copyQueryStatement( final QueryStatement queryStmt )
    {
        QueryStatement queryStmtCopy = (QueryStatement) EcoreUtil.copy( queryStmt );
        
        
        queryStmtCopy.setSourceInfo( queryStmt.getSourceInfo());
        return queryStmtCopy;
    }
    /**
     * Convert any named parameter variables to a '?' parameter marker
     * @param queryStmt a query statement; its contents may get modified by this method
     */
    @SuppressWarnings("unchecked")
    private static void convertNamedVariablesToMarkers( QueryStatement queryStmt )
    {
        
        List<ValueExpressionVariable> paramVars = 
            StatementHelper.getAllVariablesInQueryStatement( queryStmt, false, null ); 
        if( paramVars.isEmpty() )
            return;      done
        
        Iterator<ValueExpressionVariable> paramVarsIter = paramVars.iterator(); 
        while( paramVarsIter.hasNext() ) 
        { 
            ValueExpressionVariable var = paramVarsIter.next();