{"id":20644048,"url":"https://github.com/adjust/pg-currency","last_synced_at":"2025-04-16T02:07:14.857Z","repository":{"id":28872709,"uuid":"32396982","full_name":"adjust/pg-currency","owner":"adjust","description":"1 Byte Currency ISO type for PostgreSQL","archived":false,"fork":false,"pushed_at":"2025-03-14T16:42:42.000Z","size":61,"stargazers_count":16,"open_issues_count":0,"forks_count":4,"subscribers_count":62,"default_branch":"master","last_synced_at":"2025-04-16T02:06:51.585Z","etag":null,"topics":["adjust-kpis-team","postgresql"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/adjust.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-03-17T14:04:58.000Z","updated_at":"2025-04-09T10:10:15.000Z","dependencies_parsed_at":"2024-10-23T12:56:06.354Z","dependency_job_id":null,"html_url":"https://github.com/adjust/pg-currency","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adjust%2Fpg-currency","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adjust%2Fpg-currency/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adjust%2Fpg-currency/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adjust%2Fpg-currency/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/adjust","download_url":"https://codeload.github.com/adjust/pg-currency/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249183103,"owners_count":21226142,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["adjust-kpis-team","postgresql"],"created_at":"2024-11-16T16:14:38.001Z","updated_at":"2025-04-16T02:07:14.839Z","avatar_url":"https://github.com/adjust.png","language":"C","funding_links":[],"categories":["C"],"sub_categories":[],"readme":"[![CI](https://github.com/adjust/pg-currency/actions/workflows/main.yml/badge.svg)](https://github.com/adjust/pg-currency/actions/workflows/main.yml)\n\n# PG Currency\n\nA 1-byte ISO 4217 Currency Code data-type for PostgreSQL.\n\n### Installation\n\nYou can clone the extension and run the standard `make \u0026\u0026 make install` to\nbuild it against your PostgreSQL server.\n\n### Usage\n\nThe currency extension defines a data-type `currency`, which can be used, for\nexample, in `CREATE TABLE` statements. There're also comparison operators to\nsupport ordering and `btree` indexing.\n\n#### Using the currency data-type\n\nThe following example illustrates the use of the `country` type.\n\n```SQL\nCREATE TABLE transactions (id serial, payment_currency currency);\n\nINSERT INTO transactions (values\n  (1, 'USD'),\n  (2, 'EUR'),\n  (3, 'USD')\n);\n\nSELECT * FROM transactions ORDER BY payment_currency;\n```\n\nThe result from the above execution will be:\n\n```\nid | payment_currency\n----+------------------\n  2 | EUR\n  1 | USD\n  3 | USD\n(3 rows)\n```\n\n#### List of supported currencies\n\nTo get a list of supported for the installed version, you can use the `supported_currencies` SRF.\n\n```\nSELECT * FROM supported_currencies();\n```\n\nThis will return a set of the supported currencies with no specific ordering.\n\n```\nSELECT * FROM supported_currencies() currency ORDER BY currency;\n```\n\n### Development\n\nTo run the tests, clone and run `make \u0026\u0026 make install \u0026\u0026 make installcheck`.\n[Dumbo](https://github.com/adjust/dumbo) is the recommended development tool for\nthe extension.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadjust%2Fpg-currency","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fadjust%2Fpg-currency","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadjust%2Fpg-currency/lists"}