Skip to main content

ValidateOnlyKind

Enum ValidateOnlyKind 

Source
pub enum ValidateOnlyKind {
Show 16 variants LockTable, RoleName, SecurityLabel, ExtensionAvailable, TypeName, AggregateName, ConversionName, LanguageName, CollationName, TsConfigName, EventTriggerName, TablespaceName, LargeObjectOid, ForeignInfra, ExtensionInstalled, SessionAuthorization,
}
Expand description

v7.39 (round 696) — which operand a Statement::ValidateOnly names, and therefore which catalog answers whether it exists.

Variants§

§

LockTable

LOCK TABLE <t> [, …] — the relation must exist.

§

RoleName

Every role named must exist: DROP OWNED BY <r> [, …], REASSIGN OWNED BY <r> [, …] TO <r>, ALTER ROLE <r> ….

§

SecurityLabel

SECURITY LABEL … — PG refuses unconditionally, because no label provider is loaded. SPG has none either.

§

ExtensionAvailable

v7.39 (round 697) — CREATE EXTENSION <e>: the extension must be AVAILABLE (PG: extension "x" is not available).

§

TypeName

v7.39 (round 708) — ALTER TYPE <t> <any no-op form>: the TYPE must exist (PG: type "x" does not exist); the action itself stays a no-op (PG genuinely renames; that residual is recorded).

§

AggregateName

v7.39 (round 708) — ALTER AGGREGATE name(args) …: names[0] is the aggregate, the rest its argument type names (* = the (*) form). Existence only; the action no-ops (PG really renames built-ins — measured — and SPG does not model that).

§

ConversionName

v7.39 (round 708) — DROP CONVERSION <c>: SPG ships no conversions, so every name answers PG’s conversion "x" does not exist.

§

LanguageName

v7.39 (round 708) — DROP LANGUAGE <l>: an unknown language does not exist; a shipped one is required (PG’s two wordings, measured).

§

CollationName

v7.39 (round 709) — a collation name: performable or PG’s collation "x" for encoding "UTF8" does not exist.

§

TsConfigName

v7.39 (round 709) — a text search configuration name.

§

EventTriggerName

v7.39 (round 709) — an event trigger name. SPG has none, so the not-found answer is total.

§

TablespaceName

v7.39 (round 709) — a tablespace name. SPG has none beyond PG’s two built-ins, whose drop PG refuses with permission denied (measured).

§

LargeObjectOid

v7.39 (round 709) — a large-object oid (names[0], decimal). The registry is real (round 287), so the check is a lookup.

§

ForeignInfra

v7.39 (round 706) — CREATE SERVER / CREATE FOREIGN TABLE / CREATE FOREIGN DATA WRAPPER. SPG has no foreign-data infrastructure at all, so PG’s refusals (foreign-data wrapper "x" does not exist, server "x" does not exist) cannot be copied — PG can refuse because the missing piece is installable there. Accepted with a WARNING, the extension resolution (round 697): refusing turns a dump that restores today into one that needs editing, and silent acceptance was the actual defect.

§

ExtensionInstalled

v7.39 (round 697) — DROP EXTENSION <e>: it must be installed (PG: extension "x" does not exist).

§

SessionAuthorization

v7.40.12 — SET SESSION AUTHORIZATION <r>. APPENDED, not inserted: putting it beside RoleName where it belongs read better and shifted thirteen discriminants, which cargo-semver-checks calls out as its own breaking change (enum_no_repr_variant_discriminant_changed) for anyone casting the enum. Reading order is not worth a break nobody asked for.

It used to share RoleName with the three role statements, and one question separates them: PG does NOT count this statement as a query, so a later SET TRANSACTION ISOLATION LEVEL still succeeds, while after DROP OWNED BY, REASSIGN OWNED BY or ALTER ROLE it is refused with 25001. All four measured on PG 18.6. The role check is identical; the snapshot answer is not.

Trait Implementations§

Source§

impl Clone for ValidateOnlyKind

Source§

fn clone(&self) -> ValidateOnlyKind

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for ValidateOnlyKind

Source§

impl Debug for ValidateOnlyKind

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for ValidateOnlyKind

Source§

impl PartialEq for ValidateOnlyKind

Source§

fn eq(&self, other: &ValidateOnlyKind) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for ValidateOnlyKind

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.