Here is the code I'm Testing :

```
DO $$
DECLARE 
    i INT := 0;
BEGIN
    WHILE i <= numberUsers
    BEGIN
        SELECT COUNT(*) FROM "Users";
        SET i := i + 1;
    END;
END $$;

```

But when I try to execute it it return me this error :

```
ERREUR:  « LOOP » manquant à la fin de l'expression SQL
LIGNE 7 :         SELECT COUNT(*) FROM "Users";

```

[![enter image description here](https://i.stack.imgur.com/vR833.png)](https://i.stack.imgur.com/vR833.png)

Kind Regards !