public async Task <IActionResult> ExtractingQuery([FromBody] ExtractingQueryModel extractingQuery)
        {
            _logger.Info("Extracing query model {@extractingQuery}", extractingQuery);
            var result = await _dynamicService.ExtractingQuery(extractingQuery);

            _logger.Info("Extracting result {@result}", result);
            return(Ok(result));
        }
示例#2
0
        public async Task <PopulateQueryModel> ExtractingQuery(ExtractingQueryModel extractingQuery)
        {
            var extractingResult = await
                                   _databaseServiceProvider
                                   .GetSchemasByQuery(extractingQuery.DatabaseId, extractingQuery.Query, extractingQuery.Parameters.Select(a => new Models.Databases.ExecuteParamModel {
                Name = a.Name, ReplaceValue = a.Value
            }));

            return(new PopulateQueryModel {
                ColumnFields = extractingResult.ColumnFields
            });
        }