1/*
2 * $Id: 0d1727fd96c982ecbda5355361ccd7c30a4c1948 $
3 *
4 * PostgreSQL schema for DHCP for FreeRADIUS
5 *
6 */
7
8/*
9 * Table structure for table 'dhcpgroupreply'
10 */
11CREATE TABLE IF NOT EXISTS dhcpgroupreply (
12	id			serial PRIMARY KEY,
13	GroupName		text NOT NULL DEFAULT '',
14	Attribute		text NOT NULL DEFAULT '',
15	op			VARCHAR(2) NOT NULL DEFAULT '=',
16	Value			text NOT NULL DEFAULT '',
17	Context			text NOT NULL DEFAULT ''
18);
19CREATE INDEX dhcpgroupreply_GroupName ON dhcpgroupreply (Context,GroupName,Attribute);
20
21/*
22 * Table structure for table 'dhcpreply'
23 */
24CREATE TABLE IF NOT EXISTS dhcpreply (
25	id			serial PRIMARY KEY,
26	Identifier		text NOT NULL DEFAULT '',
27	Attribute		text NOT NULL DEFAULT '',
28	op			VARCHAR(2) NOT NULL DEFAULT '=',
29	Value			text NOT NULL DEFAULT '',
30	Context			text NOT NULL DEFAULT ''
31);
32CREATE INDEX dhcpreply_Identifier ON dhcpreply (Context,Identifier,Attribute);
33
34/*
35 * Table structure for table 'dhcpgroup'
36 */
37CREATE TABLE IF NOT EXISTS dhcpgroup (
38	id			serial PRIMARY KEY,
39	Identifier		text NOT NULL DEFAULT '',
40	GroupName		text NOT NULL DEFAULT '',
41	Priority		integer NOT NULL DEFAULT 0,
42	Context			text NOT NULL DEFAULT ''
43);
44CREATE INDEX dhcpgroup_Identifier ON dhcpgroup (Context,Identifier);
45