root/sql/tables/noit.check_tag.sql

Revision 2b8f8c20cf8db128b58a867bceb25006514a662e, 1.6 kB (checked in by Robert Treat <robert@omniti.com>, 5 years ago)

fix up bugs now that it's tested

  • Property mode set to 100644
Line 
1 -- formerly check_tags
2
3 --
4 -- PostgreSQL database dump
5 --
6
7 SET client_encoding = 'UTF8';
8 SET standard_conforming_strings = off;
9 SET check_function_bodies = false;
10 SET client_min_messages = warning;
11 SET escape_string_warning = off;
12
13 SET search_path = noit, pg_catalog;
14
15 SET default_tablespace = '';
16
17 SET default_with_oids = false;
18
19 --
20 -- Name: check_tag; Type: TABLE; Schema: noit; Owner: reconnoiter; Tablespace:
21 --
22
23 CREATE TABLE check_tag (
24     sid integer NOT NULL,
25     tags_array text[]
26 );
27
28
29 ALTER TABLE noit.check_tag OWNER TO reconnoiter;
30
31 --
32 -- Name: check_tag_pkey; Type: CONSTRAINT; Schema: noit; Owner: reconnoiter; Tablespace:
33 --
34
35 ALTER TABLE ONLY check_tag
36     ADD CONSTRAINT check_tag_pkey PRIMARY KEY (sid);
37
38
39 --
40 -- Name: update_metric_name_summary_fulltext; Type: TRIGGER; Schema: noit; Owner: reconnoiter
41 --
42
43 CREATE TRIGGER update_metric_name_summary_fulltext
44     AFTER INSERT OR UPDATE ON check_tag
45     FOR EACH ROW
46     EXECUTE PROCEDURE update_mns_via_check_tag();
47
48
49 --
50 -- Name: check_tag_sid_fkey; Type: FK CONSTRAINT; Schema: noit; Owner: reconnoiter
51 -- NOTE: this FK reference is only valid on single database installations
52 --
53
54 ALTER TABLE ONLY check_tag
55     ADD CONSTRAINT check_tag_sid_fkey FOREIGN KEY (sid) REFERENCES stratcon.map_uuid_to_sid(sid);
56
57
58 --
59 -- Name: check_tag; Type: ACL; Schema: noit; Owner: reconnoiter
60 --
61
62 REVOKE ALL ON TABLE check_tag FROM PUBLIC;
63 REVOKE ALL ON TABLE check_tag FROM reconnoiter;
64 GRANT ALL ON TABLE check_tag TO reconnoiter;
65 GRANT ALL ON TABLE check_tag TO prism;
66 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE check_tag TO stratcon;
67
68
69 --
70 -- PostgreSQL database dump complete
71 --
72
Note: See TracBrowser for help on using the browser.