www.webdeveloper.com
Results 1 to 3 of 3

Thread: What's the most concise way in sql to select from 5 different tables..

Threaded View

  1. #1
    Join Date
    Jun 2011
    Location
    California
    Posts
    383

    Lightbulb What's the most concise way in sql to select from 5 different tables..

    I want some data from each.. but mainly the telephone numbers found in each of these tables..

    The ultimate goal is to create a type of phone book, so when someone searches in the phone number input box it returns all the phones numbers that match from those five different categories (tables).....

    any help would be greatly appreciated.

    Here's what i have now...

    Code:
    select 
    
    code,
    first,
    last,
    phoneday,
    phonenight,
    dfcode
    
    from event.dbo.patient_dg()
    
    select 
    
    id,
    doctor_id,
    phone,
    fax
    
    from event.dbo.doctor_alt_address
    
    select 
    
    CODE_,
    NAME_,
    PHONE,
    FAX
    
    from ARE.APS.RFDME
    
    select 
    
    CODE_,
    FIRST_,
    LAST_,
    PHONE,
    FAX
    
    from ARE.APS.DFDME
    
    Select *
    
    from pharmacy.dbo.chain
    
    Select *
    
    from crm.dbo.rf_contacts
    Last edited by Supplement; 12-10-2012 at 07:17 PM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles