CREATE DATABASE IF NOT EXISTS SAZDB;
use SAZDB;
CREATE TABLE IF NOT EXISTS admin(
	dn CHAR(255),
	prin CHAR(255),
	vo CHAR(255) NOT NULL DEFAULT 'all',
	rights CHAR(255),
	changedAt TIMESTAMP
	);

CREATE TABLE user (
	vo CHAR(255),
	dn CHAR(255) NOT NULL PRIMARY KEY, 
	prin CHAR(255), 
	status ENUM('Y','N') NOT NULL,
	changeAt TIMESTAMP
	);

CREATE TABLE vo (
	vo CHAR(255) NOT NULL PRIMARY KEY
);



FLUSH PRIVILEGES;

--rights ENUM('all','add','del','ls','enable','disable','prin') DEFAULT 'all',
