pub trait QueryService: Service {
// Required methods
fn execute_dataset_query<'life0, 'async_trait>(
&'life0 self,
query: DatasetQuery,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn execute_native_query<'life0, 'async_trait>(
&'life0 self,
database_id: i32,
query: NativeQuery,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn execute_raw_query<'life0, 'async_trait>(
&'life0 self,
query: Value,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn execute_pivot_query<'life0, 'async_trait>(
&'life0 self,
query: Value,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn execute_sql_with_params<'life0, 'life1, 'async_trait>(
&'life0 self,
database_id: i32,
sql: &'life1 str,
params: HashMap<String, Value>,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn execute_sql<'life0, 'life1, 'async_trait>(
&'life0 self,
database_id: i32,
sql: &'life1 str,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn export_query<'life0, 'life1, 'async_trait>(
&'life0 self,
format: &'life1 str,
query: Value,
) -> Pin<Box<dyn Future<Output = ServiceResult<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn validate_query<'life0, 'life1, 'async_trait>(
&'life0 self,
sql: &'life1 str,
) -> Pin<Box<dyn Future<Output = ServiceResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn validate_dataset_query<'life0, 'life1, 'async_trait>(
&'life0 self,
query: &'life1 DatasetQuery,
) -> Pin<Box<dyn Future<Output = ServiceResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}
Expand description
Service trait for Query operations
Required Methods§
Sourcefn execute_dataset_query<'life0, 'async_trait>(
&'life0 self,
query: DatasetQuery,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn execute_dataset_query<'life0, 'async_trait>(
&'life0 self,
query: DatasetQuery,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Execute a dataset query
Sourcefn execute_native_query<'life0, 'async_trait>(
&'life0 self,
database_id: i32,
query: NativeQuery,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn execute_native_query<'life0, 'async_trait>(
&'life0 self,
database_id: i32,
query: NativeQuery,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Execute a native SQL query
Sourcefn execute_raw_query<'life0, 'async_trait>(
&'life0 self,
query: Value,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn execute_raw_query<'life0, 'async_trait>(
&'life0 self,
query: Value,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Execute a raw query (JSON format)
Sourcefn execute_pivot_query<'life0, 'async_trait>(
&'life0 self,
query: Value,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn execute_pivot_query<'life0, 'async_trait>(
&'life0 self,
query: Value,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Execute a pivot query
Sourcefn execute_sql_with_params<'life0, 'life1, 'async_trait>(
&'life0 self,
database_id: i32,
sql: &'life1 str,
params: HashMap<String, Value>,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn execute_sql_with_params<'life0, 'life1, 'async_trait>(
&'life0 self,
database_id: i32,
sql: &'life1 str,
params: HashMap<String, Value>,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Execute a SQL query with parameters
Sourcefn execute_sql<'life0, 'life1, 'async_trait>(
&'life0 self,
database_id: i32,
sql: &'life1 str,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn execute_sql<'life0, 'life1, 'async_trait>(
&'life0 self,
database_id: i32,
sql: &'life1 str,
) -> Pin<Box<dyn Future<Output = ServiceResult<QueryResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Execute a simple SQL query
Sourcefn export_query<'life0, 'life1, 'async_trait>(
&'life0 self,
format: &'life1 str,
query: Value,
) -> Pin<Box<dyn Future<Output = ServiceResult<Vec<u8>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn export_query<'life0, 'life1, 'async_trait>(
&'life0 self,
format: &'life1 str,
query: Value,
) -> Pin<Box<dyn Future<Output = ServiceResult<Vec<u8>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Export query results
Sourcefn validate_query<'life0, 'life1, 'async_trait>(
&'life0 self,
sql: &'life1 str,
) -> Pin<Box<dyn Future<Output = ServiceResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn validate_query<'life0, 'life1, 'async_trait>(
&'life0 self,
sql: &'life1 str,
) -> Pin<Box<dyn Future<Output = ServiceResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Validate SQL query syntax (basic validation)
Sourcefn validate_dataset_query<'life0, 'life1, 'async_trait>(
&'life0 self,
query: &'life1 DatasetQuery,
) -> Pin<Box<dyn Future<Output = ServiceResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn validate_dataset_query<'life0, 'life1, 'async_trait>(
&'life0 self,
query: &'life1 DatasetQuery,
) -> Pin<Box<dyn Future<Output = ServiceResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Validate a dataset query