Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1b1D6I-0002On-Vj for pgadmin-hackers@arkaria.postgresql.org; Fri, 13 May 2016 13:25:55 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1b1D6I-0001PK-IC for pgadmin-hackers@arkaria.postgresql.org; Fri, 13 May 2016 13:25:54 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1b1D63-0001Av-RX for pgadmin-hackers@postgresql.org; Fri, 13 May 2016 13:25:40 +0000 Received: from mail-lf0-x22c.google.com ([2a00:1450:4010:c07::22c]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84_2) (envelope-from ) id 1b1D5z-0003Rw-Lz for pgadmin-hackers@postgresql.org; Fri, 13 May 2016 13:25:38 +0000 Received: by mail-lf0-x22c.google.com with SMTP id u64so88542761lff.3 for ; Fri, 13 May 2016 06:25:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=enterprisedb-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc; bh=FTWdVaN6BkFbjfjAFV8YRnTOdyZIpkLa/74q71O0Jbc=; b=cfVblVxdH6vBG5hjLu6t3S45f4KNI2LbbfPG/ZuwOyzjDsxHrtyR7bcizQRk6mCFjU mXC9gaVi5QBy/WDb0KaNsZ8uN2/upHE3bdfgOq1qGO4mQkVWSdLpULGee4lj8AbWL5RK 6utEqpfca82riBxL7F2jdwTRe9JPH+J4MpdEAkge7vzPPga3M5NEjMa34ytquqcaQsLh vxZT+IqaD5QZzUrDw1eSAWmIGFkmOMIyZ0DQ7B6tE8CvcgWhM2C32USmQI1dGLJvT7p1 ZJoNnwlldOdtgV/owpUQ0jjMTA6uGZaePV0f0RLklaxMurSwCALpRhT4wOrfFNo3AlVv 2ZxA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc; bh=FTWdVaN6BkFbjfjAFV8YRnTOdyZIpkLa/74q71O0Jbc=; b=RKKLU2eeigQNeKNJC324mLSWgNK5XRumdeh5RXvnQGz1coaSY7Vj1UtZ2FdTH6YMgK DTxv93UyO4GGAy44qCo1YpjU/Db8JJGrEcWGJA75LfYVP1vJrWOVmp5eMPNZZyPWFixO 5O2anTinWoiBWUH34TesNtBxyzY2KurTRrgq9ODQ6RvqFPM9JaLF0IVYohS9UaC0KqPi Lq0eH+l9/NsxreNavuPe3wyUHmV9AVVYFk7XH84ur71aNxjSWFHenHKi8KOUy7Ubc5YD t5F7pou7dhXuw9AxIAOE+gKlbB3sHiYUEffCB8ZGJ34MX9mY9fT0TB4P4kpt45fklumx SanQ== X-Gm-Message-State: AOPr4FX4A4wMe1OOAHsZNT/uSf2Tu000Df8RZ3/uzeJQGd0c+HOtBE36pfJ28K6DcwDO4KRh654obVP3ZMxGttCv MIME-Version: 1.0 X-Received: by 10.25.163.15 with SMTP id m15mr6986624lfe.93.1463145933339; Fri, 13 May 2016 06:25:33 -0700 (PDT) Received: by 10.25.206.85 with HTTP; Fri, 13 May 2016 06:25:33 -0700 (PDT) In-Reply-To: References: Date: Fri, 13 May 2016 18:55:33 +0530 Message-ID: Subject: Re: [PATCH] Tables node (pgAdmin4) From: Khushboo Vashi To: Harshal Dhumal Cc: pgadmin-hackers Content-Type: multipart/alternative; boundary=001a114108049c978a0532b93562 X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgadmin-hackers Precedence: bulk Sender: pgadmin-hackers-owner@postgresql.org --001a114108049c978a0532b93562 Content-Type: text/plain; charset=UTF-8 Hi, Review Comments: - Please replace 'can not' with 'cannot' in all the validation messages. - PG 9.1+ Inheritance issue as below: CREATE TABLE public.table1 ( ) ( ) INHERITS (a) WITH ( OIDS = FALSE ) TABLESPACE pg_default; ALTER TABLE public.table1 OWNER to postgres; brackets are coming twice. - Please maintain one line spacing between SQL queries In the SQL Tab. - Foreign Key Grid in Table css issue: Grid columns expands on the selection of the cell - Check Constraint: Validated? option should be True by default - pg 9.4: Exclude constraint does not render in SQL tab - Missing Security validation - Vacuum grid should not be editable in properties mode. - Edit mode, Fill Factor can be allowed to be null. - While dropping inheritance, related table columns drop SQL are also populated in the SQL Tab ALTER TABLE public."Tbl" NO INHERIT b; ALTER TABLE public."Tbl" DROP COLUMN id; ALTER TABLE public."Tbl" DROP COLUMN name; And also render error while clicking on the save button. ERROR: syntax error at or near "[" LINE 2: INHERIT [; ^ - in a Reverse Engineering SQL tab, schema_name.tablename should be there, currently only table_name displays. - Column SQL is showing below text with HTML -- Column: id -- ALTER TABLE public.a DROP COLUMN id; ALTER TABLE public.a ADD COLUMN id integer; - The column datatype dependency does not get cleared upon selection of another datatype. For example, if I select numeric and gives the length and precision. After that I change the dat-type then, dependent fields should be get cleared. - The column datatype does not get displayed in the properties and edit mode if the length and precision are given while creating a column. - Statistics is showing null value even after having value. - if the check constraints are not validated then put proper icon in tree and also it should be validated in edit mode. NOTE: I have not checked the Indexes, Triggers and Rules nodes as I do not have much knowledge about it. Thanks, Khushboo On Fri, May 13, 2016 at 5:24 PM, Harshal Dhumal < harshal.dhumal@enterprisedb.com> wrote: > Hi > > PFA attached patches for table and it's child nodes with python 2.7 > compatibility. > > -- > *Harshal Dhumal* > *Software Engineer * > > > > EenterpriseDB > > On Thu, May 12, 2016 at 6:55 PM, Khushboo Vashi < > khushboo.vashi@enterprisedb.com> wrote: > >> Hi, >> >> I have started reviewing the patch but the basic functionalities are >> breaking on python 2.7. >> Please test the patch on Python 2.7, fix the issues and resend the patch. >> >> Thanks, >> Khushboo >> >> On Thu, May 12, 2016 at 6:03 PM, Harshal Dhumal < >> harshal.dhumal@enterprisedb.com> wrote: >> >>> Hi, >>> >>> >>> -- >>> *Harshal Dhumal* >>> *Software Engineer * >>> >>> >>> >>> EenterpriseDB >>> >>> On Tue, May 10, 2016 at 6:37 PM, Murtuza Zabuawala < >>> murtuza.zabuawala@enterprisedb.com> wrote: >>> >>>> Hi Harshal, >>>> >>>> Pending issues to be fixed which I tried but not able to fix in >>>> Constraints node, >>>> >>> *1)* Adding Primary key in create table mode causes "too much >>>> recursion" error & Column collection validation error. >>>> >>> Fixed. >>> >>> >>>> *2)* MultiSelect2 rendering issue causing window to hang. >>>> >>> Fixed. >>> >>> >>>> >>>> >>>> >>>> >>>> PFA updated patch for table node, >>>> - Added help file names in js. >>>> - Added Deps for primary key cell in create table node >>>> - Corrected validation error messages >>>> - Formatted SQL templates properly >>>> - Added support for View in triggers node >>>> >>>> >>>> Regards, >>>> Murtuza >>>> >>>> -- >>>> Regards, >>>> Murtuza Zabuawala >>>> EnterpriseDB: http://www.enterprisedb.com >>>> The Enterprise PostgreSQL Company >>>> >>>> On Mon, May 9, 2016 at 5:51 PM, Murtuza Zabuawala < >>>> murtuza.zabuawala@enterprisedb.com> wrote: >>>> >>>>> Hi Harshal, >>>>> >>>>> Please find comments as below for constraints node, >>>>> >>>>> 1) Not able to create Primary key due to 'Please provide primary key' >>>>> validation error >>>>> 2) Primary key dialog do not close after save. >>>>> 3) Error "too much recursion" when creating Forgien key from New table. >>>>> 4) Error "too much recursion" when creating Check constraint from New >>>>> table. >>>>> 5) Remove console.log from JS (Unique constraint) >>>>> 6) Unique & Exclude constraint are also not working in create mode, No >>>>> SQL is generated in create mode >>>>> 7) If there are no columns on table select2 shows columns of >>>>> previously fetched objects columns. >>>>> >>>>> >>>>> >>>>> Also attaching new updated patch, which will fixes below issues, >>>>> Fixed: >>>>> ===== >>>>> 1) Do not show Foreign tables under tables node >>>>> 2) In trigger node changed select2 control options as per new format. >>>>> 3) Removed unwanted templates from trigger node >>>>> 4) clean up some unwanted code from trigger node >>>>> 5) Fixed Create sql template in index node >>>>> >>>>> >>>>> Regards, >>>>> Murtuza >>>>> >>>>> -- >>>>> Regards, >>>>> Murtuza Zabuawala >>>>> EnterpriseDB: http://www.enterprisedb.com >>>>> The Enterprise PostgreSQL Company >>>>> >>>>> On Sat, May 7, 2016 at 7:45 PM, Harshal Dhumal < >>>>> harshal.dhumal@enterprisedb.com> wrote: >>>>> >>>>>> Hi, >>>>>> >>>>>> Please find below responses. >>>>>> >>>>>>> >>>>>>> Please find the review comments so far: >>>>>>> >>>>>>> 1. On the Table Collection node, The fields in the grid should be >>>>>>> Name, Owner and Comments. OID is not required. Please follow same for the >>>>>>> other Nodes like Index, Constraints etc. >>>>>>> >>>>>> >>>>>> Fixed >>>>>> >>>>>>> 2. While Updating the Table, Add any column as well as Inherits any >>>>>>> table, then the check the SQL tab. >>>>>>> ALTER TABLE SQL should be come in the new line >>>>>>> >>>>>>> *Current SQL Tab:* >>>>>>> >>>>>>> ALTER TABLE pem.agent_heartbeat >>>>>>> INHERIT pem.alert_history;ALTER TABLE pem.agent_heartbeat >>>>>>> ADD COLUMN test bigint; >>>>>>> >>>>>> Fixed >>>>>> >>>>>> >>>>>>> 3. While Creating/updating table, if the Schema is other than >>>>>>> selected one, then after saving the table, it is not falling under the same >>>>>>> schema. And also in update mode it gives an error. >>>>>>> >>>>>> TODO >>>>>> >>>>>> >>>>>>> 4. Unlogged setting does not honor the change of value. >>>>>>> >>>>>> Not reproducible. >>>>>> >>>>>> >>>>>>> 5. Please Check SQL tab for all the Nodes as most of them having >>>>>>> problem of No blank lines/More than one Blank Lines/Blank Lines at the end >>>>>>> etc. >>>>>>> >>>>>> Fixed >>>>>> >>>>>> >>>>>>> 6. Creating Table with auto_vacuum and updating only one field then >>>>>>> wrong SQL is generated. >>>>>>> WITH ( >>>>>>> OIDS = TRUE, >>>>>>> FILLFACTOR = 12, >>>>>>> autovacuum_enabled = TRUE, >>>>>>> , >>>>>>> autovacuum_vacuum_cost_delay = 21 >>>>>>> ) >>>>>>> >>>>>>> Fixed. >>>>>> >>>>>> >>>>>>> 7. Same as toast >>>>>>> WITH ( >>>>>>> OIDS = TRUE, >>>>>>> FILLFACTOR = 12, >>>>>>> autovacuum_enabled = TRUE, >>>>>>> toast.autovacuum_enabled = TRUE, >>>>>>> autovacuum_analyze_scale_factor = 1, >>>>>>> autovacuum_analyze_threshold = 2, >>>>>>> autovacuum_freeze_max_age = 2, >>>>>>> , >>>>>>> toast.autovacuum_vacuum_cost_limit = 2, >>>>>>> toast.autovacuum_freeze_min_age = 4 >>>>>>> ) >>>>>>> >>>>>> Fixed >>>>>> >>>>>> >>>>>>> >>>>>>> 8. Sometimes while creating table and checking sql table, below >>>>>>> error is coming >>>>>>> >>>>>>> File >>>>>>> "/home/khushboo/Projects/pgadmin4/web/pgadmin/browser/server_groups/servers/databases/schemas/tables/__init__.py", >>>>>>> line 1060, in properties >>>>>>> data = res['rows'][0] >>>>>>> IndexError: list index out of range >>>>>>> >>>>>> TODO. (Need exact steps to reproduce.) >>>>>> >>>>>> >>>>>>> >>>>>>> 9. Please check all the Grid table columns. It should not be >>>>>>> expanded while editing directly into the grid. For ref: Check constraint >>>>>>> grid >>>>>>> >>>>>> TODO >>>>>> >>>>>> >>>>>> >>>>>>> >>>>>>> 10. Constraint Nodes are not covered yet due to validation issue on >>>>>>> which Harshal is working. >>>>>>> >>>>>> Done. >>>>>> >>>>>> >>>>>>> >>>>>>> 11. While creating the table if auto-vacuume has been enabled by >>>>>>> user, then it should stay enabled in Edit mode also. Currently it is not. >>>>>>> >>>>>> Fixed >>>>>> >>>>>> >>>>>> >>>>>>> 12 .If I just enable 'custom auto activated' and don't update >>>>>>> anything then SQL tab is generating below SQL which is wrong. >>>>>>> >>>>>>> ALTER TABLE pem.khushboo1 SET ( >>>>>>> >>>>>>> ); >>>>>>> >>>>>> Fixed >>>>>> >>>>>> >>>>>>> >>>>>>> 13. IF I Change privileges from pem_agent to agent1 then the SQL i >>>>>>> like below, which is not corrent >>>>>>> >>>>>>> REVOKE ALL ON TABLE pem.khushboo1 FROM agent1; >>>>>>> GRANT SELECT ON TABLE pem.khushboo1 TO agent1; >>>>>>> >>>>>> >>>>>> Not reproducible Or please provide steps to reproduce. >>>>>> >>>>>> >>>>>> >>>>>>> 14. In check constraint, change "Don't Validate" to Validated? >>>>>>> Please refer Domain Constraint for the same. >>>>>>> >>>>>> Fixed. >>>>>> >>>>>> >>>>>>> >>>>>>> 15. SQL for the Column is coming as below, which is not correct. >>>>>>> >>>>>>> -- Column: col3 -- ALTER TABLE >>>>>>> pem.khushboo1 DROP COLUMN col3; ALTER TABLE pem.khushboo1 ADD COLUMN col3 >>>>>>> integer NOT NULL; >>>>>>> >>>>>> >>>>>> Not reproducible Or please provide steps to reproduce. >>>>>> >>>>>> >>>>>> >>>>>>> >>>>>>> 16. While updating table columns from column node. Below SQL >>>>>>> generating an error. >>>>>>> >>>>>>> ALTER TABLE pem.khushboo1 >>>>>>> ALTER COLUMN col2 numeric(1, 1); >>>>>>> >>>>>> Fixed >>>>>> >>>>>> >>>>>>> >>>>>>> 17. After deleting any column, the properties of the another column >>>>>>> of the same table doesn't show up. Gives below error. >>>>>>> >>>>>>> TypeError: self.canDrop.apply is not a function >>>>>>> >>>>>>> ...lf.canDrop) ? function() { return self.canDrop.apply(self, >>>>>>> arguments); } : fals >>>>>>> >>>>>> >>>>>> This issue is already raised. >>>>>> >>>>>> >>>>>>> 18. Table Node : Exclusion constraint : Grid validates DESC instead >>>>>>> of operator. >>>>>>> >>>>>> >>>>>> Not reproducible. >>>>>> >>>>>> >>>>>>> >>>>>>> 19. Please check validation of the Exclusion control, as some JS >>>>>>> error is coming and due to this, we can not close the dialogue. >>>>>>> >>>>>>> The select2('destroy') method was called on an element that is >>>>>>> not using Select2. >>>>>>> >>>>>>> >>>>>>> ...this.$dropdown.on(d.join(" >>>>>>> "),function(a){a.stopPropagation()})},a}),b.define("s... >>>>>>> >>>>>>> select2....min.js (line 3) >>>>>>> TypeError: c is undefined >>>>>>> >>>>>> >>>>>> This is already fixed. >>>>>> >>>>>> >>>>>>> >>>>>>> 20. While updating the comments field of the Index node, it throws >>>>>>> below error: >>>>>>> >>>>>>> TypeError: obj is null >>>>>>> >>>>>>> } else if ((obj.sessChanged && obj.sessChanged()) || isNew) { >>>>>>> >>>>>> >>>>>> This is already fixed. >>>>>> >>>>>> >>>>>> >>>>>>> 21. Job Trigger : Validation missing, so user can't get an idea what >>>>>>> is missing while checking the SQL tab >>>>>>> >>>>>> >>>>>> Fixed. >>>>>> >>>>>> >>>>>>> 22. For the reverse Engineering SQL tab, the constraints should be >>>>>>> start with Schema.Table.Constraint. Please follow same path for all the >>>>>>> nodes. >>>>>>> >>>>>> >>>>>> I cross checked with pgadmin3. Reverse Engineering SQL looks good to >>>>>> me. Please let me know what is missing? >>>>>> >>>>>> >>>>>>> 23. Indexes : Comments can not be updated. Please check the attached >>>>>>> screen-shot for reference. >>>>>>> >>>>>> Fixed >>>>>> >>>>>> >>>>>>> 24. Spelling mistake of 'Definition' in Indexes. >>>>>>> >>>>>> >>>>>> Fixed >>>>>> >>>>>>> >>>>>>> NOTE: I haven't check Constraints properly due to validation issue. >>>>>>> Also I have checked only functional flow, I will review the code today >>>>>>> evening or tomorrow. >>>>>>> >>>>>>> >>>>>>> Thanks, >>>>>>> Khushboo >>>>>>> >>>>>>> >>>>>>> >>>>>>> On Wed, Apr 27, 2016 at 2:52 PM, Harshal Dhumal < >>>>>>> harshal.dhumal@enterprisedb.com> wrote: >>>>>>> >>>>>>>> Hi, >>>>>>>> >>>>>>>> PFA attached patches for table node and all table child nodes. >>>>>>>> >>>>>>>> This patch includes below nodes, >>>>>>>> >>>>>>>> 1) Table node *-- Initial patch by >>>>>>>> Murtuza, constraints compatibility by Harshal. * >>>>>>>> 2) Column node *-- by Murtuza. * >>>>>>>> 3) Index node *-- by Murtuza. * >>>>>>>> 4) Trigger node *-- by Murtuzz. * >>>>>>>> 6) Rules node >>>>>>>> *-- by Surinder.* >>>>>>>> 7) Constraints nodes: >>>>>>>> i] Index Constraint *-- Initial patch by >>>>>>>> Harshal, Integration with table node by **Murtuza.* >>>>>>>> ii] Foreign key *-- Initial patch and >>>>>>>> Integration with table node by Harshal**.* >>>>>>>> iii] Check constraint *-- Initial patch and >>>>>>>> Integration with table node by Harshal**.* >>>>>>>> iv] Exclusion constraint *-- Initial patch and >>>>>>>> Integration with table node by Harshal**.* >>>>>>>> >>>>>>>> Please apply patches in following order as all of them depends on >>>>>>>> each other. >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> *Order: Table Node ----> Index constraint ---> remaining patches >>>>>>>> in any order.* >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> -- >>>>>>>> *Harshal Dhumal* >>>>>>>> *Software Engineer * >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> EenterpriseDB >>>>>>>> >>>>>>>> On Mon, Apr 18, 2016 at 7:04 PM, Murtuza Zabuawala < >>>>>>>> murtuza.zabuawala@enterprisedb.com> wrote: >>>>>>>> >>>>>>>>> Hi, >>>>>>>>> >>>>>>>>> Please find initial patch for tables node. >>>>>>>>> >>>>>>>>> This patch includes below nodes, >>>>>>>>> >>>>>>>>> 1) Tables node >>>>>>>>> 2) Columns node >>>>>>>>> 3) Index node >>>>>>>>> 4) Trigger node >>>>>>>>> 5) Constraints node (Primary key & Unique constraints only) *-- >>>>>>>>> From: Harshal* >>>>>>>>> 6) Roles node >>>>>>>>> *-- From: Surinder* >>>>>>>>> >>>>>>>>> This patch also includes "VacuumSettings control" required by >>>>>>>>> table node. >>>>>>>>> >>>>>>>>> Please apply Fieldset Control UI patch sent earlier. >>>>>>>>> >>>>>>>>> >>>>>>>>> *Please note that constraint node is still partial, It has Primary >>>>>>>>> Key & Unique constraint working & integrated in tables node.* >>>>>>>>> >>>>>>>>> 1) I have used initial patch of index constraints node from >>>>>>>>> Harshal & further extend it it to work with table node. >>>>>>>>> [ Harshal will integrate rest of constraints in tables node, he is >>>>>>>>> working on it.] >>>>>>>>> >>>>>>>>> 2) I have also used initial patches of rules node and >>>>>>>>> VacuumSettings control from Surinder & further extend them it to work with >>>>>>>>> table node. >>>>>>>>> >>>>>>>>> >>>>>>>>> -- >>>>>>>>> Regards, >>>>>>>>> Murtuza Zabuawala >>>>>>>>> EnterpriseDB: http://www.enterprisedb.com >>>>>>>>> The Enterprise PostgreSQL Company >>>>>>>>> >>>>>>>>> >>>>>>>>> -- >>>>>>>>> Sent via pgadmin-hackers mailing list ( >>>>>>>>> pgadmin-hackers@postgresql.org) >>>>>>>>> To make changes to your subscription: >>>>>>>>> http://www.postgresql.org/mailpref/pgadmin-hackers >>>>>>>>> >>>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> -- >>>>>>>> Sent via pgadmin-hackers mailing list ( >>>>>>>> pgadmin-hackers@postgresql.org) >>>>>>>> To make changes to your subscription: >>>>>>>> http://www.postgresql.org/mailpref/pgadmin-hackers >>>>>>>> >>>>>>>> >>>>>>> >>>>>> >>>>> >>>> >>> >> > > > -- > Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) > To make changes to your subscription: > http://www.postgresql.org/mailpref/pgadmin-hackers > > --001a114108049c978a0532b93562 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi,

Review Comments:

- Please replace 'can not' with 'cannot' =C2=A0= in all the validation messages.
- PG 9.1+ Inheritance issue as be= low:
CREATE TABLE public.table1
<= div>(
)
(
)
=C2=A0 =C2= =A0 INHERITS (a)
WITH (
=C2=A0 =C2=A0 OIDS =3D FALSE
)=
TABLESPACE pg_default;
ALTER TABLE public.table1
=C2= =A0 =C2=A0 OWNER to postgres;
brackets are coming twice.

- Plea= se maintain one line spacing between SQL queries In the SQL Tab.
= - Foreign Key Grid in Table css issue: Grid columns expands on the selectio= n of the cell
- Check Constraint: Validated? option should be= True by default
- pg 9.4: Exclude constraint does not render in = SQL tab
- Missing Security validation
- Vacuum grid sho= uld not be editable in properties mode.
- Edit mode, Fill Factor = can be allowed to be null.
- While dropping inheritance, related = table columns drop SQL are also populated in the SQL Tab
ALTE= R TABLE public."Tbl"
=C2=A0 =C2=A0 NO INHERI= T b;
ALTER TABLE public."Tbl" DROP COLUMN id= ;
ALTER TABLE public."Tbl" DROP COLUMN name;=

And also render error whi= le clicking on the save button.
ERROR: syntax error at or near &q= uot;["
LINE 2: INHERIT [;
^<= /div>
- in a Reverse Engineering SQL tab, schem= a_name.tablename should be there, currently only table_name displays.
=
- Column SQL is showing below text with HTML

<html><head></head><body>-- Column: id -= - ALTER TABLE public.a DROP COLUMN id; ALTER TABLE public.a ADD COLUMN id i= nteger;</body></html>
- The c= olumn datatype dependency does not get cleared upon selection of another da= tatype.
=C2=A0For example, if I select numeric and gives the leng= th and precision. After that I change the dat-type then, dependent fields s= hould be get cleared.

- The column datatype does n= ot get displayed in the properties and edit mode if the length and precisio= n are given while creating a column.=C2=A0

- Stati= stics is showing null value even after having value.=C2=A0

- if the check constraints are not validated then put proper icon = in tree and also it should be validated in edit mode.

<= div>NOTE: I have not checked the Indexes, Triggers and Rules nodes as I do = not have much knowledge about it.

Thanks,
Khushboo

On Fri, May 13, 2016 at 5:24 PM, Harshal Dhumal <= harshal.dhumal@enterprisedb.com> wrote:
Hi

PFA attached patches fo= r table and it's child nodes with python 2.7 compatibility.

--=C2=A0
Harshal Dhumal=
Software Engineer=C2=A0




On Thu, May 12= , 2016 at 6:55 PM, Khushboo Vashi <khushboo.vashi@enterprise= db.com> wrote:
Hi,

I have started reviewing the patc= h but the basic functionalities are breaking on python 2.7.
Please= test the patch on Python 2.7, fix the issues and resend the patch.

=
Thanks,
Khushboo

On Thu, May 12, 2016 at 6:03 PM, Harshal = Dhumal <harshal.dhumal@enterprisedb.com> wrote= :
=C2=A0
2) MultiSelect2 rendering issue causing window= to hang.
Fixed.
=
=C2=A0

=


<= /div>
PFA updated patch for table node,=C2=A0
- Added help fi= le names in js.
- Added Deps for primary key cell in create t= able node
- Corrected validation error messages
- Forma= tted SQL templates properly =C2=A0
- Added support for View in tr= iggers node


Regards,
Murt= uza


On Mon, May 9, 2016 at 5:51= PM, Murtuza Zabuawala <murtuza.zabuawala@enterprisedb.co= m> wrote:
=
Hi Harshal,

Please find comments as below for= constraints node,

1) Not able to create Primary k= ey due to 'Please provide primary key' validation error
2= ) Primary key dialog do not close after save.
3) Error "too = much recursion" when creating Forgien key from New table.
4)= Error "too much recursion" when creating Check constraint from N= ew table.
5) Remove console.log from JS (Unique constraint)
=
6) Unique & Exclude constraint are also not working in create mode= , No SQL is generated in create mode
7) If there are no columns o= n table select2 shows columns of previously fetched objects columns.
<= div>


