Forum Discussion

NageshKuppuraj1's avatar
Qrew Member
9 months ago

Simple table Join question from a QB newbie


I am trying to join two tables - let's say Customer and Order tables. Customer->Order has 1-M relationship. The primary key for the Customer is Customerid and for the order table is Orderid. 1 customer can have multiple orders. I want to join the two tables and display all the attributes in one table. for ex: in SQL I can do something like: Select * from customer, order where order.customerid = customer.customerid . I am not sure how to go about doing this in QB. Any help appreciated. Thanks

Nagesh Kuppuraju

3 Replies

  • I had the same problem going from SQL to Quickbase because Quickbase does a lot of the heavy lifting.  Under settings for the table you will find Table to Table Relationships and this walks you through connecting the tables and creates the "related" fields.  In your example go to the settings in the Customer table and under Table to Table Relationships select New Relationship.  Select the Order table and then the graphic for Customer has many Orders.  Then you can select what Customer info you want in the order and you can also create summary fields in the Customer like a count of orders or total all orders.  Hope that helped!

    Julie Meeker