> For the complete documentation index, see [llms.txt](https://anton-veselskyi.gitbook.io/codding-problems-solutions/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://anton-veselskyi.gitbook.io/codding-problems-solutions/codewars/8-kyu/sql-basics-mod.md).

# SQL Basics: Mod

## [SQL Basics: Mod](https://www.codewars.com/kata/594a9592704e4d21bc000131)

Given the following table 'decimals':

&#x20;**decimals table schema**&#x20;

* id
* number1
* number2

Return a table with one column (mod) which is the output of number1 modulus number2.

## Solutions

### 🗃️ Sql

```sql
select number1 % number2 as mod
from decimals;
```