Also attaching new up= dated patch, which will fixes below issues,
Fixed:
=3D= =3D=3D=3D=3D
1) Do not show Foreign tables under tables node
2) In trigger node changed select2 control options as per new format.= =C2=A0
3) Removed unwanted templates from trigger node
= 4) clean up some unwanted code from trigger node
5) Fixed Create = sql template in index node


Re= gards,
Murtuza

--
Re= gards,
Murtuza Zabuawala
EnterpriseDB:=C2=A0http://www.enterprisedb.com
The Enterprise= PostgreSQL Company

On Sat, May 7, 2016 at 7:45 PM, Harshal Dhum= al <harshal.dhumal@enterprisedb.com> wrote:
Hi,

Ple= ase find below responses.=C2=A0

Please find t= he review comments so far:

1. On the Table=20 Collection node, The fields in the grid should be Name, Owner and=20 Comments. OID is not required. Please follow same for the other Nodes=20 like Index, Constraints etc.

Fixed=C2=A0
= 2. While Updating the Table, Add any column as well as Inherits any table, = then the check the SQL tab.
ALTER TABLE SQL should be come in the = new line

Current SQL Ta= b:

ALTER TABLE pem.agent_heartbeat
=C2=A0=C2=A0=C2=A0 INHERIT= pem.alert_history;ALTER TABLE pem.agent_heartbeat
=C2=A0=C2=A0=C2=A0 AD= D COLUMN test bigint;
Fixed
=C2=A0
3. While Creating/updating table, if the Schema is other than selected=20 one, then after saving the table, it is not falling under the same=20 schema. And also in update mode it gives an error.
TODO
=C2=A0
4. Unlogged setting does not honor the change of value.
Not reproducible.
=C2=A0
5. Please Check SQL tab for all the Nodes as most of them having problem=20 of No blank lines/More than one Blank Lines/Blank Lines at the end etc.
=
Fixed
=C2=A0
6. Creating Table with=C2=A0 au= to_vacuum and updating only one field then wrong SQL is generated.
WITH (
=C2=A0=C2=A0=C2=A0 OIDS =3D TRUE= ,
=C2=A0=C2=A0=C2=A0 FILLFACTOR =3D 12,
=C2=A0=C2=A0=C2=A0 aut= ovacuum_enabled =3D TRUE,
,
=C2=A0=C2=A0=C2=A0 autovacuum_vacuum_cost= _delay =3D 21
)

