12.10. psql支援

Information about text search configuration objects can be obtained inpsqlusing a set of commands:

  1. \dF{d,p,t}[
  2. +
  3. ] [
  4. PATTERN
  5. ]

An optional+produces more details.

The optional parameterPATTERN_can be the name of a text search object, optionally schema-qualified. IfPATTERNis omitted then information about all visible objects will be displayed.PATTERN_can be a regular expression and can provide_separate_patterns for the schema and object names. The following examples illustrate this:

  1. =
  2. >
  3. \dF *fulltext*
  4. List of text search configurations
  5. Schema | Name | Description
  6. --------+--------------+-------------
  7. public | fulltext_cfg |
  1. =
  2. >
  3. \dF *.fulltext*
  4. List of text search configurations
  5. Schema | Name | Description
  6. ----------+----------------------------
  7. fulltext | fulltext_cfg |
  8. public | fulltext_cfg |

The available commands are:

\dF[

+

] [

PATTERN

]

List text search configurations (add+for more detail).

  1. =
  2. >
  3. \dF russian
  4. List of text search configurations
  5. Schema | Name | Description
  6. ------------+---------+------------------------------------
  7. pg_catalog | russian | configuration for russian language
  8. =
  9. >
  10. \dF+ russian
  11. Text search configuration "pg_catalog.russian"
  12. Parser: "pg_catalog.default"
  13. Token | Dictionaries
  14. -----------------+--------------
  15. asciihword | english_stem
  16. asciiword | english_stem
  17. email | simple
  18. file | simple
  19. float | simple
  20. host | simple
  21. hword | russian_stem
  22. hword_asciipart | english_stem
  23. hword_numpart | simple
  24. hword_part | russian_stem
  25. int | simple
  26. numhword | simple
  27. numword | simple
  28. sfloat | simple
  29. uint | simple
  30. url | simple
  31. url_path | simple
  32. version | simple
  33. word | russian_stem

\dFd[

+

] [

PATTERN

]

List text search dictionaries (add+for more detail).

  1. =
  2. >
  3. \dFd
  4. List of text search dictionaries
  5. Schema | Name | Description
  6. ------------+-----------------+-----------------------------------------------------------
  7. pg_catalog | danish_stem | snowball stemmer for danish language
  8. pg_catalog | dutch_stem | snowball stemmer for dutch language
  9. pg_catalog | english_stem | snowball stemmer for english language
  10. pg_catalog | finnish_stem | snowball stemmer for finnish language
  11. pg_catalog | french_stem | snowball stemmer for french language
  12. pg_catalog | german_stem | snowball stemmer for german language
  13. pg_catalog | hungarian_stem | snowball stemmer for hungarian language
  14. pg_catalog | italian_stem | snowball stemmer for italian language
  15. pg_catalog | norwegian_stem | snowball stemmer for norwegian language
  16. pg_catalog | portuguese_stem | snowball stemmer for portuguese language
  17. pg_catalog | romanian_stem | snowball stemmer for romanian language
  18. pg_catalog | russian_stem | snowball stemmer for russian language
  19. pg_catalog | simple | simple dictionary: just lower case and check for stopword
  20. pg_catalog | spanish_stem | snowball stemmer for spanish language
  21. pg_catalog | swedish_stem | snowball stemmer for swedish language
  22. pg_catalog | turkish_stem | snowball stemmer for turkish language

\dFp[

+

] [

PATTERN

]

List text search parsers (add+for more detail).

  1. =
  2. >
  3. \dFp
  4. List of text search parsers
  5. Schema | Name | Description
  6. ------------+---------+---------------------
  7. pg_catalog | default | default word parser
  8. =
  9. >
  10. \dFp+
  11. Text search parser "pg_catalog.default"
  12. Method | Function | Description
  13. -----------------+----------------+-------------
  14. Start parse | prsd_start |
  15. Get next token | prsd_nexttoken |
  16. End parse | prsd_end |
  17. Get headline | prsd_headline |
  18. Get token types | prsd_lextype |
  19. Token types for parser "pg_catalog.default"
  20. Token name | Description
  21. -----------------+------------------------------------------
  22. asciihword | Hyphenated word, all ASCII
  23. asciiword | Word, all ASCII
  24. blank | Space symbols
  25. email | Email address
  26. entity | XML entity
  27. file | File or path name
  28. float | Decimal notation
  29. host | Host
  30. hword | Hyphenated word, all letters
  31. hword_asciipart | Hyphenated word part, all ASCII
  32. hword_numpart | Hyphenated word part, letters and digits
  33. hword_part | Hyphenated word part, all letters
  34. int | Signed integer
  35. numhword | Hyphenated word, letters and digits
  36. numword | Word, letters and digits
  37. protocol | Protocol head
  38. sfloat | Scientific notation
  39. tag | XML tag
  40. uint | Unsigned integer
  41. url | URL
  42. url_path | URL path
  43. version | Version number
  44. word | Word, all letters
  45. (23 rows)

\dFt[

+

] [

PATTERN

]

List text search templates (add+for more detail).

  1. =
  2. >
  3. \dFt
  4. List of text search templates
  5. Schema | Name | Description
  6. ------------+-----------+-----------------------------------------------------------
  7. pg_catalog | ispell | ispell dictionary
  8. pg_catalog | simple | simple dictionary: just lower case and check for stopword
  9. pg_catalog | snowball | snowball stemmer
  10. pg_catalog | synonym | synonym dictionary: replace word by its synonym
  11. pg_catalog | thesaurus | thesaurus dictionary: phrase by phrase substitution