{"id":13527979,"url":"https://github.com/aurasphere/gomorra-sql","last_synced_at":"2025-05-16T12:03:09.733Z","repository":{"id":44452590,"uuid":"362274388","full_name":"aurasphere/gomorra-sql","owner":"aurasphere","description":"SQL made uagliò.","archived":false,"fork":false,"pushed_at":"2023-06-06T19:16:42.000Z","size":297,"stargazers_count":1349,"open_issues_count":11,"forks_count":24,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-04-09T07:03:18.332Z","etag":null,"topics":["esoteric-language","napoli","sql"],"latest_commit_sha":null,"homepage":"https://aurasphere.co/gomorra-sql","language":"CSS","has_issues":false,"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/aurasphere.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}},"created_at":"2021-04-27T23:00:43.000Z","updated_at":"2025-04-06T21:36:21.000Z","dependencies_parsed_at":"2023-10-20T18:07:36.883Z","dependency_job_id":null,"html_url":"https://github.com/aurasphere/gomorra-sql","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aurasphere%2Fgomorra-sql","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aurasphere%2Fgomorra-sql/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aurasphere%2Fgomorra-sql/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aurasphere%2Fgomorra-sql/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aurasphere","download_url":"https://codeload.github.com/aurasphere/gomorra-sql/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254527084,"owners_count":22085918,"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":["esoteric-language","napoli","sql"],"created_at":"2024-08-01T06:02:09.128Z","updated_at":"2025-05-16T12:03:09.690Z","avatar_url":"https://github.com/aurasphere.png","language":"CSS","readme":"[![Travis](https://img.shields.io/travis/aurasphere/gomorra-sql.svg)](https://travis-ci.org/aurasphere/gomorra-sql)\n[![Maintainability](https://api.codeclimate.com/v1/badges/6de2eb23249ef4c8a60c/maintainability)](https://codeclimate.com/github/aurasphere/gomorra-sql/maintainability)\n[![Test Coverage](https://api.codeclimate.com/v1/badges/6de2eb23249ef4c8a60c/test_coverage)](https://codeclimate.com/github/aurasphere/gomorra-sql/test_coverage)\n[![Join the chat at https://gitter.im/gomorra-sql/community](https://badges.gitter.im/gomorra-sql/community.svg)](https://gitter.im/gomorra-sql/community?utm_source=badge\u0026utm_medium=badge\u0026utm_campaign=pr-badge\u0026utm_content=badge)\n[![Donate](https://img.shields.io/badge/Donate-PayPal-orange.svg)](https://www.paypal.com/donate/?cmd=_donations\u0026business=8UK2BZP2K8NSS)\n[![Telegram](https://img.shields.io/badge/-telegram-a?color=white\u0026logo=telegram)](https://t.me/+Wy1DPTLyFGg0OWE0)\n\n![logo](https://user-images.githubusercontent.com/14991778/117669306-0a931c00-b1a7-11eb-8db8-babc14e767d1.png)\n\n\nGomorraSQL is an easy and straightforward interpreted SQL dialect that allows you to write simpler and more understandable queries in [Neapolitan Language](https://en.wikipedia.org/wiki/Neapolitan_language).\n\n## Set up\nGomorraSQL can be used either as a Java library or as a standalone SQL database client.\n\n### Java library\nTo use it as a Java library, download the latest jar in the release section and import it into your project, along with the driver of the database you want to use. Then, you can use the methods exposed by the class ```co.aurasphere.gomorrasql.GomorraSqlInterpreter``` which allow you to either execute a GomorraSQL query against your database (to which you will provide a connection) or just translate it into plain old SQL.\nGomorraSQL throws a ```CaggiaFaException``` with useful debugging information whenever an error occurs.\n\n### Database client\nTo use GomorraSQL as a database client, download the latest jar in the release section and execute it with the command:\n\n    java -cp gomorra-sql-1.0.0.jar;\u003cpath_to_your_db_driver\u003e co.aurasphere.gomorrasql.GomorraSqlShell\n    \nThe client will ask for a JDBC string representing the database to connect to (including credentials). After the connection is established, you can start running commands.\n\n## Language basics\nBefore delving into the specific commands, it's important to consider some general rules to avoid \"cuoppo\" mistakes:\n\n- parenthesis are not valid characters in GomorraSQL queries. In the following examples, they are just used to distinguish between (mandatory parameters) and [optional parameters]\n-  GomorraSQL doesn't allow multi-line queries. Therefore, there's no end-of-query character (like ; in SQL)\n-  spacing is very important when using operators! A query using a condition ```a = 5``` will work but the same query with ```a= 5``` or ```a =5``` or ```a=5``` will not\n\n## Data Manipulation Language\nLikewise standard SQL, GomorraSQL allows performing data manipulation. Here's a list of supported operations:\n\n### Retrieving data\nTo retrieve data, you can use the ```ripigliammo``` command. Here's the command syntax:\n\n    ripigliammo (\u003ccomma_separated_column_names\u003e || tutto chillo ch'era 'o nuostro) mmiez 'a \u003ctable_name\u003e [pesc e pesc \u003ctable_name\u003e...] [arò \u003ccondition\u003e]\n\nThe first argument for the ```ripigliammo``` command is the columns to retrieve. They can be specified either as a list of comma-separated values or with the ```tutto chillo ch'era 'o nuostro``` which will return all the columns.\n\nAfter the columns, the following parameter is the name of the table where to fetch the data with ```mmiez 'a```. Data can be fetched from multiple tables by using the optional join operator ```pesc e pesc``` followed by another table name. Currently, there's no limit on the number of ```pesc e pesc``` that can be applied to a single ```ripigliammo```. The join condition is specified in the ```arò``` clause, along with the row filtering.\n\nFinally, you can filter the rows using the optional ```arò``` clause, followed by one or more conditions. The conditions work exactly like in SQL, with a slightly different syntax for some operators (check the [Language Reference](#language-reference) section).\n\nHere are some sample queries:\n\n    ripigliammo tutto chillo ch'era 'o nuostro mmiez 'a user  # retrieves all users' data\n    ripigliammo email mmiez 'a user arò id = 6 o name è nisciun  # retrieves all the emails of the users with id 6 or null name\n    ripigliammo email mmiez 'a user pesc e pesc city pesc e pesc account arò user.id = 6 e user.birth_city = city.id e user.account_id = account.id  # retrieves the data of the user with id 6 along joined with his birth city and his account data\n\n### Deleting data\nData deletion can be performed using the ```facimm na' strage``` command which supports a subset of options from the ```ripigliammo``` command. Here's the syntax:\n\n    facimm na' strage mmiez 'a \u003ctable_name\u003e [arò \u003ccondition\u003e]\n    \nHere are some sample queries:\n\n    facimm na' strage mmiez 'a user  # deletes all users' data\n    facimm na' strage mmiez 'a user arò name nun è nisciun o deleted è true  # deletes the users with name not null or with deleted = true\n    \n### Updating data\nThe command ```rifacimm``` is used to update data in a table. The syntax is:\n\n    rifacimm \u003ctable_name\u003e accunza \u003ccolumn_1\u003e accussì \u003cvalue_1\u003e, \u003ccolumn_2\u003e accussì \u003cvalue_2\u003e, ... [arò \u003cconditions\u003e]\n    \nThe  ```accunza``` operator marks the begin of a list of column/values assignments using the assignment operator ```accussì```.\n\nHere are some sample queries:\n\n    rifacimm user accunza name accussì \"Pippo\"  # sets the name \"Pippo\" for all the users\n    rifacimm user accunza name accussì \"Pinco\", surname accussì \"Pallo\" arò name è nisciun  # sets the name to \"Pinco\" and surname to \"Pallo\" for all users with null name\n\n### Inserting data\nData insertion can be performed using the ```nzipp 'ngoppa``` operator as following:\n\n    nzipp 'ngoppa \u003ctable_name\u003e (\u003ccolumn_1\u003e, \u003ccolumn_2\u003e...) chist \u003cvalue_1\u003e, \u003cvalue_2\u003e...\n    \nAfter the table name, you can specify a list of columns whose data are being inserted. If not present, GomorraSQL will default to all columns. The ```chist``` keyword marks the beginning of a comma-separated list of values to insert. Each insert statement can only add one row.\n\nHere are some sample queries:\n\n    nzipp 'ngoppa user chist 1, \"Pinco\", \"Pallo\"  # inserts a new user with all his data\n    nzipp 'ngoppa user name chist \"Pinco\"  # inserts a new user with only his name set\n\n\n## Transaction support\nBeing a fully ACID compliant language, GomorraSQL offers basic transaction management. To begin a transaction, you can issue the command ```ua uagliò```. You can then commit the transaction with the command ```iamme bello ia'``` or perform rollback with the command ```sfaccimm```.\n\n## Language reference\nFollows a table that roughly maps GomorraSQL language to standard SQL:\n\n| GomorraSQL keyword             | SQL equivalent | Valid in...            |\n|--------------------------------|----------------|------------------------|\n| ripigliammo                    | SELECT         | SELECT                 |\n| rifacimm                       | UPDATE         | UPDATE                 |\n| nzipp                          | INSERT         | INSERT                 |\n| 'ngoppa                        | INTO           | INSERT                 |\n| facimm na' strage              | DELETE         | DELETE                 |\n| pesc e pesc                    | INNER JOIN     | SELECT                 |\n| mmiez 'a                       | FROM           | SELECT, DELETE         |\n| tutto chillo ch'era 'o nuostro | *              | SELECT                 |\n| arò                            | WHERE          | SELECT, UPDATE, DELETE |\n| e                              | AND            | ANY WHERE CLAUSE       |\n| o                              | OR             | ANY WHERE CLAUSE       |\n| nisciun                        | NULL           | ANY WHERE CLAUSE       |\n| è                              | IS             | ANY WHERE CLAUSE       |\n| nun è                          | IS NOT         | ANY WHERE CLAUSE       |\n| chist                          | VALUES         | INSERT                 |\n| accunza                        | SET            | UPDATE                 |\n| accussì                        | = (assignment) | UPDATE                 |\n| \u003e                              | \u003e              | ANY WHERE CLAUSE       |\n| \u003c                              | \u003c              | ANY WHERE CLAUSE       |\n| = (comparison)                 | = (comparison) | ANY WHERE CLAUSE       |\n| !=                             | !=             | ANY WHERE CLAUSE       |\n| \u003c\u003e                             | \u003c\u003e             | ANY WHERE CLAUSE       |\n| \u003c=                             | \u003c=             | ANY WHERE CLAUSE       |\n| \u003e=                             | \u003e=             | ANY WHERE CLAUSE       |\n| sfaccimm                       | ROLLBACK       | TRANSACTION            |\n| iamme bello ia'                | COMMIT         | TRANSACTION            |\n| ua uagliò                      | BEGIN TRANSACTION | TRANSACTION         |\n\n## Supported Database\nGomorraSQL has been extensively tested with MySQL and H2. Other databases may not work properly.\n\n## Training\nVideo lessons on GomorraSQL syntax and philosophy [are available here](https://www.nowtv.it/watch/home/asset/gomorra-la-serie/skyatlantic_7bb8b3e11d19439fb71c68349b2cfab3). If you are also interested in corporate training, feel free to contact me for pricing.\n\n## Certifications\nIf you have an issued certification, you can check it out at the following URL by replacing the \"user\" parameter with your name (replace spaces with hyphens): https://aurasphere.co/gomorra-sql/certificate.html?user=donato-rimenti.\n\n## Project status\nThis project is considered completed and won't be developed further.\n\n## Contacts\nYou can contact me using my account e-mail or by joining the Telegram group (link on the badge on top of this document). I'll try to reply ASAP.\n\n## Acknowledgments\nThanks to [Federica Lisci](https://www.linkedin.com/in/federica-lisci-377220162/) for the logo!\n\n## License\nThe project is released under the MIT license, which lets you reuse the code for any purpose you want (even commercial) with the only requirement being copying this project license on your project.\n\n\u003csub\u003eCopyright (c) 2021 Donato Rimenti\u003c/sub\u003e\n","funding_links":["https://www.paypal.com/donate/?cmd=_donations\u0026business=8UK2BZP2K8NSS"],"categories":["CSS"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faurasphere%2Fgomorra-sql","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faurasphere%2Fgomorra-sql","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faurasphere%2Fgomorra-sql/lists"}