mod cache;
#[cfg(all(feature = "sql", feature = "diagnostics"))]
mod diagnostics;
mod dynamic;
#[cfg(feature = "sql")]
mod grouped;
mod projection;
use crate::db::{QueryError, executor::ExecutorPlanError};
pub(in crate::db) use cache::QueryPlanCacheAttribution;
#[cfg(feature = "diagnostics")]
pub(in crate::db) use cache::QueryPlanCompilePhaseAttribution;
#[cfg(feature = "sql-explain")]
pub(in crate::db::session) use cache::query_plan_cache_reuse_event;
#[cfg(all(feature = "sql", feature = "diagnostics"))]
pub use diagnostics::{
DirectDataRowAttribution, GroupedCountAttribution, GroupedExecutionAttribution,
KernelRowAttribution, ScalarAggregateAttribution,
};
pub(in crate::db) use projection::StructuralProjectionContract;
pub(in crate::db::session) use projection::StructuralProjectionPayload;
#[cfg(feature = "sql-explain")]
pub(in crate::db::session) use projection::projection_labels_from_projection_spec;
pub(in crate::db::session) fn query_error_from_executor_plan_error(
err: ExecutorPlanError,
) -> QueryError {
match err {
ExecutorPlanError::Cursor(err) => QueryError::from_cursor_plan_error(*err),
}
}