Fixed.<= /div>
=C2=A0
7. Same as toast
WITH (
=C2=A0=C2= =A0=C2=A0 OIDS =3D TRUE,
=C2=A0=C2=A0=C2=A0 FILLFACTOR =3D 12,=C2=A0=C2=A0=C2=A0 autovacuum_enabled =3D TRUE,
=C2=A0=C2=A0=C2=A0 toas= t.autovacuum_enabled =3D TRUE,
=C2=A0=C2=A0=C2=A0 autovacuum_analyze_sca= le_factor =3D 1,
=C2=A0=C2=A0=C2=A0 autovacuum_analyze_threshold =3D 2,<= br>=C2=A0=C2=A0=C2=A0 autovacuum_freeze_max_age =3D 2,
,
=C2=A0=C2=A0= =C2=A0 toast.autovacuum_vacuum_cost_limit =3D 2,
=C2=A0=C2=A0=C2=A0 toas= t.autovacuum_freeze_min_age =3D 4
)
Fixed
=C2=A0
=
8. Sometimes while creating table and checking sql table, be= low error is coming

=C2=A0 File=20 "/home/khushboo/Projects/pgadmin4/web/pgadmin/browser/server_groups/se= rvers/databases/schemas/tables/__init__.py", line 1060, in properties
=C2=A0=C2=A0=C2=A0 data =3D res['rows'= ][0]
IndexError: list index out of range
TODO. (Need exact steps to reproduce.)
=C2=A0

