You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hive.apache.org by "Edward Capriolo (JIRA)" <ji...@apache.org> on 2013/08/25 19:10:53 UTC

[jira] [Comment Edited] (HIVE-4964) Cleanup PTF code: remove code dealing with non standard sql behavior we had original introduced

    [ https://issues.apache.org/jira/browse/HIVE-4964?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13749694#comment-13749694 ] 

Edward Capriolo edited comment on HIVE-4964 at 8/25/13 5:10 PM:
----------------------------------------------------------------

One more cleanup: Please remove 'while (true)' + 'break' constructs unless they are needed. The do not read well and introducing break logic is generally not suggested.


{quote}
while (true) {
 if (iDef instanceof PartitionedTableFunctionDef) {
{quote}



Instead try:
{quote}
Item found == null;
while (found==null){
}
{quote}
or even better
{quote}
 for (item: list){
   if (matchesCriteria(item) ){
     return item;
   }
 }
{quote}
                
      was (Author: appodictic):
    One more cleanup: Please remove 'while (true)' + 'break' constructs unless they are needed. The do not read well and introducing break logic is generally not suggested.


{quote}
while (true) {
 if (iDef instanceof PartitionedTableFunctionDef) {
{quote}



Instead try:
{quote}
Item found == null;
while (found!=null){
}
{quote}
or even better
{quote}
 for (item: list){
   if (matchesCriteria(item) ){
     return item;
   }
 }
{quote}
                  
> Cleanup PTF code: remove code dealing with non standard sql behavior we had original introduced
> -----------------------------------------------------------------------------------------------
>
>                 Key: HIVE-4964
>                 URL: https://issues.apache.org/jira/browse/HIVE-4964
>             Project: Hive
>          Issue Type: Bug
>            Reporter: Harish Butani
>            Priority: Minor
>         Attachments: HIVE-4964.D11985.1.patch, HIVE-4964.D11985.2.patch
>
>
> There are still pieces of code that deal with:
> - supporting select expressions with Windowing
> - supporting a filter with windowing
> Need to do this before introducing  Perf. improvements. 

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira