Strange but
with vertica 7 this query does not work anymore
select count(f.cod_negozio) from ods.dim_offerta oa left join olap_vendite.fact_vendggall f join ods.dim_offerta o on (f.cod_articolo)= (o.cod_articolo) and (f.cod_negozio) = (o.cod_negozio ) and (f.aaaammgg between o.aaaammgg_inizio and o.aaaammgg_fine) and (f.cod_negozio) = '080814' on f.cod_articolo=oa.cod_articolo and f.cod_negozio= (oa.cod_negozio) where oa.offerta='2014/1002' and (oa.cod_negozio = '080814') and oa.cod_articolo = ('445347')
but if i do:
...
join ods.dim_offerta o on (f.cod_articolo)= (o.cod_articolo) and (f.cod_negozio) = trim(o.cod_negozio ) and ...
or
...
join ods.dim_offerta o on (f.cod_articolo)= (o.cod_articolo) and trim(f.cod_negozio) = (o.cod_negozio ) and ...
then runs fine !!!
obviously subjected fields to trim() contain no trailing spaces...
Sign up
Already have an account? Login
Welcome to the Rocket Forum!
Please log in or register:
Employee Login | Registration Member Login | RegistrationEnter your E-mail address. We'll send you an e-mail with instructions to reset your password.