Struct tusk_rs::query::PostgresField
source · pub struct PostgresField {
pub alias: &'static str,
pub location: PostgresFieldLocation,
}
Expand description
A struct that symbolizes a field in a Postgres table. This is used for reading from tables.
Intializing this struct manually is frowned upon. The easiest way to construct a PostgresField is to use the macros provided.
- [
local
] for a field on the table itself. - [
local_as
] for a field on the table itself with an alias. - [
expression
] for an expression. - [
foreign
] for a field on a foreign table. - [
foreign_as
] for a field on a foreign table with an alias.
Fields§
§alias: &'static str
§location: PostgresFieldLocation
Implementations§
source§impl PostgresField
impl PostgresField
pub fn into_syntax(&self, local_table: &str) -> String
Auto Trait Implementations§
impl Freeze for PostgresField
impl RefUnwindSafe for PostgresField
impl Send for PostgresField
impl Sync for PostgresField
impl Unpin for PostgresField
impl UnwindSafe for PostgresField
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more