You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by "ApoorvGuptaAi (via GitHub)" <gi...@apache.org> on 2023/02/26 18:39:12 UTC

[GitHub] [druid] ApoorvGuptaAi commented on issue #13851: Not able to access column from a Join datasource inside virtualColumns fields of scan queryType

ApoorvGuptaAi commented on issue #13851:
URL: https://github.com/apache/druid/issues/13851#issuecomment-1445431527

   Attaching results from a slightly modified query, it can be clearly seen that accessing the mean_expected column in virtual expression in the top most query returns null. 
   
   ```
   {
     ...
       "virtualColumns": [
       {
         "type": "expression",
         "name": "diff_of_mean",
         "expression": "basesplit.mean_expected - mean_actual",
         "outputType": "DOUBLE"
       },
       {
         "type": "expression",
         "name": "diff_of_mean_debug_1",
         "expression": "basesplit.mean_expected",
         "outputType": "DOUBLE"
       },
       {
         "type": "expression",
         "name": "diff_of_mean_debug_2",
         "expression": "mean_expected",
         "outputType": "DOUBLE"
       },
     ],
   }
   ```
   
   ```csv
   "__time","diff_of_mean","diff_of_mean_debug_1","diff_of_mean_debug_2","sum_actual","count_actual","mean_actual","basesplit.__time","basesplit.sum_expected","basesplit.count_expected","basesplit.mean_expected"
   "1664409600000","-643165.1670692185","null","null","1851672515.99228","2879","643165.1670692185","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1664496000000","-529102.7366475407","null","null","1523815881.5449173","2880","529102.7366475407","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1664582400000","-569473.1718008721","null","null","1640082734.7865114","2880","569473.1718008721","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1664668800000","-552417.1615504303","null","null","1590961425.2652395","2880","552417.1615504303","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1664755200000","-565688.6536937789","null","null","1629183322.6380832","2880","565688.6536937789","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1664841600000","-666414.1523327589","null","null","1919272758.7183456","2880","666414.1523327589","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1664928000000","-465871.1106727756","null","null","1341708798.7375937","2880","465871.1106727756","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1665014400000","-482558.17478761915","null","null","1389767543.388343","2880","482558.17478761915","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1665100800000","-441239.2982682393","null","null","1270769179.0125291","2880","441239.2982682393","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1665187200000","-543284.1701650404","null","null","1564658410.0753164","2880","543284.1701650404","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1665273600000","-557229.5186876628","null","null","1604821013.8204687","2880","557229.5186876628","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1665360000000","-495219.3813783375","null","null","1426231818.369612","2880","495219.3813783375","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1665446400000","-471617.48787544563","null","null","1358258365.0812833","2880","471617.48787544563","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1665532800000","-605353.4029983195","null","null","1743417800.63516","2880","605353.4029983195","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1665619200000","-685076.1327278281","null","null","1973019262.256145","2880","685076.1327278281","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1665705600000","-616306.0573581769","null","null","640341993.5951458","1039","616306.0573581769","1440720000000","24080990493.740643","40319","597261.6010749434"
   "1676937600000","-608602.4824432421","null","null","49077095581.7406","80639","608602.4824432421","1440720000000","24080990493.740643","40319","597261.6010749434"
   ```


-- 
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@druid.apache.org

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


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