Title: Support PostgreSQL CREATE TABLE LIKE · Issue #481 · sqlc-dev/sqlc · GitHub
Open Graph Title: Support PostgreSQL CREATE TABLE LIKE · Issue #481 · sqlc-dev/sqlc
X Title: Support PostgreSQL CREATE TABLE LIKE · Issue #481 · sqlc-dev/sqlc
Description: The following create table statement CREATE TABLE changes ( ranked INT NOT NULL ); CREATE TABLE changes_ranked ( LIKE changes INCLUDING ALL, rank_by_effect_size INT NOT NULL, rank_by_abs_percent_change INT NOT NULL ); -- name: AllRanked ...
Open Graph Description: The following create table statement CREATE TABLE changes ( ranked INT NOT NULL ); CREATE TABLE changes_ranked ( LIKE changes INCLUDING ALL, rank_by_effect_size INT NOT NULL, rank_by_abs_percent_ch...
X Description: The following create table statement CREATE TABLE changes ( ranked INT NOT NULL ); CREATE TABLE changes_ranked ( LIKE changes INCLUDING ALL, rank_by_effect_size INT NOT NULL, rank_by_abs_percent_ch...
Opengraph URL: https://github.com/sqlc-dev/sqlc/issues/481
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Support PostgreSQL CREATE TABLE LIKE","articleBody":"The following create table statement\r\n\r\n```sql\r\nCREATE TABLE changes (\r\n ranked INT NOT NULL\r\n);\r\n\r\nCREATE TABLE changes_ranked (\r\n LIKE changes INCLUDING ALL,\r\n rank_by_effect_size INT NOT NULL,\r\n rank_by_abs_percent_change INT NOT NULL\r\n);\r\n\r\n\r\n-- name: AllRanked :many\r\nSELECT * FROM changes_ranked;\r\n```\r\n\r\nproduces model\r\n```go\r\ntype ChangesRanked struct {\r\n RankByEffectSize int32\r\n RankByAbsPercentChange int32\r\n}\r\n```\r\nColumns from the `changes` table are ignored.\r\n\r\n(Aside: I encountered this while trying to work around #159. The `changes_ranked` table is an attempt to materialize what would have been a subquery.)","author":{"url":"https://github.com/mmcloughlin","@type":"Person","name":"mmcloughlin"},"datePublished":"2020-05-12T06:57:35.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":2},"url":"https://github.com/481/sqlc/issues/481"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:85c28152-79ff-b413-bee8-edee642c35c2 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | D992:204E27:AB15A0C:AE8A11A:6A50BA85 |
| html-safe-nonce | 922d7c0e454e92dca5eaac3c74de107e85f3c019d0dfda758f42674031f8fc00 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEOTkyOjIwNEUyNzpBQjE1QTBDOkFFOEExMUE6NkE1MEJBODUiLCJ2aXNpdG9yX2lkIjoiNTY2NDAwNDY3NTA2MDg0NDg1IiwicmVnaW9uX2VkZ2UiOiJzZWEiLCJyZWdpb25fcmVuZGVyIjoic2VhIn0= |
| visitor-hmac | 97131706c2752bd96abe9e6f5c4021f50bf8ba21acd5c76dd96fcee03e88ccd0 |
| hovercard-subject-tag | issue:616410640 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/sqlc-dev/sqlc/481/issue_layout |
| twitter:image | https://opengraph.githubassets.com/93ddc506e9b75e233045321eb35016d8695e067aac0ea7503a4c5e11b380f04a/sqlc-dev/sqlc/issues/481 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/93ddc506e9b75e233045321eb35016d8695e067aac0ea7503a4c5e11b380f04a/sqlc-dev/sqlc/issues/481 |
| og:image:alt | The following create table statement CREATE TABLE changes ( ranked INT NOT NULL ); CREATE TABLE changes_ranked ( LIKE changes INCLUDING ALL, rank_by_effect_size INT NOT NULL, rank_by_abs_percent_ch... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | mmcloughlin |
| hostname | github.com |
| expected-hostname | github.com |
| None | 72b13e0e8d0319acdd27a145cfe73f4f06c791713d0ac4690e41fb68ad28cac0 |
| turbo-cache-control | no-preview |
| go-import | github.com/sqlc-dev/sqlc git https://github.com/sqlc-dev/sqlc.git |
| octolytics-dimension-user_id | 136738596 |
| octolytics-dimension-user_login | sqlc-dev |
| octolytics-dimension-repository_id | 193160679 |
| octolytics-dimension-repository_nwo | sqlc-dev/sqlc |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 193160679 |
| octolytics-dimension-repository_network_root_nwo | sqlc-dev/sqlc |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 08e79d53fc070870d5b168356afebb1e286a2ffe |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width