Columns
| Column | Type | Size | Nulls | Auto | Default | Children | Parents | Comments | ||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| id | int4 | 10 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| first_name | text | 2147483647 | null |
|
|
|||||||||||||||||||||||||||||||||
| last_name | text | 2147483647 | null |
|
|
|||||||||||||||||||||||||||||||||
| middle_name | text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| full_name | citext | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| sex | bpchar | 1 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| birthdate | date | 13 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| nation_id | int4 | 10 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| lang_id | int4 | 10 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| vip_id | int4 | 10 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| address1 | text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| address2 | text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| country_id | int4 | 10 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| country_res_id | int4 | 10 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| telephone | text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| fax | text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| mobile | text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| text | 2147483647 | √ | null |
|
|
|||||||||||||||||||||||||||||||||
| company | text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| occupation_id | int4 | 10 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| doc_number | citext | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| doc_type | int2 | 5 | √ | null |
|
|
1 = Passport , 2 = ID Card, 3 = Driving License |
|||||||||||||||||||||||||||||||
| credit_limit | t_money | 15,2 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| confidential | bool | 1 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| member_code | citext | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| carplate_no | text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| photo | bytea | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| remark | text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| image_count | int4 | 10 | √ | 0 |
|
|
||||||||||||||||||||||||||||||||
| visit_count | int4 | 10 | √ | 0 |
|
|
||||||||||||||||||||||||||||||||
| visit_nights | int4 | 10 | √ | 0 |
|
|
||||||||||||||||||||||||||||||||
| last_arrival | date | 13 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| last_departure | date | 13 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| phone_numbersXXX | _text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| emails | _text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| doc_country | int4 | 10 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| doc_expire | date | 13 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| city_id | int4 | 10 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| title_id | int4 | 10 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| likes | _text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| dislikes | _text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| credit_cards | _int4 | 10 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| telephones | _text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| mobiles | _text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| photo_id | int8 | 19 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| doc_id | int4 | 10 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| photo_url | text | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| revenues | jsonb | 2147483647 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| total_revenue | t_money | 15,2 | √ | null |
|
|
||||||||||||||||||||||||||||||||
| is_dummy | bool | 1 | false |
|
|
Indexes
| Constraint Name | Type | Sort | Column(s) |
|---|---|---|---|
| pk_guest | Primary key | Asc | id |
| idx_guest_city_id | Performance | Asc | city_id |
| idx_guest_country_id | Performance | Asc | country_id |
| idx_guest_doc_id | Performance | Asc | doc_id |
| idx_guest_full_name | Performance | Asc | full_name |
| idx_guest_is_dummy | Performance | Asc | is_dummy |
| idx_guest_lang_id | Performance | Asc | lang_id |
| idx_guest_nation_id | Performance | Asc | nation_id |
| idx_guest_res_country_id | Performance | Asc | country_res_id |
| idx_guest_title_id | Performance | Asc | title_id |
| idx_guest_vip_id | Performance | Asc | vip_id |



