<?xml version="1.0" encoding="UTF-8"?>
<table>
    <column>
        <name>creation_date</name>
        <type>timestamp</type>
        <null>NO</null>
    </column>
    <column>
        <name>id</name>
        <type>serial</type>
        <null>NO</null>
    </column>
    <column>
        <name>id_report_board</name>
        <type>integer</type>
        <null>NO</null>
    </column>
    <column>
        <name>last_nick</name>
        <type>character varying(50)</type>
    </column>
    <column>
        <name>last_update</name>
        <type>timestamp</type>
    </column>
    <column>
        <name>nick</name>
        <type>character varying(50)</type>
    </column>
    <column>
        <name>user_nick</name>
        <type>character varying(50)</type>
        <null>NO</null>
    </column>
    <constraint>
        <name>reports_boards_users_pkey</name>
        <type>PRIMARY KEY (id)</type>
    </constraint>
    <constraint>
        <name>uniq_reports_boards_users</name>
        <type>UNIQUE (id_report_board,user_nick)</type>
    </constraint>
    <constraint>
        <name>ca_reports_boards_users_last_nick</name>
        <type>FOREIGN KEY (last_nick) REFERENCES users (nick) ON DELETE SET NULL ON UPDATE CASCADE</type>
    </constraint>
    <constraint>
        <name>ca_reports_boards_users_nick</name>
        <type>FOREIGN KEY (nick) REFERENCES users (nick) ON DELETE SET NULL ON UPDATE CASCADE</type>
    </constraint>
    <constraint>
        <name>ca_reports_boards_users</name>
        <type>FOREIGN KEY (user_nick) REFERENCES users (nick) ON DELETE CASCADE ON UPDATE CASCADE</type>
    </constraint>
    <constraint>
        <name>ca_reports_boards_users_report_boards</name>
        <type>FOREIGN KEY (id_report_board) REFERENCES reports_boards (id) ON DELETE CASCADE ON UPDATE CASCADE</type>
    </constraint>
</table>