{"id":917,"date":"2024-08-05T11:24:00","date_gmt":"2024-08-05T08:24:00","guid":{"rendered":"https:\/\/aristov.tech\/blog\/?p=917"},"modified":"2024-10-07T14:59:30","modified_gmt":"2024-10-07T11:59:30","slug":"tipy-dannyh-postgresql","status":"publish","type":"post","link":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/","title":{"rendered":"\u0422\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 PostgreSQL"},"content":{"rendered":"\n<p>\u0421\u0442\u0430\u0442\u044c\u044f \u043e\u0441\u043d\u043e\u0432\u0430\u043d\u0430 \u043d\u0430\u00a0<a href=\"https:\/\/youtu.be\/r6JhBFXoEOE\">13 \u0432\u0438\u0434\u0435\u043e<\/a>\u00a0\u0438\u0437 30 \u0442\u0435\u043c\u00a0<a href=\"https:\/\/aristov.tech\/blog\/kurs-sql-c-0\/\">\u043a\u0443\u0440\u0441\u0430 SQL c 0<\/a>\u00a0\u043e\u0442 \u0410\u0440\u0438\u0441\u0442\u043e\u0432\u0430 \u0415\u0432\u0433\u0435\u043d\u0438\u044f. \u0421\u0441\u044b\u043b\u043a\u0438 \u043d\u0430 \u0432\u0438\u0434\u0435\u043e \u043d\u0430 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0430\u0445 <a href=\"https:\/\/rutube.ru\/video\/7170c654d3a5f2ce72b2f784e770446a\/\">RUTUBE<\/a> \u0438 <a href=\"https:\/\/vk.com\/video-212716752_456239019\">VK \u0432\u0438\u0434\u0435\u043e<\/a>.<\/p>\n\n\n\n<p class=\"has-large-font-size\"><strong>\u0422\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445<\/strong><\/p>\n\n\n\n<p>\u0412 PostgreSQL \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u043c\u043d\u043e\u0433\u043e \u0442\u0438\u043f\u043e\u0432 \u0434\u0430\u043d\u043d\u044b\u0445.<\/p>\n\n\n\n<p>\u041f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0438\u0445 \u0438 \u0438\u0445 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u043c\u043e\u0436\u043d\u043e \u0432 <a href=\"https:\/\/www.postgresql.org\/docs\/current\/datatype.html\">\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438<\/a> \u0438\u043b\u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u043c\u0438:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>SELECT typname, typlen, typtype FROM pg_type;<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>SELECT count(typtype) FROM pg_type;<\/code><\/pre>\n\n\n\n<p>\u0417\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0442\u0438\u043f\u043e\u0432 \u0440\u0430\u0437\u0431\u0438\u0442\u044b \u043f\u043e \u0433\u0440\u0443\u043f\u043f\u0430\u043c <strong>typtype<\/strong>:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>b &#8212; \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u0442\u0438\u043f (base)<\/li>\n\n\n\n<li>c &#8212; \u0441\u043e\u0441\u0442\u0430\u0432\u043d\u043e\u0439 (composite)<\/li>\n\n\n\n<li>d &#8212; \u0434\u043b\u044f \u0434\u043e\u043c\u0435\u043d\u0430 (domain)<\/li>\n\n\n\n<li>e &#8212; \u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u044f\u0435\u043c\u044b\u0439 (enum)<\/li>\n\n\n\n<li>p &#8212; \u043f\u0441\u0435\u0432\u0434\u043e\u0442\u0438\u043f (pseudo-type)<\/li>\n\n\n\n<li>r &#8212; \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d (range)<\/li>\n<\/ul>\n\n\n\n<p>\u041f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432\u0441\u0435 \u0431\u0430\u0437\u043e\u0432\u044b\u0435 \u0442\u0438\u043f\u044b:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>SELECT typname, typlen, typtype FROM pg_type WHERE typtype='b';<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"335\" src=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/07\/image-28-1024x335.png\" alt=\"\" class=\"wp-image-973\" srcset=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/07\/image-28-1024x335.png 1024w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/07\/image-28-300x98.png 300w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/07\/image-28-768x252.png 768w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/07\/image-28.png 1166w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>\u0412\u0441\u0435\u0433\u043e 300+ \u0442\u0438\u043f\u043e\u0432. \u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435.<\/p>\n\n\n\n<p class=\"has-large-font-size\"><strong>\u0411\u0430\u0437\u043e\u0432\u044b\u0435 \u0442\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445<\/strong><\/p>\n\n\n\n<p>\u0412 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442\u0441\u044f \u0432\u0441\u0435\u0433\u043e 6 \u0442\u0438\u043f\u043e\u0432 \u0434\u0430\u043d\u043d\u044b\u0445:<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-27-1024x576.png\" alt=\"\" class=\"wp-image-918\" srcset=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-27-1024x576.png 1024w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-27-300x169.png 300w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-27-768x432.png 768w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-27-1536x864.png 1536w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-27.png 1600w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>\u041a\u043e\u043b\u043e\u043d\u043a\u0430 NOT NULL \u0432 \u0442\u0430\u0431\u043b\u0438\u0446\u0435 &#8212; \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b, \u0447\u0435\u043c \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 NULL, \u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043a\u043e\u043d\u0446\u0435\u043f\u0446\u0438\u044e \u0441 NULLABLE \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f\u043c\u0438, \u043e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 NULL != NULL \u0438 \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0445 \u0441 \u044d\u0442\u0438\u043c <a href=\"https:\/\/habr.com\/ru\/articles\/684600\/\">\u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430\u043c\u0438<\/a>.<\/p>\n\n\n\n<p>INT &#8212; \u043f\u0440\u043e\u0441\u0442\u0435\u0439\u0448\u0435\u0435 \u0447\u0438\u0441\u043b\u043e(4 \u0431\u0430\u0439\u0442\u0430), \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u043e\u0442 -2 \u043c\u043b\u0440\u0434 \u0434\u043e 2 \u043c\u043b\u0440\u0434. BIGINT &#8212; \u0431\u043e\u043b\u044c\u0448\u043e\u0435 \u0447\u0438\u0441\u043b\u043e (8 \u0431\u0430\u0439\u0442). SERIAL \u043e\u0441\u043d\u043e\u0432\u0430\u043d \u043d\u0430 INT (\u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d \u0442\u043e\u0442 \u0436\u0435, \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u0432 <a href=\"https:\/\/aristov.tech\/blog\/sequence-postgresql\/\">\u0441\u0442\u0430\u0442\u044c\u0435<\/a>). \u0412 PostgreSQL \u043d\u0435\u0442 \u0431\u0435\u0437\u0437\u043d\u0430\u043a\u043e\u0432\u043e\u0433\u043e \u0442\u0438\u043f\u0430, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0434\u043b\u044f \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0435\u0439  \u0434\u043b\u0438\u043d\u043e\u0439 \u0431\u043e\u043b\u044c\u0448\u0435 2 \u043c\u043b\u0440\u0434 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 BIGSERIAL.<\/p>\n\n\n\n<p>VARCHAR\/TEXT &#8212; \u0442\u0435\u043a\u0441\u0442 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 \u0434\u043b\u0438\u043d\u044b (\u0432 VARCHAR \u043c\u043e\u0436\u0435\u043c \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0442\u044c \u0434\u043b\u0438\u043d\u0443 \u043f\u043e\u043b\u044f), CHAR &#8212; \u0442\u0435\u043a\u0441\u0442 \u0444\u0438\u043a\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0439 \u0434\u043b\u0438\u043d\u044b. <\/p>\n\n\n\n<p>\u0420\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0430\u0446\u0438\u0438: \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u043b\u044f \u0442\u0438\u043f\u0430 TEXT, \u0442\u0430\u043a \u043a\u0430\u043a \u0432 \u043d\u0451\u043c \u043d\u0435\u0442 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u043d\u0430 \u0434\u043b\u0438\u043d\u0443, \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0443 \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0442\u044c \u043d\u0430 \u0431\u044d\u043a\u0435\u043d\u0434\u0435; \u0437\u0430\u0434\u0430\u0432\u0430\u0442\u044c \u0434\u043b\u044f \u043f\u043e\u043b\u044f NOT NULL (\u043f\u0443\u0441\u0442\u044b\u0435 \u044f\u0447\u0435\u0439\u043a\u0438 \u0437\u0430\u043f\u043e\u043b\u043d\u044f\u0442\u044c &#187;).<\/p>\n\n\n\n<p>NUMERIC\/DECIMAL &#8212; \u0432\u0435\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u0447\u0438\u0441\u043b\u043e, \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u0434\u0430\u0442\u044c \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0441\u0438\u043c\u0432\u043e\u043b\u043e\u0432 \u0434\u043e \u0437\u0430\u043f\u044f\u0442\u043e\u0439 \u0438 \u043f\u043e\u0441\u043b\u0435 \u043d\u0435\u0451. REAL &#8212; \u0447\u0438\u0441\u043b\u0430 \u0441 \u043f\u043b\u0430\u0432\u0430\u044e\u0449\u0435\u0439 \u0442\u043e\u0447\u043a\u043e\u0439.<\/p>\n\n\n\n<p>BOOLEAN &#8212; \u043b\u043e\u0433\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0442\u0438\u043f, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0437\u0430\u043d\u0438\u043c\u0430\u0435\u0442 1 \u0431\u0430\u0439\u0442.<\/p>\n\n\n\n<p>DATE &#8212; \u0434\u0430\u0442\u0430, \u043c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0441 \u0443\u0447\u0451\u0442\u043e\u043c \u0447\u0430\u0441\u043e\u0432\u043e\u0433\u043e \u043f\u043e\u044f\u0441\u0430 (\u0437\u0430\u043d\u0438\u043c\u0430\u0435\u0442 \u0441\u0442\u043e\u043b\u044c\u043a\u043e \u0436\u0435 \u043c\u0435\u0441\u0442\u0430). \u0420\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0435\u0434\u0438\u043d\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434 \u0432\u043e \u0432\u0441\u0451\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u0435.<\/p>\n\n\n\n<p>TIMESTAMP &#8212; \u0434\u0430\u0442\u0430 + \u0432\u0440\u0435\u043c\u044f<\/p>\n\n\n\n<p>\u041d\u0430\u043f\u043e\u043c\u0438\u043d\u0430\u044e, \u0447\u0442\u043e \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043a\u043e\u0434\u0438\u0440\u043e\u0432\u043a\u0443 UTF-8.<\/p>\n\n\n\n<p class=\"has-large-font-size\"><strong>\u0424\u0438\u043d\u0430\u043d\u0441\u043e\u0432\u0430\u044f \u0430\u0440\u0438\u0444\u043c\u0435\u0442\u0438\u043a\u0430<\/strong><\/p>\n\n\n\n<p>\u0412 PostgreSQL \u0434\u043b\u044f \u0434\u0435\u043d\u0435\u0436\u043d\u044b\u0445 \u0435\u0434\u0438\u043d\u0438\u0446 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u044e\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c <a href=\"https:\/\/www.postgresql.org\/docs\/current\/datatype-money.html\">MONEY<\/a>, \u043d\u043e \u0432 \u0434\u0430\u043d\u043d\u043e\u043c \u0442\u0438\u043f\u0435 \u0434\u0430\u043d\u043d\u044b\u0445 \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u0441 \u043f\u043e\u0434\u0441\u0447\u0435\u0442\u043e\u043c \u0443 \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432 \u0438\u0437 \u0410\u043c\u0435\u0440\u0438\u043a\u0438. <\/p>\n\n\n\n<p>\u041e\u0442\u043b\u0438\u0447\u0438\u0435 \u0430\u043c\u0435\u0440\u0438\u043a\u0430\u043d\u0441\u043a\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u043e\u0442 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u043c\u0438\u0440\u0430:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u0421\u0447\u0438\u0442\u0430\u044e\u0442 \u0434\u043e 0.001 \u0434\u043e\u043b\u043b\u0430\u0440\u0430, \u0430 \u0432 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u043e\u043c \u043c\u0438\u0440\u0435 \u0434\u043e 0.01<\/li>\n\n\n\n<li>\u041e\u043a\u0440\u0443\u0433\u043b\u044f\u044e\u0442 \u043a \u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0435\u043c\u0443 \u0447\u0435\u0442\u043d\u043e\u043c\u0443(3.5-&gt;4&nbsp;VS <strong>3.5-&gt;3<\/strong> ; 4.5-&gt;4&nbsp; VS <strong>4.5-&gt;4<\/strong>), \u0430 \u0432 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u043e\u043c \u043c\u0438\u0440\u0435 \u043a \u0431\u043b\u0438\u0436\u0430\u0439\u0448\u0435\u043c\u0443 \u0446\u0435\u043b\u043e\u043c\u0443.<\/li>\n<\/ul>\n\n\n\n<p>\u041f\u043e\u0434\u0441\u0447\u0451\u0442 \u0437\u0430\u0432\u0438\u0441\u0438\u0442 \u043e\u0442 \u0442\u043e\u0433\u043e, \u043a\u0430\u043a\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u043b\u043e\u043a\u0430\u043b\u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u044b \u043d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0435.<\/p>\n\n\n\n<p>\u0422\u0435\u043a\u0443\u0449\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u043b\u043e\u043a\u0430\u043b\u0438:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>SHOW <a href=\"https:\/\/www.postgresql.org\/docs\/current\/datatype-money.html\">lc_monetary<\/a> <\/code><\/pre>\n\n\n\n<p>\u0412\u043c\u0435\u0441\u0442\u043e MONEY \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c NUMERIC.<\/p>\n\n\n\n<p><a href=\"https:\/\/habr.com\/ru\/company\/tensor\/blog\/508038\/\">\u041f\u043e\u0434\u043e\u0437\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0442\u0438\u043f\u044b<\/a><\/p>\n\n\n\n<p class=\"has-large-font-size\"><strong>\u041f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0442\u0438\u043f\u043e\u0432<\/strong><\/p>\n\n\n\n<p><a href=\"https:\/\/www.postgresql.org\/docs\/current\/typeconv.html\">PostgreSQL: Documentation: 16: Chapter 10. Type Conversion<\/a><\/p>\n\n\n\n<p>\u0412 PostgreSQL \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0439 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 ::<strong> (\u0434\u0432\u043e\u0439\u043d\u043e\u0435 \u0434\u0432\u043e\u0435\u0442\u043e\u0447\u0438\u0435) <\/strong><\/p>\n\n\n\n<p>\u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0442\u0435\u043a\u0441\u0442 &#8217;10&#8217; \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u043f\u044b\u0442\u0430\u0442\u044c\u0441\u044f \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u0442\u044c \u043a \u0432\u0435\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u043c\u0443 \u0442\u0438\u043f\u0443 &#8212; <strong>&#8217;10&#8217; :: real<\/strong><\/p>\n\n\n\n<p>\u0422\u0430\u043a\u0436\u0435 \u0435\u0441\u0442\u044c \u043d\u0430\u0431\u043e\u0440 \u0444\u0443\u043d\u043a\u0446\u0438\u0439 \u0434\u043b\u044f \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u044f:<\/p>\n\n\n\n<p><a href=\"https:\/\/www.postgresql.org\/docs\/current\/functions-formatting.html\">PostgreSQL: Documentation: 16: 9.8. Data Type Formatting Functions<\/a><\/p>\n\n\n\n<p>\u0422\u0430\u043a\u0436\u0435 \u043c\u043e\u0436\u043d\u043e <a href=\"https:\/\/www.postgresql.org\/docs\/current\/sql-createcast.html\">\u0441\u043a\u0430\u0441\u0442\u043e\u0432\u0430\u0442\u044c <\/a>\u0442\u0438\u043f (\u043d\u043e \u0442\u0430\u043a\u043e\u0439 \u043a\u0430\u0441\u0442 \u0434\u043e\u043b\u0436\u0435\u043d \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043e\u0432\u0430\u0442\u044c):<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>SELECT CAST ('expression' AS INTEGER);<\/code><\/pre>\n\n\n\n<p class=\"has-large-font-size\"><strong>UUID<\/strong><\/p>\n\n\n\n<p>UUID \u0437\u0430\u043d\u0438\u043c\u0430\u0435\u0442 32 \u0431\u0430\u0439\u0442\u0430, \u043e\u0431\u044b\u0447\u043d\u043e \u043f\u0440\u0435\u0434\u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d \u0434\u043b\u044f \u0443\u043d\u0438\u043a\u0430\u043b\u044c\u043d\u044b\u0445 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439, \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0442\u044c\u0441\u044f \u043d\u0435 \u043c\u043e\u0436\u0435\u0442.<\/p>\n\n\n\n<p>\u041c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0438\u0442\u044c \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u0441 \u0440\u0430\u0437\u043d\u044b\u0445 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432, \u0447\u0442\u043e\u0431\u044b \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0440\u0430\u0432\u043d\u043e\u043c\u0435\u0440\u043d\u043e\u0435 \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435.<\/p>\n\n\n\n<p>\u041d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043e\u043a &#8212; \u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u0432\u0435\u0441 (\u0442\u0430\u043a\u0436\u0435 \u0437\u0430\u0444\u0444\u0435\u043a\u0442\u0438\u0442 \u043d\u0430 \u0438\u043d\u0434\u0435\u043a\u0441 \u0438 \u0432\u043d\u0435\u0448\u043d\u0438\u0435 \u043a\u043b\u044e\u0447\u0438), \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0434\u043e\u043b\u0433\u0430\u044f \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u044f.<\/p>\n\n\n\n<p><a href=\"https:\/\/aristov.tech\/blog\/chto-bystree-countid-ili-countuuid\/\">\u0421\u0442\u0430\u0442\u044c\u044f \u043f\u0440\u043e \u0441\u043a\u043e\u0440\u043e\u0441\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u044b UUID.<\/a><\/p>\n\n\n\n<p class=\"has-x-large-font-size\"><strong>\u041f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435<\/strong><\/p>\n\n\n\n<p class=\"has-large-font-size\">\u0424\u0438\u043d\u0430\u043d\u0441\u044b<\/p>\n\n\n\n<p>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u043f\u0440\u043e\u0446\u0435\u0434\u0443\u0440\u0443, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 10000 \u0440\u0430\u0437 \u043f\u0440\u0438\u0431\u0430\u0432\u0438\u043c \u043a DECIMAL \u0438 FLOAT 0.001. \u041f\u0440\u0435\u0434\u043f\u043e\u043b\u0430\u0433\u0430\u0435\u043c, \u0447\u0442\u043e \u0432 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0434\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u043e\u0435 \u0447\u0438\u0441\u043b\u043e.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>CREATE or REPLACE PROCEDURE finance(inout x text)\nas $$\n    DECLARE\n        i INTEGER DEFAULT 0;\n        numeric_ DECIMAL(10,4) DEFAULT 0;\n        float_ FLOAT DEFAULT 0;\n    BEGIN\n        LOOP\n            numeric_ := numeric_ + 0.001;\n            float_ := float_ + 0.001E0;\n            i := i + 1;\n            if i &gt; 10000\n                then exit;\n            end if;\n        END LOOP;\n        x = numeric_ || ' ' || float_;\n    end;\n$$\nlanguage plpgsql\n;<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>call finance('');<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"355\" height=\"71\" src=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-28.png\" alt=\"\" class=\"wp-image-919\" srcset=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-28.png 355w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-28-300x60.png 300w\" sizes=\"auto, (max-width: 355px) 100vw, 355px\" \/><\/figure>\n\n\n\n<p>\u041f\u043e\u043b\u0443\u0447\u0438\u043b\u0438\u0441\u044c \u0434\u0432\u0430 \u0440\u0430\u0437\u043d\u044b\u0445 \u0447\u0438\u0441\u043b\u0430, \u0447\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u0441\u044b\u0433\u0440\u0430\u0442\u044c \u0431\u043e\u043b\u044c\u0448\u0443\u044e \u0440\u043e\u043b\u044c \u0432 \u0444\u0438\u043d\u0430\u043d\u0441\u043e\u0432\u044b\u0445 \u043e\u0442\u0447\u0451\u0442\u0430\u0445. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043b\u0443\u0447\u0448\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c NUMERIC.<\/p>\n\n\n\n<p class=\"has-large-font-size\">\u041a\u043e\u0434\u0438\u0440\u043e\u0432\u043a\u0430<\/p>\n\n\n\n<p>\u041f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0440\u0430\u0437\u043d\u0438\u0446\u0443 \u0432 \u043a\u043e\u0434\u0438\u0440\u043e\u0432\u043a\u0435 UTF \u0440\u0443\u0441\u0441\u043a\u043e\u0433\u043e \u0438 \u0430\u043d\u0433\u043b\u0438\u0439\u0441\u043a\u043e\u0433\u043e \u0442\u0435\u043a\u0441\u0442\u0430:<\/p>\n\n\n\n<p>SELECT bit_length(&#8216;test&#8217;);<br>SELECT bit_length(&#8216;\u0442\u0435\u0441\u0442&#8217;);<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"198\" height=\"77\" src=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-29.png\" alt=\"\" class=\"wp-image-920\"\/><\/figure>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"229\" height=\"72\" src=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-30.png\" alt=\"\" class=\"wp-image-921\"\/><\/figure>\n\n\n\n<p>\u0410\u043d\u0433\u043b\u0438\u0439\u0441\u043a\u0438\u0439 \u0442\u0435\u043a\u0441\u0442 \u0437\u0430\u043d\u0438\u043c\u0430\u0435\u0442 1 \u0431\u0430\u0439\u0442 \u043d\u0430 \u0441\u0438\u043c\u0432\u043e\u043b, \u0430 \u0440\u0443\u0441\u0441\u043a\u0438\u0439 &#8212; \u0432 \u0434\u0432\u0430 \u0440\u0430\u0437\u0430 \u0431\u043e\u043b\u044c\u0448\u0435. \u0415\u0441\u043b\u0438 \u0442\u0435\u043a\u0441\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0431\u043e\u043b\u0435\u0435 ~20 \u0431\u0430\u0439\u0442, \u0442\u043e \u043a \u043d\u0435\u043c\u0443 \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u044e\u0442\u0441\u044f \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u044b \u0441\u0436\u0430\u0442\u0438\u044f (\u0431\u043e\u043b\u0435\u0435 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u043d\u0430 <a href=\"https:\/\/aristov.tech\/blog\/kurs-po-optimizaczii-postgresql\/\">\u043a\u0443\u0440\u0441\u0435 \u043f\u043e \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438<\/a>), \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043f\u043e\u0442\u0435\u0440\u0438 \u0438\u0437-\u0437\u0430 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u044d\u0442\u043e\u0439 \u043a\u043e\u0434\u0438\u0440\u043e\u0432\u043a\u0438 \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u0438\u0435.<\/p>\n\n\n\n<p class=\"has-large-font-size\">\u041e\u043f\u0438\u0441\u0430\u043d\u0438\u0435<\/p>\n\n\n\n<p>\u041e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u0442\u0438\u043f\u043e\u0432 \u0434\u0430\u043d\u043d\u044b\u0445:<\/p>\n\n\n\n<p>\u0418\u043c\u044f- \u0442\u0438\u043f_\u0434\u0430\u043d\u043d\u044b\u0445 &#8212; \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u0435 &#8212; \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435_\u043f\u043e_\u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e<\/p>\n\n\n\n<p>name text NOT NULL DEFAULT &#187;<\/p>\n\n\n\n<p>\u0420\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u0432\u0441\u0435\u0433\u0434\u0430 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c DEFAULT \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u043f\u0438\u0441\u0430\u043d\u043e, \u0435\u0441\u043b\u0438 \u043a\u0430\u043a\u043e\u0435-\u0442\u043e \u043f\u043e\u043b\u0435 \u043d\u0435 \u0443\u043a\u0430\u0437\u0430\u043d\u043e. \u0422\u0430\u043a\u0436\u0435 \u0435\u0441\u043b\u0438 \u0437\u0430\u0431\u044b\u0442\u044c \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u043a\u0430\u043a\u043e\u0435-\u0442\u043e \u043f\u043e\u043b\u0435, \u0430 \u043d\u0430 \u043d\u0435\u0433\u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043e NOT NULL, \u0442\u043e \u0432\u043e\u0437\u043d\u0438\u043a\u043d\u0435\u0442 \u043e\u0448\u0438\u0431\u043a\u0430 (DEFAULT \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u0438\u0437\u0431\u0435\u0436\u0430\u0442\u044c \u044d\u0442\u043e\u0433\u043e).<\/p>\n\n\n\n<p class=\"has-large-font-size\">\u0427\u0430\u0441\u043e\u0432\u044b\u0435 \u043f\u043e\u044f\u0441\u0430<\/p>\n\n\n\n<p>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0442\u0430\u0431\u043b\u0438\u0446\u0443 \u0421\u043a\u043b\u0430\u0434, \u0432 \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u043f\u043e\u043b\u044f salesTime (\u0441 \u0437\u043e\u043d\u043e\u0439) \u0438 salesTime2 (\u0431\u0435\u0437 \u0437\u043e\u043d\u044b).<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>DROP TABLE IF EXISTS warehouse;<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>CREATE TABLE warehouse (id serial UNIQUE,\nname text NOT NULL DEFAULT '',\nkolvo int NOT NULL DEFAULT 0,\nprice numeric NOT NULL DEFAULT 0.0,\nsalesTime timestamp with time zone NOT NULL DEFAULT current_timestamp, -- UTC\nsalesTime2 timestamp NOT NULL DEFAULT current_timestamp\n);\n\nINSERT INTO warehouse(name) VALUES ('apple');\nINSERT INTO warehouse(name, price) VALUES ('banana',2.1);\nSELECT * FROM warehouse;<\/code><\/pre>\n\n\n\n<p>\u0412 \u043f\u043e\u043b\u0435 \u0441 \u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 \u0437\u043e\u043d\u043e\u0439 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0445\u0440\u0430\u043d\u0438\u0442\u0441\u044f \u0447\u0430\u0441\u043e\u0432\u043e\u0439 \u043f\u043e\u044f\u0441:<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"120\" src=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-31-1024x120.png\" alt=\"\" class=\"wp-image-922\" srcset=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-31-1024x120.png 1024w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-31-300x35.png 300w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-31-768x90.png 768w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-31.png 1047w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>PostgreSQL \u043c\u043e\u0436\u0435\u0442 \u0441\u0440\u0430\u0432\u043d\u0438\u0442\u044c \u043f\u043e\u043b\u0435 \u0441 \u0447\u0430\u0441\u043e\u0432\u044b\u043c \u043f\u043e\u044f\u0441\u043e\u043c \u0438 \u0431\u0435\u0437 (\u0432\u0438\u0434\u0438\u0442, \u0447\u0442\u043e \u044d\u0442\u043e \u043e\u0434\u0438\u043d \u043c\u043e\u043c\u0435\u043d\u0442 \u0432\u0440\u0435\u043c\u0435\u043d\u0438):<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>SELECT * FROM warehouse WHERE <em>salesTime<\/em>=<em>salesTime2<\/em>;<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"134\" src=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-32-1024x134.png\" alt=\"\" class=\"wp-image-923\" srcset=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-32-1024x134.png 1024w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-32-300x39.png 300w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-32-768x100.png 768w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-32.png 1027w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p class=\"has-large-font-size\">\u041f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0442\u0438\u043f\u043e\u0432<\/p>\n\n\n\n<p>\u041f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u0443\u0435\u043c \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 &#8217;10 &#8216; \u043a real, numeric (\u0441 \u0440\u0430\u0437\u043d\u044b\u043c \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e\u043c \u0441\u0438\u043c\u0432\u043e\u043b\u043e\u0432), text<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>SELECT '10 '::real::numeric, '10'::numeric, '10'::numeric (10,2), '10'::text;<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"515\" height=\"78\" src=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-33.png\" alt=\"\" class=\"wp-image-924\" srcset=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-33.png 515w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-33-300x45.png 300w\" sizes=\"auto, (max-width: 515px) 100vw, 515px\" \/><\/figure>\n\n\n\n<pre class=\"wp-block-code\"><code>SELECT CAST('10' AS INTEGER);<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"161\" height=\"84\" src=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-34.png\" alt=\"\" class=\"wp-image-925\"\/><\/figure>\n\n\n\n<p>\u041f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u0443\u0435\u043c \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u0443\u044e \u0441\u0442\u0440\u043e\u043a\u0443 \u043a \u0434\u0430\u0442\u0435, \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c, \u0432 \u043a\u0430\u043a\u043e\u043c \u043f\u043e\u0440\u044f\u0434\u043a\u0435 \u0437\u0430\u043f\u0438\u0441\u0430\u043d\u044b \u0447\u0430\u0441\u0442\u0438 \u0434\u0430\u0442\u044b:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>SELECT to_date('05 May 2024', 'DD Mon YYYY');<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"240\" height=\"83\" src=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-35.png\" alt=\"\" class=\"wp-image-926\"\/><\/figure>\n\n\n\n<p>\u041a\u0430\u043a \u0443\u0436\u0435 \u0443\u043f\u043e\u043c\u0438\u043d\u0430\u043b\u043e\u0441\u044c \u0432 <a href=\"https:\/\/aristov.tech\/blog\/alter-drop-postgresql\/\">\u043f\u0440\u043e\u0448\u043b\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435<\/a>, \u043f\u0440\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f \u0442\u0438\u043f\u0430 \u043f\u043e\u043b\u044f \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043f\u043e\u043b\u0435 \u043d\u043e\u0432\u043e\u0433\u043e \u0442\u0438\u043f\u0430, \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u0442\u044c \u0442\u0443\u0434\u0430 \u0441\u0442\u0430\u0440\u043e\u0435 \u043f\u043e\u043b\u0435, \u0437\u0430\u0442\u0435\u043c \u0443\u0434\u0430\u043b\u0438\u0442\u044c \u0441\u0442\u0430\u0440\u043e\u0435 \u0438 \u043f\u0435\u0440\u0435\u0438\u043c\u0435\u043d\u043e\u0432\u0430\u0442\u044c \u043d\u043e\u0432\u043e\u0435.<\/p>\n\n\n\n<p class=\"has-large-font-size\">UUID<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>CREATE EXTENSION IF NOT EXISTS \"uuid-ossp\";\nCREATE TABLE accounts (\n&nbsp;   id UUID PRIMARY KEY DEFAULT uuid_generate_v1(),\n&nbsp; &nbsp; balance DECIMAL\n&nbsp; );<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>INSERT INTO accounts(balance) VALUES ('10');\nSELECT * FROM accounts;<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"640\" height=\"99\" src=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-36.png\" alt=\"\" class=\"wp-image-927\" srcset=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-36.png 640w, https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-36-300x46.png 300w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/figure>\n\n\n\n<p>\u041f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0440\u0430\u0437\u043c\u0435\u0440 UUID:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>SELECT bit_length(<em>id<\/em>::text) FROM <em>accounts<\/em>;<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"195\" height=\"67\" src=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/06\/image-37.png\" alt=\"\" class=\"wp-image-928\"\/><\/figure>\n\n\n\n<p>\u041f\u0440\u0435\u0437\u0435\u043d\u0442\u0430\u0446\u0438\u044f \u043a \u0441\u0442\u0430\u0442\u044c\u0435 <a href=\"https:\/\/github.com\/aeuge\/aristov_tech\/blob\/main\/00%20SQL%20s%200\/presentation\/00%2013%20SQL%20c%200.pdf\">\u0437\u0434\u0435\u0441\u044c<\/a>.<\/p>\n\n\n\n<p>14 \u0438\u0437 30 \u0442\u0435\u043c \u0431\u0443\u0434\u0435\u0442 \u0441\u043a\u043e\u0440\u043e \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u0430. \u0415\u0441\u043b\u0438 \u0432\u044b \u0445\u043e\u0442\u0438\u0442\u0435 \u0431\u044b\u0441\u0442\u0440\u0435\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u2013 \u043f\u0440\u0438\u0441\u043e\u0435\u0434\u0438\u043d\u044f\u0439\u0442\u0435\u0441\u044c \u043a \u043e\u043d\u043b\u0430\u0439\u043d \u0433\u0440\u0443\u043f\u043f\u0435, \u0441\u0441\u044b\u043b\u043a\u0430 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u0430 \u0432&nbsp;<a href=\"https:\/\/aristov.tech\/blog\/kurs-sql-c-0\/\">\u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0438 \u043a\u0443\u0440\u0441\u0430<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u0421\u0442\u0430\u0442\u044c\u044f \u043e\u0441\u043d\u043e\u0432\u0430\u043d\u0430 \u043d\u0430\u00a013 \u0432\u0438\u0434\u0435\u043e\u00a0\u0438\u0437 30 \u0442\u0435\u043c\u00a0\u043a\u0443\u0440\u0441\u0430 SQL c 0\u00a0\u043e\u0442 \u0410\u0440\u0438\u0441\u0442\u043e\u0432\u0430 \u0415\u0432\u0433\u0435\u043d\u0438\u044f. \u0421\u0441\u044b\u043b\u043a\u0438 \u043d\u0430 \u0432\u0438\u0434\u0435\u043e \u043d\u0430 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0430\u0445 RUTUBE \u0438 VK \u0432\u0438\u0434\u0435\u043e. \u0422\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 \u0412 PostgreSQL \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u043c\u043d\u043e\u0433\u043e \u0442\u0438\u043f\u043e\u0432 \u0434\u0430\u043d\u043d\u044b\u0445. \u041f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0438\u0445 \u0438 \u0438\u0445 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u043c\u043e\u0436\u043d\u043e \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 \u0438\u043b\u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u043c\u0438: \u0417\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0442\u0438\u043f\u043e\u0432 \u0440\u0430\u0437\u0431\u0438\u0442\u044b \u043f\u043e \u0433\u0440\u0443\u043f\u043f\u0430\u043c typtype: \u041f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432\u0441\u0435 \u0431\u0430\u0437\u043e\u0432\u044b\u0435 \u0442\u0438\u043f\u044b: \u0412\u0441\u0435\u0433\u043e 300+ \u0442\u0438\u043f\u043e\u0432. \u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435. \u0411\u0430\u0437\u043e\u0432\u044b\u0435 [&hellip;]<\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[204,194],"tags":[259,261,258,16,195,30,260,72,256],"class_list":["post-917","post","type-post","status-publish","format-standard","hentry","category-kurs-sql-s-0","category-obuchenie-postgresql","tag-bit_length","tag-cast","tag-float","tag-postgresql","tag-sequence","tag-uuid","tag-with-time-zone","tag-kurs","tag-tip-dannyh"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>\u0422\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 PostgreSQL - \u0411\u043b\u043e\u0433 \u043f\u043e \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0435 \u0438 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438 PostgreSQL \u043e\u0442 \u0410\u0440\u0438\u0441\u0442\u043e\u0432\u0430 \u0415\u0432\u0433\u0435\u043d\u0438\u044f<\/title>\n<meta name=\"description\" content=\"\u0412 \u0434\u0430\u043d\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043e \u0431\u0430\u0437\u043e\u0432\u044b\u0445 \u0442\u0438\u043f\u0430\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 PostgreSQL, \u0438\u0445 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0434\u0440\u0443\u0433 \u043a \u0434\u0440\u0443\u0433\u0443, \u0442\u0430\u043a\u0436\u0435 \u043e \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043a\u0430\u0445 money \u0438 real.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/\" \/>\n<meta property=\"og:locale\" content=\"ru_RU\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u0422\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 PostgreSQL - \u0411\u043b\u043e\u0433 \u043f\u043e \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0435 \u0438 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438 PostgreSQL \u043e\u0442 \u0410\u0440\u0438\u0441\u0442\u043e\u0432\u0430 \u0415\u0432\u0433\u0435\u043d\u0438\u044f\" \/>\n<meta property=\"og:description\" content=\"\u0412 \u0434\u0430\u043d\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043e \u0431\u0430\u0437\u043e\u0432\u044b\u0445 \u0442\u0438\u043f\u0430\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 PostgreSQL, \u0438\u0445 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0434\u0440\u0443\u0433 \u043a \u0434\u0440\u0443\u0433\u0443, \u0442\u0430\u043a\u0436\u0435 \u043e \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043a\u0430\u0445 money \u0438 real.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/\" \/>\n<meta property=\"og:site_name\" content=\"\u0411\u043b\u043e\u0433 \u043f\u043e \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0435 \u0438 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438 PostgreSQL \u043e\u0442 \u0410\u0440\u0438\u0441\u0442\u043e\u0432\u0430 \u0415\u0432\u0433\u0435\u043d\u0438\u044f\" \/>\n<meta property=\"article:published_time\" content=\"2024-08-05T08:24:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-10-07T11:59:30+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/07\/image-28-1024x335.png\" \/>\n<meta name=\"author\" content=\"Maria\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u041d\u0430\u043f\u0438\u0441\u0430\u043d\u043e \u0430\u0432\u0442\u043e\u0440\u043e\u043c\" \/>\n\t<meta name=\"twitter:data1\" content=\"Maria\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u041f\u0440\u0438\u043c\u0435\u0440\u043d\u043e\u0435 \u0432\u0440\u0435\u043c\u044f \u0434\u043b\u044f \u0447\u0442\u0435\u043d\u0438\u044f\" \/>\n\t<meta name=\"twitter:data2\" content=\"7 \u043c\u0438\u043d\u0443\u0442\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/tipy-dannyh-postgresql\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/tipy-dannyh-postgresql\\\/\"},\"author\":{\"name\":\"Maria\",\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/#\\\/schema\\\/person\\\/6a152749a3dde76f19cc30db676d2310\"},\"headline\":\"\u0422\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 PostgreSQL\",\"datePublished\":\"2024-08-05T08:24:00+00:00\",\"dateModified\":\"2024-10-07T11:59:30+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/tipy-dannyh-postgresql\\\/\"},\"wordCount\":705,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/#\\\/schema\\\/person\\\/05f3a04bf720ae4bf25ac99c4248d5e7\"},\"image\":{\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/tipy-dannyh-postgresql\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/07\\\/image-28-1024x335.png\",\"keywords\":[\"bit_length\",\"CAST\",\"float\",\"postgresql\",\"sequence\",\"uuid\",\"with time zone\",\"\u043a\u0443\u0440\u0441\",\"\u0442\u0438\u043f \u0434\u0430\u043d\u043d\u044b\u0445\"],\"articleSection\":[\"\u041a\u0443\u0440\u0441 SQL \u0441 0\",\"\u041e\u0431\u0443\u0447\u0435\u043d\u0438\u0435 PostgreSQL\"],\"inLanguage\":\"ru-RU\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/aristov.tech\\\/blog\\\/tipy-dannyh-postgresql\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/tipy-dannyh-postgresql\\\/\",\"url\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/tipy-dannyh-postgresql\\\/\",\"name\":\"\u0422\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 PostgreSQL - \u0411\u043b\u043e\u0433 \u043f\u043e \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0435 \u0438 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438 PostgreSQL \u043e\u0442 \u0410\u0440\u0438\u0441\u0442\u043e\u0432\u0430 \u0415\u0432\u0433\u0435\u043d\u0438\u044f\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/tipy-dannyh-postgresql\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/tipy-dannyh-postgresql\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/07\\\/image-28-1024x335.png\",\"datePublished\":\"2024-08-05T08:24:00+00:00\",\"dateModified\":\"2024-10-07T11:59:30+00:00\",\"description\":\"\u0412 \u0434\u0430\u043d\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043e \u0431\u0430\u0437\u043e\u0432\u044b\u0445 \u0442\u0438\u043f\u0430\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 PostgreSQL, \u0438\u0445 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0434\u0440\u0443\u0433 \u043a \u0434\u0440\u0443\u0433\u0443, \u0442\u0430\u043a\u0436\u0435 \u043e \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043a\u0430\u0445 money \u0438 real.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/tipy-dannyh-postgresql\\\/#breadcrumb\"},\"inLanguage\":\"ru-RU\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/aristov.tech\\\/blog\\\/tipy-dannyh-postgresql\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"ru-RU\",\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/tipy-dannyh-postgresql\\\/#primaryimage\",\"url\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/07\\\/image-28.png\",\"contentUrl\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/07\\\/image-28.png\",\"width\":1166,\"height\":382},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/tipy-dannyh-postgresql\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u0413\u043b\u0430\u0432\u043d\u0430\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430\",\"item\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u0422\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 PostgreSQL\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/\",\"name\":\"\u0411\u043b\u043e\u0433 \u043f\u043e \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0435 \u0438 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438 PostgreSQL \u043e\u0442 \u0410\u0440\u0438\u0441\u0442\u043e\u0432\u0430 \u0415\u0432\u0433\u0435\u043d\u0438\u044f\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/#\\\/schema\\\/person\\\/05f3a04bf720ae4bf25ac99c4248d5e7\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"ru-RU\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/#\\\/schema\\\/person\\\/05f3a04bf720ae4bf25ac99c4248d5e7\",\"name\":\"admin2\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ru-RU\",\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/05\\\/blog-logo.png\",\"url\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/05\\\/blog-logo.png\",\"contentUrl\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/05\\\/blog-logo.png\",\"width\":180,\"height\":180,\"caption\":\"admin2\"},\"logo\":{\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/05\\\/blog-logo.png\"},\"sameAs\":[\"https:\\\/\\\/aristov.tech\\\/blog\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/#\\\/schema\\\/person\\\/6a152749a3dde76f19cc30db676d2310\",\"name\":\"Maria\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ru-RU\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/a86c8edd49a73db805cc02e271f5fc126b109c146ad0d8976829c538b3b94ca4?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/a86c8edd49a73db805cc02e271f5fc126b109c146ad0d8976829c538b3b94ca4?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/a86c8edd49a73db805cc02e271f5fc126b109c146ad0d8976829c538b3b94ca4?s=96&d=mm&r=g\",\"caption\":\"Maria\"},\"url\":\"https:\\\/\\\/aristov.tech\\\/blog\\\/author\\\/maria\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u0422\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 PostgreSQL - \u0411\u043b\u043e\u0433 \u043f\u043e \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0435 \u0438 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438 PostgreSQL \u043e\u0442 \u0410\u0440\u0438\u0441\u0442\u043e\u0432\u0430 \u0415\u0432\u0433\u0435\u043d\u0438\u044f","description":"\u0412 \u0434\u0430\u043d\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043e \u0431\u0430\u0437\u043e\u0432\u044b\u0445 \u0442\u0438\u043f\u0430\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 PostgreSQL, \u0438\u0445 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0434\u0440\u0443\u0433 \u043a \u0434\u0440\u0443\u0433\u0443, \u0442\u0430\u043a\u0436\u0435 \u043e \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043a\u0430\u0445 money \u0438 real.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/","og_locale":"ru_RU","og_type":"article","og_title":"\u0422\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 PostgreSQL - \u0411\u043b\u043e\u0433 \u043f\u043e \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0435 \u0438 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438 PostgreSQL \u043e\u0442 \u0410\u0440\u0438\u0441\u0442\u043e\u0432\u0430 \u0415\u0432\u0433\u0435\u043d\u0438\u044f","og_description":"\u0412 \u0434\u0430\u043d\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043e \u0431\u0430\u0437\u043e\u0432\u044b\u0445 \u0442\u0438\u043f\u0430\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 PostgreSQL, \u0438\u0445 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0434\u0440\u0443\u0433 \u043a \u0434\u0440\u0443\u0433\u0443, \u0442\u0430\u043a\u0436\u0435 \u043e \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043a\u0430\u0445 money \u0438 real.","og_url":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/","og_site_name":"\u0411\u043b\u043e\u0433 \u043f\u043e \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0435 \u0438 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438 PostgreSQL \u043e\u0442 \u0410\u0440\u0438\u0441\u0442\u043e\u0432\u0430 \u0415\u0432\u0433\u0435\u043d\u0438\u044f","article_published_time":"2024-08-05T08:24:00+00:00","article_modified_time":"2024-10-07T11:59:30+00:00","og_image":[{"url":"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/07\/image-28-1024x335.png","type":"","width":"","height":""}],"author":"Maria","twitter_card":"summary_large_image","twitter_misc":{"\u041d\u0430\u043f\u0438\u0441\u0430\u043d\u043e \u0430\u0432\u0442\u043e\u0440\u043e\u043c":"Maria","\u041f\u0440\u0438\u043c\u0435\u0440\u043d\u043e\u0435 \u0432\u0440\u0435\u043c\u044f \u0434\u043b\u044f \u0447\u0442\u0435\u043d\u0438\u044f":"7 \u043c\u0438\u043d\u0443\u0442"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/#article","isPartOf":{"@id":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/"},"author":{"name":"Maria","@id":"https:\/\/aristov.tech\/blog\/#\/schema\/person\/6a152749a3dde76f19cc30db676d2310"},"headline":"\u0422\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 PostgreSQL","datePublished":"2024-08-05T08:24:00+00:00","dateModified":"2024-10-07T11:59:30+00:00","mainEntityOfPage":{"@id":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/"},"wordCount":705,"commentCount":0,"publisher":{"@id":"https:\/\/aristov.tech\/blog\/#\/schema\/person\/05f3a04bf720ae4bf25ac99c4248d5e7"},"image":{"@id":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/#primaryimage"},"thumbnailUrl":"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/07\/image-28-1024x335.png","keywords":["bit_length","CAST","float","postgresql","sequence","uuid","with time zone","\u043a\u0443\u0440\u0441","\u0442\u0438\u043f \u0434\u0430\u043d\u043d\u044b\u0445"],"articleSection":["\u041a\u0443\u0440\u0441 SQL \u0441 0","\u041e\u0431\u0443\u0447\u0435\u043d\u0438\u0435 PostgreSQL"],"inLanguage":"ru-RU","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/","url":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/","name":"\u0422\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 PostgreSQL - \u0411\u043b\u043e\u0433 \u043f\u043e \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0435 \u0438 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438 PostgreSQL \u043e\u0442 \u0410\u0440\u0438\u0441\u0442\u043e\u0432\u0430 \u0415\u0432\u0433\u0435\u043d\u0438\u044f","isPartOf":{"@id":"https:\/\/aristov.tech\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/#primaryimage"},"image":{"@id":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/#primaryimage"},"thumbnailUrl":"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/07\/image-28-1024x335.png","datePublished":"2024-08-05T08:24:00+00:00","dateModified":"2024-10-07T11:59:30+00:00","description":"\u0412 \u0434\u0430\u043d\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043e \u0431\u0430\u0437\u043e\u0432\u044b\u0445 \u0442\u0438\u043f\u0430\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 PostgreSQL, \u0438\u0445 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0434\u0440\u0443\u0433 \u043a \u0434\u0440\u0443\u0433\u0443, \u0442\u0430\u043a\u0436\u0435 \u043e \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043a\u0430\u0445 money \u0438 real.","breadcrumb":{"@id":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/#breadcrumb"},"inLanguage":"ru-RU","potentialAction":[{"@type":"ReadAction","target":["https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/"]}]},{"@type":"ImageObject","inLanguage":"ru-RU","@id":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/#primaryimage","url":"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/07\/image-28.png","contentUrl":"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2024\/07\/image-28.png","width":1166,"height":382},{"@type":"BreadcrumbList","@id":"https:\/\/aristov.tech\/blog\/tipy-dannyh-postgresql\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u0413\u043b\u0430\u0432\u043d\u0430\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430","item":"https:\/\/aristov.tech\/blog\/"},{"@type":"ListItem","position":2,"name":"\u0422\u0438\u043f\u044b \u0434\u0430\u043d\u043d\u044b\u0445 PostgreSQL"}]},{"@type":"WebSite","@id":"https:\/\/aristov.tech\/blog\/#website","url":"https:\/\/aristov.tech\/blog\/","name":"\u0411\u043b\u043e\u0433 \u043f\u043e \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0435 \u0438 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438 PostgreSQL \u043e\u0442 \u0410\u0440\u0438\u0441\u0442\u043e\u0432\u0430 \u0415\u0432\u0433\u0435\u043d\u0438\u044f","description":"","publisher":{"@id":"https:\/\/aristov.tech\/blog\/#\/schema\/person\/05f3a04bf720ae4bf25ac99c4248d5e7"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/aristov.tech\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"ru-RU"},{"@type":["Person","Organization"],"@id":"https:\/\/aristov.tech\/blog\/#\/schema\/person\/05f3a04bf720ae4bf25ac99c4248d5e7","name":"admin2","image":{"@type":"ImageObject","inLanguage":"ru-RU","@id":"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2023\/05\/blog-logo.png","url":"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2023\/05\/blog-logo.png","contentUrl":"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2023\/05\/blog-logo.png","width":180,"height":180,"caption":"admin2"},"logo":{"@id":"https:\/\/aristov.tech\/blog\/wp-content\/uploads\/2023\/05\/blog-logo.png"},"sameAs":["https:\/\/aristov.tech\/blog"]},{"@type":"Person","@id":"https:\/\/aristov.tech\/blog\/#\/schema\/person\/6a152749a3dde76f19cc30db676d2310","name":"Maria","image":{"@type":"ImageObject","inLanguage":"ru-RU","@id":"https:\/\/secure.gravatar.com\/avatar\/a86c8edd49a73db805cc02e271f5fc126b109c146ad0d8976829c538b3b94ca4?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/a86c8edd49a73db805cc02e271f5fc126b109c146ad0d8976829c538b3b94ca4?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/a86c8edd49a73db805cc02e271f5fc126b109c146ad0d8976829c538b3b94ca4?s=96&d=mm&r=g","caption":"Maria"},"url":"https:\/\/aristov.tech\/blog\/author\/maria\/"}]}},"_links":{"self":[{"href":"https:\/\/aristov.tech\/blog\/wp-json\/wp\/v2\/posts\/917","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/aristov.tech\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/aristov.tech\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/aristov.tech\/blog\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/aristov.tech\/blog\/wp-json\/wp\/v2\/comments?post=917"}],"version-history":[{"count":4,"href":"https:\/\/aristov.tech\/blog\/wp-json\/wp\/v2\/posts\/917\/revisions"}],"predecessor-version":[{"id":1386,"href":"https:\/\/aristov.tech\/blog\/wp-json\/wp\/v2\/posts\/917\/revisions\/1386"}],"wp:attachment":[{"href":"https:\/\/aristov.tech\/blog\/wp-json\/wp\/v2\/media?parent=917"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/aristov.tech\/blog\/wp-json\/wp\/v2\/categories?post=917"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/aristov.tech\/blog\/wp-json\/wp\/v2\/tags?post=917"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}