Struct diesel::sql_types::Text [−][src]
pub struct Text;
The text SQL type.
On all backends strings must be valid UTF-8. On PostgreSQL strings must not include nul bytes.
Schema inference will treat all variants of TEXT
as this type (e.g.
VARCHAR
, MEDIUMTEXT
, etc).
ToSql
impls
FromSql
impls
Trait Implementations
impl SqlOrd for Text
[src]
impl SqlOrd for Text
impl QueryId for Text
[src]
impl QueryId for Text
type QueryId = Text
A type which uniquely represents Self
in a SQL query. Read more
const HAS_STATIC_QUERY_ID: bool
HAS_STATIC_QUERY_ID: bool = true
Can the SQL generated by Self
be uniquely identified by its type? Read more
fn query_id() -> Option<TypeId>
[src]
fn query_id() -> Option<TypeId>
Returns the type id of Self::QueryId
if Self::HAS_STATIC_QUERY_ID
. Returns None
otherwise. Read more
impl NotNull for Text
[src]
impl NotNull for Text
impl SingleValue for Text
[src]
impl SingleValue for Text
impl HasSqlType<Text> for Sqlite
[src]
impl HasSqlType<Text> for Sqlite
fn metadata(_: &()) -> SqliteType
[src]
fn metadata(_: &()) -> SqliteType
Fetch the metadata for the given type Read more
impl HasSqlType<Text> for Mysql
[src]
impl HasSqlType<Text> for Mysql
impl HasSqlType<Text> for Pg
[src]
impl HasSqlType<Text> for Pg
fn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
[src]
fn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
Fetch the metadata for the given type Read more
impl Debug for Text
[src]
impl Debug for Text
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Clone for Text
[src]
impl Clone for Text
fn clone(&self) -> Text
[src]
fn clone(&self) -> Text
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Copy for Text
[src]
impl Copy for Text
impl Default for Text
[src]
impl Default for Text
impl<'expr> AsExpression<Text> for &'expr String
[src]
impl<'expr> AsExpression<Text> for &'expr String
type Expression = Bound<Text, Self>
The expression being returned
fn as_expression(self) -> Self::Expression
[src]
fn as_expression(self) -> Self::Expression
Perform the conversion
impl<'expr2, 'expr> AsExpression<Text> for &'expr2 &'expr String
[src]
impl<'expr2, 'expr> AsExpression<Text> for &'expr2 &'expr String
type Expression = Bound<Text, Self>
The expression being returned
fn as_expression(self) -> Self::Expression
[src]
fn as_expression(self) -> Self::Expression
Perform the conversion
impl AsExpression<Text> for String
[src]
impl AsExpression<Text> for String
type Expression = Bound<Text, Self>
The expression being returned
fn as_expression(self) -> Self::Expression
[src]
fn as_expression(self) -> Self::Expression
Perform the conversion
impl<'expr> AsExpression<Text> for &'expr str
[src]
impl<'expr> AsExpression<Text> for &'expr str
type Expression = Bound<Text, Self>
The expression being returned
fn as_expression(self) -> Self::Expression
[src]
fn as_expression(self) -> Self::Expression
Perform the conversion
impl<'expr2, 'expr> AsExpression<Text> for &'expr2 &'expr str
[src]
impl<'expr2, 'expr> AsExpression<Text> for &'expr2 &'expr str
type Expression = Bound<Text, Self>
The expression being returned
fn as_expression(self) -> Self::Expression
[src]
fn as_expression(self) -> Self::Expression
Perform the conversion
impl<DB: Backend<RawValue = [u8]>> FromSql<Text, DB> for *const str
[src]
impl<DB: Backend<RawValue = [u8]>> FromSql<Text, DB> for *const str
The returned pointer is only valid for the lifetime to the argument of
from_sql
. This impl is intended for uses where you want to write a new
impl in terms of String
, but don't want to allocate. We have to return a
raw pointer instead of a reference with a lifetime due to the structure of
FromSql
impl<DB: Backend> ToSql<Text, DB> for str
[src]
impl<DB: Backend> ToSql<Text, DB> for str
impl<DB> ToSql<Text, DB> for String where
DB: Backend,
str: ToSql<Text, DB>,
[src]
impl<DB> ToSql<Text, DB> for String where
DB: Backend,
str: ToSql<Text, DB>,