EFIngresProvider/SqlGen/SqlGenerator/SqlGeneratorHelpers.cs
/// <summary>
/// Translates a list of SortClauses.
/// Used in the translation of OrderBy 
/// </summary>
/// <param name="orderByClause">The SqlBuilder to which the sort keys should be appended</param>
/// <param name="sortKeys"></param>
Translates a list of SortClauses.
Used in the translation of OrderBy
Translates a list of SortClauses . Used in the translation of OrderBy
private void AddSortKeys(SqlBuilder orderByClause, IList<DbSortClause> sortKeys)
        {
            string separator = "";
            foreach (DbSortClause sortClause in sortKeys)
            {
                orderByClause.Append(separator);
                orderByClause.Append(sortClause.Expression.Accept(this));
                Debug.Assert(sortClause.Collation != null);
                if (!String.IsNullOrEmpty(sortClause.Collation))
                {
                    orderByClause.Append(" collate ");
                    orderByClause.Append(sortClause.Collation);
                }
                orderByClause.Append(sortClause.Ascending ? " asc" : " desc");
                separator = ", ";
            }
        }
private void AddSortKeys ( SqlBuilder orderByClause , IList < DbSortClause > sortKeys ) { string separator = " " ; foreach ( DbSortClause sortClause in sortKeys ) { orderByClause . Append ( separator ) ; orderByClause . Append ( sortClause . Expression . Accept ( this ) ) ; Debug . Assert ( sortClause . Collation != null ) ; if ( ! String . IsNullOrEmpty ( sortClause . Collation ) ) { orderByClause . Append ( " " ) ; orderByClause . Append ( sortClause . Collation ) ; } orderByClause . Append ( sortClause . Ascending ? " " : " " ) ; separator = " " ; } }
Translates a list of SortClauses.
Translates a list of SortClauses .
// TODO: Is collate supported by Ingres?
orderByClause
SqlBuilder
The SqlBuilder to which the sort keys should be appended
The SqlBuilder to which the sort keys should be appended
sortKeys
IList<DbSortClause>
None