You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2022/12/15 04:15:04 UTC

[GitHub] [doris] gojumprope opened a new issue, #15098: [Bug] view column return value instead of null when left join a view with condition not met

gojumprope opened a new issue, #15098:
URL: https://github.com/apache/doris/issues/15098

   ### Search before asking
   
   - [X] I had searched in the [issues](https://github.com/apache/doris/issues?q=is%3Aissue) and found no similar issues.
   
   
   ### Version
   
   1.2.0
   
   ### What's Wrong?
   
   If condition is not met when left join a view, some of the view columns still return value instead of null
   
   ### What You Expected?
   
   If left join condition not met, all of the columns of the right table should be null
   
   ### How to Reproduce?
   
   create view public_holiday_view as 
   select rp.publicholidaydatetime, rp.publicholidayname, rp.companyid, rs.branchid, 1 IsPublicHoliday 
   from publicholidayconfigurations rp 
   inner join publicholidaylinks rp2 on rp.id = rp2.publicholidayid 
   left join sitegrouplinks rs on rs.sitegroupid = rp2.granularityid
   
   
   select sd.__time, ph.* from store_data sd
   LEFT JOIN public_holiday_view ph on ph.companyid = sd.companyid and ph.publicholidaydatetime = date(sd.__time)
   
   __time             |publicholidaydatetime|publicholidayname|companyid|branchid|IsPublicHoliday|
   -------------------+---------------------+-----------------+---------+--------+---------------+
   2022-01-28 00:00:00|  2022-01-28 00:00:00|test1            |    123|   456|              1|
   2022-01-29 00:00:00|                     |                 |         |        |              1|
   
   
   IsPublicHoliday column in 2022-01-29 00:00:00 should be null instead of 1
   
   
   ### Anything Else?
   
   _No response_
   
   ### Are you willing to submit PR?
   
   - [ ] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] gojumprope closed issue #15098: [Bug] view column return value instead of null when left join a view with condition not met

Posted by "gojumprope (via GitHub)" <gi...@apache.org>.
gojumprope closed issue #15098: [Bug] view column return value instead of null when left join a view with condition not met
URL: https://github.com/apache/doris/issues/15098


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] gojumprope commented on issue #15098: [Bug] view column return value instead of null when left join a view with condition not met

Posted by "gojumprope (via GitHub)" <gi...@apache.org>.
gojumprope commented on issue #15098:
URL: https://github.com/apache/doris/issues/15098#issuecomment-1681561131

   Tested no issue in 2.0.0


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org