9. Please check all the Grid table columns. It should not be expanded=20 while editing directly into the grid. For ref: Check constraint grid
TODO

=C2=A0
=

10. Constraint N= odes are not covered yet due to validation issue on which Harshal is workin= g.
Done.
=C2=A0

11. While creating the table if auto-vacuume has been enabled by user, then it should stay enabled in Edit mode also. Currently it is not.
Fixed
=C2=A0
=C2=A0
12 .If I just enable 'custom = auto activated' and don't update anything then SQL tab is generatin= g below SQL which is wrong.

ALTER TABLE pem.khushboo1 SET (

)= ;
Fixed
=C2=A0

13. IF I Change privileges from p= em_agent to agent1 then the SQL i like below, which is not corrent

R= EVOKE ALL ON TABLE pem.khushboo1 FROM agent1;
GRANT SELECT ON TABLE pem.= khushboo1 TO agent1;
=C2=A0
Not reproducible Or please provide steps to reproduce.

=
=C2=A0
14. In c= heck constraint, change "Don't Validate" to Validated? Please= refer Domain Constraint for the same.
Fixed.
=C2=A0

15. SQL for the Column is coming as below, which is not correct.
<html><head></head><body>-- Column: col3 -- ALTER TABLE pem.khushboo1 DROP COLUMN col3; ALTER TABLE pem.khushboo1 ADD COLUMN col3 integer NOT=20 NULL;</body></html>

