Skip to main content
Question

What is the way to calculate t1.c1/t2.c2 where t1 and t2 are two different tables in Vertical 8.0.x

  • Apr 15, 2017 9:51 PM UTC
  • 3 replies
  • 19 views

balakshman

I am new to Vertical. I have the above question. I would appreciate a reply in this regard. Thanks.

3 replies

balakshman
  • Author
  • New Participant
  • Apr 16, 2017 4:09 AM UTC

I mean the best way to perform division t1.c1/t2.c2. Here c1and c2are columns in tables t1 and t2 respectively.


swalkaus
Forum|alt.badge.img
  • Participating Frequently
  • Apr 17, 2017 1:06 PM UTC

If you want the cartesian product of the two tables (unlikely) you can simply do:
select t1.c1/t2.c2 from t1, t2;

More likely you want to join the tables, perhaps using some identifier:
select t1.c1/t2.c2 from t1 join t2 on t1.id =t2.id;


balakshman
  • Author
  • New Participant
  • Apr 18, 2017 2:13 PM UTC

Thanks. It solved my problem. Also, I was using a join on both the tables.