Skip to main content

check_read_only

Function check_read_only 

Source
pub fn check_read_only(sql: &str) -> Result<(), String>
Expand description

Accepts a single read-only SELECT-style query and rejects everything else: other statement kinds, several statements, and calls to mutating or admin-only functions anywhere in the query.