PostgreSQL loop with random inserts

Viewed 8621

I have a table in db:

CREATE TABLE operation ( <br>
    id     integer NOT NULL DEFAULT NEXTVAL ('seq_operation'),( <br>
    phone_number     varchar(30),( <br>
    age     integer,( <br>
    gender     char(1),( <br>
    isActive     boolean,( <br>
    date_of_surgery     timestamp,( <br>
);

I need to insert 10000 rows with random data. How can I make such INSERT statement? Im fresh with this stuff and trying to figure it out with other answers for similiar question here, but cant find easy understandable one for me.

I would really appreciate your help.

Best regards, Max

1 Answers
Related