=
Not reproducible Or please provide steps to reproduce.
=

=C2=A0

16. While updating table columns from column node. Below SQL generati= ng an error.

ALTER TABLE pem.khushboo1
=C2=A0=C2=A0=C2=A0 ALTER C= OLUMN col2 numeric(1, 1);
Fixed
=C2=A0

17. After= deleting any column, the properties of the another column of the same tabl= e doesn't show up. Gives below error.

TypeError: self.canDrop.ap= ply is not a function
=C2=A0=C2=A0
...lf.canDrop) ? function() { ret= urn self.canDrop.apply(self, arguments); } : fals
=C2=A0
This issue is already raised.=C2=A0


18.=C2=A0 T= able Node : Exclusion constraint : Grid validates DESC instead of=C2=A0 ope= rator.

Not reproducib= le.
=C2=A0
<= br>
19. Please check validation of the Exclusion control, as some JS error is=20 coming and due to this, we can not close the dialogue.

<= div style=3D"margin-left:40px">=C2=A0=C2=A0=C2=A0 The select2('destroy&= #39;) method was called on an element that is not using Select2.
=C2=A0= =C2=A0=C2=A0

...this.$dropdown.on(d.join(" "),function(a)= {a.stopPropagation()})},a}),b.define("s...

select2....min.js (l= ine 3)
TypeError: c is undefined

This is already = fixed.
=C2=A0

20. While updating the comments fie= ld of the Index node, it throws below error:

TypeError: obj is null
=C2=A0=C2=A0=C2=A0
} else if ((obj.s= essChanged && obj.sessChanged()) || isNew) {
<= /div>

This is already fixed.
=
=C2=A0
21. Job Trigger : Validation m= issing, so user can't get an idea what is missing while checking the SQ= L tab

Fixed.
=C2=A0
22. For the reverse Engineering SQL tab, the constraints should be start=20 with Schema.Table.Constraint. Please follow same path for all the nodes.

I cross checked with pg= admin3. Reverse Engineering SQL looks good to me. Please let me know what i= s missing?
=C2=A0
23. Indexes : Comments can not be updated. Please check the attached scre= en-shot for reference.
Fixed
=C2=A0
24. Spelling mis= take of 'Definition' in Indexes.
=

Fixed=C2=A0

NOTE: I haven't check Constraints properly due to validation issue. Also I= =20 have checked only functional flow, I will review the code today evening=20 or tomorrow.


Thanks,
Khushbo= o



On Wed, Apr 27, 2016 at 2:52 PM, Harshal Dhu= mal <harshal.dhumal@enterprisedb.com> wrote:
Hi= ,

PFA attached patches for table node and all table child node= s.

This patch includes below nodes,

<= /span>
1) Table node=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 -- Initial patch by M= urtuza, constraints compatibility by Harshal. =
2) Column node=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 --=C2=A0by Murtuza. <= /span>
3) Index node=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 --=C2=A0by Murt= uza.
4) Trigger node=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 -- by = Murtuzz.
6) Rules node =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0=C2=A0 -- by Surinder.
7) Constrain= ts nodes:
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 i]=C2=A0 Index Constraint= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0 -- Initial patch by Harshal, Integration wit= h table node by Murtuza.
= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ii] Foreign key=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 -- Initial patch and Integration wit= h table node by Harshal.
<= div>=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 iii] Check constraint=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 = -- Initial patch and Integration with table node by Harshal.
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 iv]= Exclusion constraint=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0 -- Initial patch and Integration with table node by Harshal= .

