Reverse change to v4_0_postgres_views.sql

Further view code restructuring to follow
Hash partitioning testing. Problems with missing objects

psql:../psql_scripts/v4_0_study_id_partitions.sql:145: WARNING:
rif40_ddl(): SQL in error (42P01)> ALTER TABLE
rif40.t_rif40_study_sql_p1 ADD CONSTRAINT t_rif40_study_sql_p1_sid_l
ine_fk FOREIGN KEY (study_id, statement_number) REFERENCES
t_rif40_study_sql_p1_log(study_id, statement_number);
psql:../psql_scripts/v4_0_study_id_partitions.sql:145: ERROR:  relation
"t_rif40_study_sql_p1_log" does not exist