Beispiel #1
0
 public void Append(SqlFragment sql, SqlPlaceHolderList placeHolders = null, SqlPrecedenceHandler precedenceHandler = null)
 {
     Fragments.Add(SqlTerms.NewLine);
     sql.Flatten(Fragments, precedenceHandler);
     if (placeHolders != null && placeHolders.Count > 0)
     {
         PlaceHolders.AddRange(placeHolders);
         ReIndexPlaceHolders();
     }
 }
Beispiel #2
0
 public SqlStatement(SqlKind kind, SqlFragment sql, SqlPlaceHolderList placeHolders, DbExecutionType executionType,
                     SqlPrecedenceHandler precedenceHandler = null, QueryOptions options = QueryOptions.None)
 {
     Kind          = kind;
     ExecutionType = executionType;
     Options       = options;
     Append(sql, placeHolders, precedenceHandler);
     if (placeHolders == null)
     {
         DiscoverPlaceholders();
     }
 }