Project

General

Profile

« Previous | Next » 

Revision 13578

inputs/.TNRS/schema.sql: tnrs: populate match_num

View differences:

trunk/inputs/.TNRS/schema.sql
174 174

  
175 175

  
176 176
--
177
-- Name: tnrs__match_num__fill(); Type: FUNCTION; Schema: TNRS; Owner: -
178
--
179

  
180
CREATE FUNCTION tnrs__match_num__fill() RETURNS trigger
181
    LANGUAGE plpgsql
182
    AS $$
183
BEGIN
184
	new.match_num = "TNRS".tnrs__match_num__next();
185
	RETURN new;
186
END;
187
$$;
188

  
189

  
190
--
177 191
-- Name: tnrs__match_num__next(); Type: FUNCTION; Schema: TNRS; Owner: -
178 192
--
179 193

  
......
729 743

  
730 744

  
731 745
--
746
-- Name: tnrs__match_num__fill; Type: TRIGGER; Schema: TNRS; Owner: -
747
--
748

  
749
CREATE TRIGGER tnrs__match_num__fill BEFORE INSERT ON tnrs FOR EACH ROW EXECUTE PROCEDURE tnrs__match_num__fill();
750

  
751

  
752
--
732 753
-- Name: tnrs_populate_fields; Type: TRIGGER; Schema: TNRS; Owner: -
733 754
--
734 755

  
trunk/schemas/vegbien.my.sql
13234 13234

  
13235 13235

  
13236 13236
--
13237
-- Name: tnrs__match_num__fill(); Type: FUNCTION; Schema: TNRS; Owner: -
13238
--
13239

  
13240

  
13241

  
13242

  
13243
--
13237 13244
-- Name: tnrs__match_num__next(); Type: FUNCTION; Schema: TNRS; Owner: -
13238 13245
--
13239 13246

  
......
13620 13627

  
13621 13628

  
13622 13629
--
13630
-- Name: tnrs__match_num__fill; Type: TRIGGER; Schema: TNRS; Owner: -
13631
--
13632

  
13633

  
13634

  
13635

  
13636
--
13623 13637
-- Name: tnrs_populate_fields; Type: TRIGGER; Schema: TNRS; Owner: -
13624 13638
--
13625 13639

  
trunk/schemas/vegbien.sql
16969 16969

  
16970 16970

  
16971 16971
--
16972
-- Name: tnrs__match_num__fill(); Type: FUNCTION; Schema: TNRS; Owner: -
16973
--
16974

  
16975
CREATE FUNCTION tnrs__match_num__fill() RETURNS trigger
16976
    LANGUAGE plpgsql
16977
    AS $$
16978
BEGIN
16979
	new.match_num = "TNRS".tnrs__match_num__next();
16980
	RETURN new;
16981
END;
16982
$$;
16983

  
16984

  
16985
--
16972 16986
-- Name: tnrs__match_num__next(); Type: FUNCTION; Schema: TNRS; Owner: -
16973 16987
--
16974 16988

  
......
17643 17657

  
17644 17658

  
17645 17659
--
17660
-- Name: tnrs__match_num__fill; Type: TRIGGER; Schema: TNRS; Owner: -
17661
--
17662

  
17663
CREATE TRIGGER tnrs__match_num__fill BEFORE INSERT ON tnrs FOR EACH ROW EXECUTE PROCEDURE tnrs__match_num__fill();
17664

  
17665

  
17666
--
17646 17667
-- Name: tnrs_populate_fields; Type: TRIGGER; Schema: TNRS; Owner: -
17647 17668
--
17648 17669

  

Also available in: Unified diff