Ejemplo n.º 1
0
 /// <summary>
 /// Appends a word HAVING COUNT and a conditional field to the SQL Query Statement.
 /// </summary>
 /// <param name="queryField">The conditional field object used for composition.</param>
 /// <param name="index">The parameter index.</param>
 /// <param name="dbSetting">The currently in used <see cref="IDbSetting"/> object.</param>
 /// <returns>The current instance.</returns>
 public QueryBuilder HavingCountFrom(QueryField queryField,
                                     int index,
                                     IDbSetting dbSetting)
 {
     return(Append(string.Concat("HAVING COUNT(", queryField.Field.Name, ") ", queryField.GetOperationText(), ", ", queryField.AsParameter(index, dbSetting))));
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Appends a word HAVING COUNT and a conditional field to the SQL Query Statement.
 /// </summary>
 /// <param name="queryField">The conditional field object used for composition.</param>
 /// <returns>The current instance.</returns>
 public QueryBuilder <TEntity> HavingCountFrom(QueryField queryField)
 {
     return(Append(string.Concat("HAVING COUNT(", queryField.Field.AsField(), ") ", queryField.GetOperationText(), ", ", queryField.AsParameter())));
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Appends a word HAVING COUNT and a conditional field to the SQL Query Statement.
 /// </summary>
 /// <param name="queryField">The conditional field object used for composition.</param>
 /// <param name="index">The parameter index.</param>
 /// <param name="prefix">The prefix to the parameters.</param>
 /// <returns>The current instance.</returns>
 public QueryBuilder HavingCountFrom(QueryField queryField, int index = 0, string prefix = Constant.DefaultParameterPrefix)
 {
     return(Append(string.Concat("HAVING COUNT(", queryField.Field.Name, ") ", queryField.GetOperationText(), ", ", queryField.AsParameter(index, prefix))));
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Appends a word HAVING COUNT and a conditional field to the SQL Query Statement.
 /// </summary>
 /// <param name="queryField">The conditional field object used for composition.</param>
 /// <returns>The current instance.</returns>
 public QueryBuilder <TEntity> HavingCountFrom(QueryField queryField)
 {
     return(Append($"HAVING COUNT({queryField.Field.AsField()}) {queryField.GetOperationText()} {queryField.AsParameter()}"));
 }