sharix_open_schema.sql 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839
  1. --
  2. -- PostgreSQL database dump
  3. --
  4. -- Dumped from database version 12.7
  5. -- Dumped by pg_dump version 12.7
  6. SET statement_timeout = 0;
  7. SET lock_timeout = 0;
  8. SET idle_in_transaction_session_timeout = 0;
  9. SET client_encoding = 'UTF8';
  10. SET standard_conforming_strings = on;
  11. SELECT pg_catalog.set_config('search_path', '', false);
  12. SET check_function_bodies = false;
  13. SET xmloption = content;
  14. SET client_min_messages = warning;
  15. SET row_security = off;
  16. SET default_tablespace = '';
  17. SET default_table_access_method = heap;
  18. --
  19. -- Name: client; Type: TABLE; Schema: public; Owner: postgres
  20. --
  21. CREATE TABLE public.client (
  22. id integer NOT NULL,
  23. user_id integer NOT NULL,
  24. requirements name NOT NULL,
  25. status character(1) DEFAULT 'A'::bpchar,
  26. ticket_status integer,
  27. id_metaservice integer NOT NULL,
  28. is_global character(1) NOT NULL,
  29. is_visible character(1) NOT NULL
  30. );
  31. ALTER TABLE public.client OWNER TO postgres;
  32. --
  33. -- Name: client_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
  34. --
  35. CREATE SEQUENCE public.client_id_seq
  36. AS integer
  37. START WITH 1
  38. INCREMENT BY 1
  39. NO MINVALUE
  40. NO MAXVALUE
  41. CACHE 1;
  42. ALTER TABLE public.client_id_seq OWNER TO postgres;
  43. --
  44. -- Name: client_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
  45. --
  46. ALTER SEQUENCE public.client_id_seq OWNED BY public.client.id;
  47. --
  48. -- Name: company; Type: TABLE; Schema: public; Owner: postgres
  49. --
  50. CREATE TABLE public.company (
  51. id character varying(10) NOT NULL,
  52. legal_name character varying(255) NOT NULL,
  53. provider_id integer NOT NULL,
  54. kpp character varying(9) NOT NULL,
  55. ogrn character varying(13) NOT NULL,
  56. bank_name character varying(255) NOT NULL,
  57. bik character varying(9) NOT NULL,
  58. ks integer NOT NULL,
  59. rs integer NOT NULL,
  60. address character varying(255) NOT NULL,
  61. id_metaservice integer,
  62. is_global character(1) NOT NULL,
  63. is_visible character(1) NOT NULL,
  64. requirements name,
  65. status character(1) DEFAULT 'A'::bpchar,
  66. ticket_status integer
  67. );
  68. ALTER TABLE public.company OWNER TO postgres;
  69. --
  70. -- Name: current_orders; Type: TABLE; Schema: public; Owner: postgres
  71. --
  72. CREATE TABLE public.current_orders (
  73. id integer NOT NULL,
  74. service_id integer NOT NULL,
  75. service_type_id integer NOT NULL,
  76. state integer NOT NULL,
  77. id_metaservice integer NOT NULL,
  78. time_created timestamp with time zone NOT NULL,
  79. time_placed timestamp with time zone NOT NULL,
  80. time_start timestamp with time zone NOT NULL,
  81. time_finish_predicted timestamp with time zone NOT NULL,
  82. time_finish_real timestamp with time zone NOT NULL,
  83. provider_id integer NOT NULL,
  84. receiver_id integer NOT NULL,
  85. client_id integer NOT NULL,
  86. predicted_price numeric(10,2) NOT NULL,
  87. real_price numeric(10,2) NOT NULL,
  88. is_global character(1) NOT NULL,
  89. is_visible character(1) NOT NULL
  90. );
  91. ALTER TABLE public.current_orders OWNER TO postgres;
  92. --
  93. -- Name: current_orders_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
  94. --
  95. CREATE SEQUENCE public.current_orders_id_seq
  96. AS integer
  97. START WITH 1
  98. INCREMENT BY 1
  99. NO MINVALUE
  100. NO MAXVALUE
  101. CACHE 1;
  102. ALTER TABLE public.current_orders_id_seq OWNER TO postgres;
  103. --
  104. -- Name: current_orders_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
  105. --
  106. ALTER SEQUENCE public.current_orders_id_seq OWNED BY public.current_orders.id;
  107. --
  108. -- Name: current_timetable; Type: TABLE; Schema: public; Owner: postgres
  109. --
  110. CREATE TABLE public.current_timetable (
  111. id integer NOT NULL,
  112. order_id integer NOT NULL,
  113. service_type_id integer NOT NULL,
  114. provider_id integer NOT NULL,
  115. resource_id integer,
  116. time_start_predicted timestamp with time zone,
  117. time_finished_predicted timestamp with time zone,
  118. gap integer
  119. );
  120. ALTER TABLE public.current_timetable OWNER TO postgres;
  121. --
  122. -- Name: current_timetable_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
  123. --
  124. CREATE SEQUENCE public.current_timetable_id_seq
  125. AS integer
  126. START WITH 1
  127. INCREMENT BY 1
  128. NO MINVALUE
  129. NO MAXVALUE
  130. CACHE 1;
  131. ALTER TABLE public.current_timetable_id_seq OWNER TO postgres;
  132. --
  133. -- Name: current_timetable_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
  134. --
  135. ALTER SEQUENCE public.current_timetable_id_seq OWNED BY public.current_timetable.id;
  136. --
  137. -- Name: documents; Type: TABLE; Schema: public; Owner: postgres
  138. --
  139. CREATE TABLE public.documents (
  140. id integer NOT NULL,
  141. id_metaservice integer NOT NULL,
  142. doctype character varying(2) NOT NULL,
  143. expire_date date NOT NULL,
  144. datalink name,
  145. user_id integer NOT NULL,
  146. company_id integer,
  147. is_global character(1) NOT NULL,
  148. is_visible character(1) NOT NULL,
  149. check_level character(1),
  150. check_by integer,
  151. check_date timestamp with time zone,
  152. status character(1),
  153. ticket_status integer
  154. );
  155. ALTER TABLE public.documents OWNER TO postgres;
  156. --
  157. -- Name: documents_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
  158. --
  159. CREATE SEQUENCE public.documents_id_seq
  160. AS integer
  161. START WITH 1
  162. INCREMENT BY 1
  163. NO MINVALUE
  164. NO MAXVALUE
  165. CACHE 1;
  166. ALTER TABLE public.documents_id_seq OWNER TO postgres;
  167. --
  168. -- Name: documents_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
  169. --
  170. ALTER SEQUENCE public.documents_id_seq OWNED BY public.documents.id;
  171. --
  172. -- Name: order_list_log; Type: TABLE; Schema: public; Owner: sharix
  173. --
  174. CREATE TABLE public.order_list_log (
  175. id integer NOT NULL,
  176. payment_transaction_id integer,
  177. service_id integer,
  178. time_placed timestamp with time zone,
  179. time_start timestamp with time zone,
  180. time_finish_predicted timestamp with time zone,
  181. time_finish_real timestamp with time zone,
  182. order_place_start name,
  183. order_place_predicted name,
  184. order_place_real name,
  185. price integer,
  186. provider integer,
  187. receiver integer,
  188. client integer
  189. );
  190. ALTER TABLE public.order_list_log OWNER TO sharix;
  191. --
  192. -- Name: order_list_log_id_seq; Type: SEQUENCE; Schema: public; Owner: sharix
  193. --
  194. CREATE SEQUENCE public.order_list_log_id_seq
  195. AS integer
  196. START WITH 1
  197. INCREMENT BY 1
  198. NO MINVALUE
  199. NO MAXVALUE
  200. CACHE 1;
  201. ALTER TABLE public.order_list_log_id_seq OWNER TO sharix;
  202. --
  203. -- Name: order_list_log_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: sharix
  204. --
  205. ALTER SEQUENCE public.order_list_log_id_seq OWNED BY public.order_list_log.id;
  206. --
  207. -- Name: orders; Type: TABLE; Schema: public; Owner: postgres
  208. --
  209. CREATE TABLE public.orders (
  210. id integer NOT NULL,
  211. service_id integer NOT NULL,
  212. service_type_id integer NOT NULL,
  213. state integer NOT NULL,
  214. id_metaservice integer NOT NULL,
  215. time_created timestamp with time zone NOT NULL,
  216. time_placed timestamp with time zone NOT NULL,
  217. time_start timestamp with time zone NOT NULL,
  218. time_finish_predicted timestamp with time zone NOT NULL,
  219. time_finish_real timestamp with time zone NOT NULL,
  220. provider_id integer NOT NULL,
  221. receiver_id integer NOT NULL,
  222. client_id integer NOT NULL,
  223. predicted_price numeric(10,2) NOT NULL,
  224. real_price numeric(10,2) NOT NULL,
  225. is_global character(1) NOT NULL,
  226. is_visible character(1) NOT NULL
  227. );
  228. ALTER TABLE public.orders OWNER TO postgres;
  229. --
  230. -- Name: orders_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
  231. --
  232. CREATE SEQUENCE public.orders_id_seq
  233. AS integer
  234. START WITH 1
  235. INCREMENT BY 1
  236. NO MINVALUE
  237. NO MAXVALUE
  238. CACHE 1;
  239. ALTER TABLE public.orders_id_seq OWNER TO postgres;
  240. --
  241. -- Name: orders_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
  242. --
  243. ALTER SEQUENCE public.orders_id_seq OWNED BY public.orders.id;
  244. --
  245. -- Name: permissions; Type: TABLE; Schema: public; Owner: postgres
  246. --
  247. CREATE TABLE public.permissions (
  248. id integer NOT NULL,
  249. id_metaservice integer NOT NULL,
  250. id_permission integer NOT NULL,
  251. user_id integer NOT NULL,
  252. is_global character(1) NOT NULL,
  253. is_visible character(1) NOT NULL,
  254. check_level character(1),
  255. check_by integer,
  256. check_date timestamp with time zone NOT NULL,
  257. status character(1),
  258. ticket_status integer
  259. );
  260. ALTER TABLE public.permissions OWNER TO postgres;
  261. --
  262. -- Name: permissions_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
  263. --
  264. CREATE SEQUENCE public.permissions_id_seq
  265. AS integer
  266. START WITH 1
  267. INCREMENT BY 1
  268. NO MINVALUE
  269. NO MAXVALUE
  270. CACHE 1;
  271. ALTER TABLE public.permissions_id_seq OWNER TO postgres;
  272. --
  273. -- Name: permissions_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
  274. --
  275. ALTER SEQUENCE public.permissions_id_seq OWNED BY public.permissions.id;
  276. --
  277. -- Name: provider; Type: TABLE; Schema: public; Owner: postgres
  278. --
  279. CREATE TABLE public.provider (
  280. id integer NOT NULL,
  281. type integer NOT NULL,
  282. id_company integer NOT NULL,
  283. user_id integer NOT NULL,
  284. requirements name NOT NULL,
  285. status character(1) DEFAULT 'A'::bpchar,
  286. ticket_status integer,
  287. id_metaservice integer NOT NULL,
  288. is_global character(1) NOT NULL,
  289. is_visible character(1) NOT NULL,
  290. location_type name NOT NULL,
  291. default_location name NOT NULL
  292. );
  293. ALTER TABLE public.provider OWNER TO postgres;
  294. --
  295. -- Name: provider_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
  296. --
  297. CREATE SEQUENCE public.provider_id_seq
  298. AS integer
  299. START WITH 1
  300. INCREMENT BY 1
  301. NO MINVALUE
  302. NO MAXVALUE
  303. CACHE 1;
  304. ALTER TABLE public.provider_id_seq OWNER TO postgres;
  305. --
  306. -- Name: provider_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
  307. --
  308. ALTER SEQUENCE public.provider_id_seq OWNED BY public.provider.id;
  309. --
  310. -- Name: relationship; Type: TABLE; Schema: public; Owner: postgres
  311. --
  312. CREATE TABLE public.relationship (
  313. id integer NOT NULL,
  314. user_id_who integer,
  315. user_id_whom integer,
  316. neg_type character(1),
  317. id_metaservice integer,
  318. is_global character(1) NOT NULL,
  319. is_visible character(1) NOT NULL,
  320. requirements name,
  321. status character(1) DEFAULT 'A'::bpchar,
  322. ticket_status integer
  323. );
  324. ALTER TABLE public.relationship OWNER TO postgres;
  325. --
  326. -- Name: relationship_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
  327. --
  328. CREATE SEQUENCE public.relationship_id_seq
  329. AS integer
  330. START WITH 1
  331. INCREMENT BY 1
  332. NO MINVALUE
  333. NO MAXVALUE
  334. CACHE 1;
  335. ALTER TABLE public.relationship_id_seq OWNER TO postgres;
  336. --
  337. -- Name: relationship_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
  338. --
  339. ALTER SEQUENCE public.relationship_id_seq OWNED BY public.relationship.id;
  340. --
  341. -- Name: resource; Type: TABLE; Schema: public; Owner: postgres
  342. --
  343. CREATE TABLE public.resource (
  344. id integer NOT NULL,
  345. type_id integer NOT NULL,
  346. user_id integer NOT NULL,
  347. requirements name NOT NULL,
  348. status character(1) DEFAULT 'A'::bpchar,
  349. ticket_status integer,
  350. id_metaservice integer NOT NULL,
  351. is_global character(1) NOT NULL,
  352. is_visible character(1) NOT NULL
  353. );
  354. ALTER TABLE public.resource OWNER TO postgres;
  355. --
  356. -- Name: resource_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
  357. --
  358. CREATE SEQUENCE public.resource_id_seq
  359. AS integer
  360. START WITH 1
  361. INCREMENT BY 1
  362. NO MINVALUE
  363. NO MAXVALUE
  364. CACHE 1;
  365. ALTER TABLE public.resource_id_seq OWNER TO postgres;
  366. --
  367. -- Name: resource_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
  368. --
  369. ALTER SEQUENCE public.resource_id_seq OWNED BY public.resource.id;
  370. --
  371. -- Name: service; Type: TABLE; Schema: public; Owner: postgres
  372. --
  373. CREATE TABLE public.service (
  374. id integer NOT NULL,
  375. servicetype_id integer NOT NULL,
  376. id_provider integer NOT NULL,
  377. resourse_id integer NOT NULL,
  378. price_alg character varying(255) NOT NULL,
  379. price_km integer NOT NULL,
  380. price_min integer NOT NULL,
  381. price_amount integer NOT NULL,
  382. id_metaservice integer,
  383. is_global character(1) NOT NULL,
  384. is_visible character(1) NOT NULL,
  385. requirements name,
  386. status character(1) DEFAULT 'A'::bpchar,
  387. ticket_status integer
  388. );
  389. ALTER TABLE public.service OWNER TO postgres;
  390. --
  391. -- Name: service_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
  392. --
  393. CREATE SEQUENCE public.service_id_seq
  394. AS integer
  395. START WITH 1
  396. INCREMENT BY 1
  397. NO MINVALUE
  398. NO MAXVALUE
  399. CACHE 1;
  400. ALTER TABLE public.service_id_seq OWNER TO postgres;
  401. --
  402. -- Name: service_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
  403. --
  404. ALTER SEQUENCE public.service_id_seq OWNED BY public.service.id;
  405. --
  406. -- Name: servicetype; Type: TABLE; Schema: public; Owner: postgres
  407. --
  408. CREATE TABLE public.servicetype (
  409. id integer NOT NULL,
  410. caption character varying(255) NOT NULL,
  411. description text NOT NULL,
  412. pricetype integer NOT NULL,
  413. id_metaservice integer,
  414. is_global character(1) NOT NULL,
  415. is_visible character(1) NOT NULL,
  416. requirements name,
  417. status character(1) DEFAULT 'A'::bpchar,
  418. ticket_status integer
  419. );
  420. ALTER TABLE public.servicetype OWNER TO postgres;
  421. --
  422. -- Name: servicetype_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
  423. --
  424. CREATE SEQUENCE public.servicetype_id_seq
  425. AS integer
  426. START WITH 1
  427. INCREMENT BY 1
  428. NO MINVALUE
  429. NO MAXVALUE
  430. CACHE 1;
  431. ALTER TABLE public.servicetype_id_seq OWNER TO postgres;
  432. --
  433. -- Name: servicetype_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
  434. --
  435. ALTER SEQUENCE public.servicetype_id_seq OWNED BY public.servicetype.id;
  436. --
  437. -- Name: tickets; Type: TABLE; Schema: public; Owner: sharix
  438. --
  439. CREATE TABLE public.tickets (
  440. id integer NOT NULL,
  441. id_reporter integer,
  442. id_asignee integer,
  443. time_created timestamp with time zone,
  444. time_assigned timestamp with time zone,
  445. time_changed timestamp with time zone,
  446. time_closed timestamp with time zone,
  447. status integer,
  448. description text
  449. );
  450. ALTER TABLE public.tickets OWNER TO sharix;
  451. --
  452. -- Name: tickets_id_seq; Type: SEQUENCE; Schema: public; Owner: sharix
  453. --
  454. CREATE SEQUENCE public.tickets_id_seq
  455. AS integer
  456. START WITH 1
  457. INCREMENT BY 1
  458. NO MINVALUE
  459. NO MAXVALUE
  460. CACHE 1;
  461. ALTER TABLE public.tickets_id_seq OWNER TO sharix;
  462. --
  463. -- Name: tickets_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: sharix
  464. --
  465. ALTER SEQUENCE public.tickets_id_seq OWNED BY public.tickets.id;
  466. --
  467. -- Name: users; Type: TABLE; Schema: public; Owner: drive
  468. --
  469. CREATE TABLE public.users (
  470. id integer DEFAULT 0 NOT NULL,
  471. name text,
  472. access text,
  473. login text,
  474. password text
  475. );
  476. ALTER TABLE public.users OWNER TO drive;
  477. --
  478. -- Name: client id; Type: DEFAULT; Schema: public; Owner: postgres
  479. --
  480. ALTER TABLE ONLY public.client ALTER COLUMN id SET DEFAULT nextval('public.client_id_seq'::regclass);
  481. --
  482. -- Name: current_orders id; Type: DEFAULT; Schema: public; Owner: postgres
  483. --
  484. ALTER TABLE ONLY public.current_orders ALTER COLUMN id SET DEFAULT nextval('public.current_orders_id_seq'::regclass);
  485. --
  486. -- Name: current_timetable id; Type: DEFAULT; Schema: public; Owner: postgres
  487. --
  488. ALTER TABLE ONLY public.current_timetable ALTER COLUMN id SET DEFAULT nextval('public.current_timetable_id_seq'::regclass);
  489. --
  490. -- Name: documents id; Type: DEFAULT; Schema: public; Owner: postgres
  491. --
  492. ALTER TABLE ONLY public.documents ALTER COLUMN id SET DEFAULT nextval('public.documents_id_seq'::regclass);
  493. --
  494. -- Name: order_list_log id; Type: DEFAULT; Schema: public; Owner: sharix
  495. --
  496. ALTER TABLE ONLY public.order_list_log ALTER COLUMN id SET DEFAULT nextval('public.order_list_log_id_seq'::regclass);
  497. --
  498. -- Name: orders id; Type: DEFAULT; Schema: public; Owner: postgres
  499. --
  500. ALTER TABLE ONLY public.orders ALTER COLUMN id SET DEFAULT nextval('public.orders_id_seq'::regclass);
  501. --
  502. -- Name: permissions id; Type: DEFAULT; Schema: public; Owner: postgres
  503. --
  504. ALTER TABLE ONLY public.permissions ALTER COLUMN id SET DEFAULT nextval('public.permissions_id_seq'::regclass);
  505. --
  506. -- Name: provider id; Type: DEFAULT; Schema: public; Owner: postgres
  507. --
  508. ALTER TABLE ONLY public.provider ALTER COLUMN id SET DEFAULT nextval('public.provider_id_seq'::regclass);
  509. --
  510. -- Name: relationship id; Type: DEFAULT; Schema: public; Owner: postgres
  511. --
  512. ALTER TABLE ONLY public.relationship ALTER COLUMN id SET DEFAULT nextval('public.relationship_id_seq'::regclass);
  513. --
  514. -- Name: resource id; Type: DEFAULT; Schema: public; Owner: postgres
  515. --
  516. ALTER TABLE ONLY public.resource ALTER COLUMN id SET DEFAULT nextval('public.resource_id_seq'::regclass);
  517. --
  518. -- Name: service id; Type: DEFAULT; Schema: public; Owner: postgres
  519. --
  520. ALTER TABLE ONLY public.service ALTER COLUMN id SET DEFAULT nextval('public.service_id_seq'::regclass);
  521. --
  522. -- Name: servicetype id; Type: DEFAULT; Schema: public; Owner: postgres
  523. --
  524. ALTER TABLE ONLY public.servicetype ALTER COLUMN id SET DEFAULT nextval('public.servicetype_id_seq'::regclass);
  525. --
  526. -- Name: tickets id; Type: DEFAULT; Schema: public; Owner: sharix
  527. --
  528. ALTER TABLE ONLY public.tickets ALTER COLUMN id SET DEFAULT nextval('public.tickets_id_seq'::regclass);
  529. --
  530. -- Name: client client_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
  531. --
  532. ALTER TABLE ONLY public.client
  533. ADD CONSTRAINT client_pkey PRIMARY KEY (id);
  534. --
  535. -- Name: company company_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
  536. --
  537. ALTER TABLE ONLY public.company
  538. ADD CONSTRAINT company_pkey PRIMARY KEY (id);
  539. --
  540. -- Name: current_orders current_orders_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
  541. --
  542. ALTER TABLE ONLY public.current_orders
  543. ADD CONSTRAINT current_orders_pkey PRIMARY KEY (id);
  544. --
  545. -- Name: current_timetable current_timetable_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
  546. --
  547. ALTER TABLE ONLY public.current_timetable
  548. ADD CONSTRAINT current_timetable_pkey PRIMARY KEY (id);
  549. --
  550. -- Name: documents documents_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
  551. --
  552. ALTER TABLE ONLY public.documents
  553. ADD CONSTRAINT documents_pkey PRIMARY KEY (id);
  554. --
  555. -- Name: order_list_log order_list_log_pkey; Type: CONSTRAINT; Schema: public; Owner: sharix
  556. --
  557. ALTER TABLE ONLY public.order_list_log
  558. ADD CONSTRAINT order_list_log_pkey PRIMARY KEY (id);
  559. --
  560. -- Name: orders orders_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
  561. --
  562. ALTER TABLE ONLY public.orders
  563. ADD CONSTRAINT orders_pkey PRIMARY KEY (id);
  564. --
  565. -- Name: permissions permissions_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
  566. --
  567. ALTER TABLE ONLY public.permissions
  568. ADD CONSTRAINT permissions_pkey PRIMARY KEY (id);
  569. --
  570. -- Name: provider provider_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
  571. --
  572. ALTER TABLE ONLY public.provider
  573. ADD CONSTRAINT provider_pkey PRIMARY KEY (id);
  574. --
  575. -- Name: relationship relationship_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
  576. --
  577. ALTER TABLE ONLY public.relationship
  578. ADD CONSTRAINT relationship_pkey PRIMARY KEY (id);
  579. --
  580. -- Name: resource resource_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
  581. --
  582. ALTER TABLE ONLY public.resource
  583. ADD CONSTRAINT resource_pkey PRIMARY KEY (id);
  584. --
  585. -- Name: service service_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
  586. --
  587. ALTER TABLE ONLY public.service
  588. ADD CONSTRAINT service_pkey PRIMARY KEY (id);
  589. --
  590. -- Name: servicetype servicetype_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres
  591. --
  592. ALTER TABLE ONLY public.servicetype
  593. ADD CONSTRAINT servicetype_pkey PRIMARY KEY (id);
  594. --
  595. -- Name: tickets tickets_pkey; Type: CONSTRAINT; Schema: public; Owner: sharix
  596. --
  597. ALTER TABLE ONLY public.tickets
  598. ADD CONSTRAINT tickets_pkey PRIMARY KEY (id);
  599. --
  600. -- PostgreSQL database dump complete
  601. --