Advertisement
tmerry

Untitled

Jan 19th, 2017
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.31 KB | None | 0 0
  1. <changeSet id="20170118_00.16" author="tmerry">
  2.  
  3. <comment>
  4. create table pr_balancing16
  5. </comment>
  6.  
  7. <createSequence schemaName="public"
  8. sequenceName="pr_balancing16_cp_id_seq"/>
  9.  
  10. <sql>
  11. alter table public.pr_balancing16_cp_id_seq
  12. owner to postgres;
  13. </sql>
  14.  
  15. <sql>
  16. grant select, update on table
  17. public.pr_balancing16_cp_id_seq to public;
  18. </sql>
  19.  
  20. <sql>
  21. create table private.pr_balancing16 (
  22. cp_id integer primary care not null default
  23. nextval('public.pr_balancing16_cp_id_seq'::text),
  24. person_id integer,
  25. location_id integer,
  26. jobs_id integer,
  27. earn_rate_id integer, <!-- rate type -->
  28. rate numeric(10,4),
  29. first_pay integer,
  30. last_pay integer,
  31. number_of_pays integer,
  32. active boolean default True,
  33. constraint pr_balancing16_person_id_fkey foreign key (person_id)
  34. references personid (person_id) match simple
  35. on update no action on delete no action,
  36. constraint pr_balancing16_jobs_id_fkey foreign key (jobs_id)
  37. references jobs (cp_id) match simple
  38. on update no action on delete no action,
  39. constraint pr_balancing16_earn_rate_id_fkey
  40. foreign key (earn_rate_id)
  41. references lk_earn_rate_code (cp_id) match simple
  42. on update no action on delete no action
  43. );
  44. </sql>
  45.  
  46. <sql>
  47. alter table private.pr_balancing16 own to veil_owner;
  48. </sql>
  49.  
  50. <sql>
  51. comment on table private.pr_balancing16 is
  52. 'i_have_global_priv(%s)';
  53. </sql>
  54.  
  55. </changeSet>
  56.  
  57. <changeSet id="20170118_01.16" author="tmerry">
  58.  
  59. <comment>
  60. create table pr_balancing_detail16
  61. </comment>
  62.  
  63. <createSequence schemaName="public"
  64. sequenceName="pr_balancing_detail16_cp_id_seq"/>
  65.  
  66. <sql>
  67. alter table public.pr_balancing_detail16_cp_id_seq
  68. owner to postgres;
  69. </sql>
  70.  
  71. <sql>
  72. grant select, update on table
  73. public.pr_balancing_detail16_cp_id_seq to public;
  74. </sql>
  75.  
  76. <sql>
  77. create table private.pr_balancing_detail16 (
  78. cp_id integer primary care not null default
  79. nextval('public.pr_balancing_detail16_cp_id_seq'::text),
  80. master_id integer,
  81. person_id integer,
  82. location_id integer,
  83. jobs_id integer,
  84. earn_rate_id integer, <!-- rate type -->
  85. rate numeric(10,4),
  86. first_pay integer,
  87. last_pay integer,
  88. number_of_pays,
  89. hours numeric(14,4),
  90. adjustment numeric(14.4),
  91. comment text,
  92. constraint pr_balancing_detail16_master_id_fkey
  93. foreign key (master_id)
  94. references pr_balancing16 (cp_id) match simple
  95. on update no action on delete no action,
  96. constraint pr_balancing_detail16_person_id_fkey
  97. foreign key (person_id)
  98. references personid (person_id) match simple
  99. on update no action on delete no action,
  100. constraint pr_balancing_detail16_jobs_id_fkey
  101. foreign key (jobs_id)
  102. references jobs (cp_id) match simple
  103. on update no action on delete no action,
  104. constraint pr_balancing_detail16_earn_rate_id_fkey
  105. foreign key (earn_rate_id)
  106. references lk_earn_rate_code (cp_id) match simple
  107. on update no action on delete no action
  108. );
  109. </sql>
  110.  
  111. <sql>
  112. alter table private.pr_balancing_detail16 own to veil_owner;
  113. </sql>
  114.  
  115. <sql>
  116. comment on table private.pr_balancing_detail16 is
  117. 'i_have_global_priv(%s)';
  118. </sql>
  119.  
  120. </changeSet>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement