I have 2 tables. tbl_names
and tbl_section
which has both the id
field in them. How do I go about selecting the id
field,
If the format of the id's in the two table varies then you want to join them, as such you can select to use an id from one-main table, say if you have table_customes
and table_orders
, and tha id for orders is like "101","102"..."110", just use one for customers
select customers.id, name, amount, date from customers.orders;