private void CombineQueries(IResultSetsCommand resultSetsCommand) { foreach (var multiSource in _queries) { foreach (var cmd in multiSource.GetCommands()) { resultSetsCommand.Append(cmd); } } }
private void CombineQueries(IResultSetsCommand resultSetsCommand) { foreach (var query in _queries) { foreach (var cmd in query.GetCommands()) { resultSetsCommand.Append(cmd); } } }
private async Task CombineQueriesAsync(IResultSetsCommand resultSetsCommand, CancellationToken cancellationToken) { cancellationToken.ThrowIfCancellationRequested(); foreach (var multiSource in _queries) { foreach (var cmd in await(multiSource.GetCommandsAsync(cancellationToken)).ConfigureAwait(false)) { resultSetsCommand.Append(cmd); } } }
private void CombineCriteriaQueries() { foreach (CriteriaLoader loader in loaders) { CriteriaQueryTranslator translator = loader.Translator; translators.Add(translator); QueryParameters queryParameters = translator.GetQueryParameters(); parameters.Add(queryParameters); ISqlCommand singleCommand = loader.CreateSqlCommand(queryParameters, session); resultSetsCommand.Append(singleCommand); } }
private void CombineCriteriaQueries() { foreach (CriteriaLoader loader in loaders) { CriteriaQueryTranslator translator = loader.Translator; translators.Add(translator); QueryParameters queryParameters = translator.GetQueryParameters(); parameters.Add(queryParameters); SqlCommandInfo commandInfo = loader.GetQueryStringAndTypes(session, queryParameters, resultSetsCommand.ParametersCount); resultSetsCommand.Append(commandInfo); } }
private void AggregateQueriesInformation() { int queryIndex = 0; foreach (AbstractQueryImpl query in queries) { query.VerifyParameters(); QueryParameters queryParameters = query.GetQueryParameters(); queryParameters.ValidateParameters(); foreach (var translator in query.GetTranslators(session, queryParameters)) { translators.Add(translator); translatorQueryMap.Add(queryIndex); parameters.Add(queryParameters); ISqlCommand singleCommand = translator.Loader.CreateSqlCommand(queryParameters, session); resultSetsCommand.Append(singleCommand); } queryIndex++; } }