Pleas= e apply patches in following order as all of them depends on each other.
Order:=C2=A0 Table Node ----> Index constraint --->= ; remaining patches in any order.


=C2=A0




--=C2=A0
Harshal Dhumal
Software Engineer= =C2=A0



<= /div>

On Mon, Apr 18, 2016 at 7:04 PM, M= urtuza Zabuawala <murtuza.zabuawala@enterprisedb.com&= gt; wrote:
Hi,

Please find initial patch for tables node.

This patch includes below nodes,

1) Tables node
2) Columns node
3) Index node
4) Trigger node
5) Constraints node (Primary key & Unique co= nstraints only) =C2=A0 =C2=A0-- From: Harshal
6) Roles node =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0-- From: Surinder

T= his patch also includes "VacuumSettings control" required by tabl= e node.

Please apply Fieldset Control UI patch sen= t earlier.


Please note that constraint node is still partial, It has Primary Key = & Unique constraint working & integrated in tables node.
<= div>
1) =C2=A0I have used ini= tial patch of index constraints=C2=A0node from Harshal & further extend= it it to work with table node.
[ Harshal will integrate rest of constraints i= n tables node, he is working on it.]

2) I have also used initial patches of rule= s node and VacuumSettings control from Surinder & further extend them i= t to work with table node.


--
Regards= ,
Murtuza Zabuawala
= EnterpriseDB:=C2=A0http://www.enterprisedb.com
The Enterprise Post= greSQL Company



=
--
Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers=


=

--
Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers=



<= /span>






--
Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers=


--001a114108049c978a0532b93562--