From: Masataka S. <pg...@gm...> - 2013-08-01 07:35:26
|
I apologize to sent my review to Abbas directly. Latest patch Abbas wrote attached, and I think it goes well. On Tue, Jul 30, 2013 at 2:54 PM, Abbas Butt <abb...@en...> wrote: > Thanks, please find the updated patch attached. > > > On Tue, Jul 30, 2013 at 7:26 AM, Masataka Saito <pg...@gm...> wrote: >> >> On Tue, Jul 30, 2013 at 9:04 AM, Abbas Butt <abb...@en...> >> wrote: >>> >>> >>> then wouldn't it be better to change it to >>> private String createBitTab = "create temp table bit_tab ( max_val >>> boolean, min_val boolean, null_val boolean )"; >>> and then do >>> if (TestUtil.isPGXC()) >>> { >>> createBitTab = createBitTab + " DISRIBUTE BY ROUNDROBIN"; >>> } >>> This obviously removes final but keeps that patch easily portable to a >>> future newer version of JDBC. >>> And for the same reason I used the trick to omit semi colon. >>> What do you think? >> >> >> I know my idea is too forceful and I feel I was too sticked to keep >> original and to close SQLs. >> >> You are right. >> It is reasonable to eliminate "final" with annotation and append >> "DISTRIBUTE BY" clause in setUp method. >> >>> >>> >>>> >>>> A line is dropped in previous mail. This is the complete version. >>>> > private final String createBitTab; >>>> > class TempBitTab { > private final String createBitTab = "create temp >>>> > table bit_tab ( max_val boolean, min_val boolean, null_val boolean )"; > >>>> > public String getSQL() { > String sql; > if (TestUtil.isPGXC()) { > sql = >>>> > this.createBitTab + " DISRIBUTE BY ROUNDROBIN"; > } else { > sql = >>>> > this.createBitTab; > } > return sql; > } > } > > public >>>> > CallableStatementTest() { > createBitTab = new TempBitTab().getSQL(); > } >>>> >>>> >>>> On Mon, Jul 29, 2013 at 9:05 PM, Abbas Butt >>>> <abb...@en...> wrote: >>>>> >>>>> Thanks for your review. >>>>> Yes we can use this technique but the trick I used only omits semicolon >>>>> in the original code which I think would be OK. >>>>> >>>>> >>>>> >>>>> On Mon, Jul 29, 2013 at 4:59 PM, Masataka Saito <pg...@gm...> >>>>> wrote: >>>>>> >>>>>> My comments are follow >>>>>> >>>>>> * org.postgresql.test.jdbc3.Jdbc3CallableStatementTest >>>>>> I don't have great idea for overriding the final SQL, but I can >>>>>> propose next code as a last-ditch measure. >>>>>> > class TempBitTab { > private final String createBitTab = "create >>>>>> > temp table bit_tab ( max_val boolean, min_val boolean, null_val boolean )"; >>>>>> > > public String getSQL() { > String sql; > if (TestUtil.isPGXC()) { > sql = >>>>>> > this.createBitTab + " DISRIBUTE BY ROUNDROBIN"; > } else { > sql = >>>>>> > this.createBitTab; > } > return sql; > } > } > > public >>>>>> > CallableStatementTest() { > createBitTab = new TempBitTab().getSQL(); > } >>>>>> >>>>>> >>>>>> On Fri, Jul 26, 2013 at 10:32 PM, Abbas Butt >>>>>> <abb...@en...> wrote: >>>>>>> >>>>>>> Hi, >>>>>>> In order to avoid the limitation that partition column cannot be >>>>>>> updated I changed table distribution to round robin. >>>>>>> The patch is attached. >>>>>>> >>>>>>> -- >>>>>>> Abbas >>>>>>> Architect >>>>>>> >>>>>>> Ph: 92.334.5100153 >>>>>>> Skype ID: gabbasb >>>>>>> www.enterprisedb.com >>>>>>> >>>>>>> Follow us on Twitter >>>>>>> @EnterpriseDB >>>>>>> >>>>>>> Visit EnterpriseDB for tutorials, webinars, whitepapers and more >>>>>>> >>>>>>> >>>>>>> ------------------------------------------------------------------------------ >>>>>>> See everything from the browser to the database with AppDynamics >>>>>>> Get end-to-end visibility with application monitoring from >>>>>>> AppDynamics >>>>>>> Isolate bottlenecks and diagnose root cause in seconds. >>>>>>> Start your free trial of AppDynamics Pro today! >>>>>>> >>>>>>> http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk >>>>>>> _______________________________________________ >>>>>>> Postgres-xc-developers mailing list >>>>>>> Pos...@li... >>>>>>> https://lists.sourceforge.net/lists/listinfo/postgres-xc-developers >>>>>>> >>>>>> >>>>> >>>>> >>>>> >>>>> -- >>>>> -- >>>>> Abbas >>>>> Architect >>>>> >>>>> Ph: 92.334.5100153 >>>>> Skype ID: gabbasb >>>>> www.enterprisedb.com >>>>> >>>>> Follow us on Twitter >>>>> @EnterpriseDB >>>>> >>>>> Visit EnterpriseDB for tutorials, webinars, whitepapers and more >>>> >>>> >>> >>> >>> >>> -- >>> -- >>> Abbas >>> Architect >>> >>> Ph: 92.334.5100153 >>> Skype ID: gabbasb >>> www.enterprisedb.com >>> >>> Follow us on Twitter >>> @EnterpriseDB >>> >>> Visit EnterpriseDB for tutorials, webinars, whitepapers and more >> >> > > > > -- > -- > Abbas > Architect > > Ph: 92.334.5100153 > Skype ID: gabbasb > www.enterprisedb.com > > Follow us on Twitter > @EnterpriseDB > > Visit EnterpriseDB for tutorials, webinars, whitepapers and more |