Archived
1
0
Fork 0

Some line ending normalization

This commit is contained in:
Henrik Hautakoski 2015-03-05 11:44:59 +01:00
parent 9a68a04790
commit a493f4db19
2 changed files with 92 additions and 92 deletions

View file

@ -1,49 +1,49 @@
/*
Sample grant for PostgreSQL
CREATE ROLE queue LOGIN
PASSWORD '[CHANGE ME]'
NOSUPERUSER NOINHERIT NOCREATEDB NOCREATEROLE;
*/
--
-- Table structure for table `queue`
--
DROP TABLE IF EXISTS queue;
CREATE TABLE queue
(
queue_id serial NOT NULL,
queue_name character varying(100) NOT NULL,
timeout smallint NOT NULL DEFAULT 30,
CONSTRAINT queue_pk PRIMARY KEY (queue_id)
)
WITH (OIDS=FALSE);
ALTER TABLE queue OWNER TO queue;
-- --------------------------------------------------------
--
-- Table structure for table `message`
--
DROP TABLE IF EXISTS message;
CREATE TABLE message
(
message_id bigserial NOT NULL,
queue_id integer,
handle character(32),
body character varying(8192) NOT NULL,
md5 character(32) NOT NULL,
timeout real,
created integer,
CONSTRAINT message_pk PRIMARY KEY (message_id),
CONSTRAINT message_ibfk_1 FOREIGN KEY (queue_id)
REFERENCES queue (queue_id) MATCH SIMPLE
ON UPDATE CASCADE ON DELETE CASCADE
)
WITH (OIDS=FALSE);
/*
Sample grant for PostgreSQL
CREATE ROLE queue LOGIN
PASSWORD '[CHANGE ME]'
NOSUPERUSER NOINHERIT NOCREATEDB NOCREATEROLE;
*/
--
-- Table structure for table `queue`
--
DROP TABLE IF EXISTS queue;
CREATE TABLE queue
(
queue_id serial NOT NULL,
queue_name character varying(100) NOT NULL,
timeout smallint NOT NULL DEFAULT 30,
CONSTRAINT queue_pk PRIMARY KEY (queue_id)
)
WITH (OIDS=FALSE);
ALTER TABLE queue OWNER TO queue;
-- --------------------------------------------------------
--
-- Table structure for table `message`
--
DROP TABLE IF EXISTS message;
CREATE TABLE message
(
message_id bigserial NOT NULL,
queue_id integer,
handle character(32),
body character varying(8192) NOT NULL,
md5 character(32) NOT NULL,
timeout real,
created integer,
CONSTRAINT message_pk PRIMARY KEY (message_id),
CONSTRAINT message_ibfk_1 FOREIGN KEY (queue_id)
REFERENCES queue (queue_id) MATCH SIMPLE
ON UPDATE CASCADE ON DELETE CASCADE
)
WITH (OIDS=FALSE);
ALTER TABLE message OWNER TO queue;

View file

@ -1,44 +1,44 @@
CREATE TABLE [dbo].[queue](
[queue_id] [int] IDENTITY(1,1) NOT NULL,
[queue_name] [varchar](100) NOT NULL,
[timeout] [int] NOT NULL,
CONSTRAINT [PK_queue] PRIMARY KEY CLUSTERED
(
[queue_id] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[queue] ADD DEFAULT ((30)) FOR [timeout]
GO
CREATE TABLE [dbo].[message](
[message_id] [bigint] IDENTITY(1,1) NOT NULL,
[queue_id] [int] NOT NULL,
[handle] [char](32) NULL,
[body] [varchar](max) NOT NULL,
[md5] [char](32) NOT NULL,
[timeout] [decimal](14, 4) NULL,
[created] [int] NOT NULL,
CONSTRAINT [PK_message] PRIMARY KEY CLUSTERED
(
[message_id] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[message] WITH CHECK ADD CONSTRAINT [fk_message_queue_id] FOREIGN KEY([queue_id])
REFERENCES [dbo].[queue] ([queue_id])
GO
ALTER TABLE [dbo].[message] CHECK CONSTRAINT [fk_message_queue_id]
GO
CREATE TABLE [dbo].[queue](
[queue_id] [int] IDENTITY(1,1) NOT NULL,
[queue_name] [varchar](100) NOT NULL,
[timeout] [int] NOT NULL,
CONSTRAINT [PK_queue] PRIMARY KEY CLUSTERED
(
[queue_id] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[queue] ADD DEFAULT ((30)) FOR [timeout]
GO
CREATE TABLE [dbo].[message](
[message_id] [bigint] IDENTITY(1,1) NOT NULL,
[queue_id] [int] NOT NULL,
[handle] [char](32) NULL,
[body] [varchar](max) NOT NULL,
[md5] [char](32) NOT NULL,
[timeout] [decimal](14, 4) NULL,
[created] [int] NOT NULL,
CONSTRAINT [PK_message] PRIMARY KEY CLUSTERED
(
[message_id] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[message] WITH CHECK ADD CONSTRAINT [fk_message_queue_id] FOREIGN KEY([queue_id])
REFERENCES [dbo].[queue] ([queue_id])
GO
ALTER TABLE [dbo].[message] CHECK CONSTRAINT [fk_message_queue_id]
GO