I would like a user to enter a single border of markers on the map

0

Good morning, I would like to know if there is a way for me to determine a maximum limit of markers registrations for a user, depending on their level of access in the database. Example:

CREATE TABLE tb_users (

id_users int (11) NOT NULL AUTO_INCREMENT,

email varchar (50) NOT NULL,

usuario varchar (20) NOT NULL,

senha varchar (15) NOT NULL,

nome varchar (35) NOT NULL,

telefone varchar (15) NOT NULL,

status varchar (10) NOT NULL,

pagseguro varchar (20) DEFAULT NULL,

PRIMARY KEY ( id_users )

)

In the above table, if the user was level 2 in the payout column, he could then register 4 markers on the map. Anyway, I want to know how I put this limit to the user ??

    
asked by anonymous 16.05.2017 / 15:31

1 answer

0

At first it would be a single boundary of markers. the ratio would be 1 to 1 for another table with reference to safe pay; only dependence q I noticed for the quantity indication, normalizing.

However,notethatitisavarcharastheprimarykey;Iwouldrecommendanothersecurepaytable,containingsecure_id,afieldwithdescription,andtheamountofmarkers...;ThatwayI'dreferenceaninteger .

    
16.05.2017 / 16:20