Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7278305
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T22:51:24+00:00 2026-05-28T22:51:24+00:00

Is it possible to combine two tables as in my example? table one: bibid

  • 0

Is it possible to combine two tables as in my example?

table one:

bibid -- fieldid -- fied_data 
400 ----- 10 ------- 107
400 ------ 5 -------- 1950
400 ------ 3 -------- USA
405 ------ 5 -------- 1997
405 ----- 10 -------- 90
405 ------ 3 -------- RUSSIA

table two:

bibid -------- name
400 --- Postman Always Rings Twice
405 --- Postman is a very good person

That result would be:

bibid --------- name --------------------------length ----------year ---------- country 
400 -- Postman Always Rings Twice --------------107------------1950 ------------USA
405 -- Postman is a very good person -----------90-------------1997 ------------RUSSIA
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T22:51:24+00:00Added an answer on May 28, 2026 at 10:51 pm

    Using joins to fetch the data.

    SELECT one.bibid, 
      two.name, 
      one_10.fied_data as length,
      one_5.fied_data as year,
      one_3.fied_data as country  
    from table_two two
    LEFT OUTER JOIN table_one one
    ON one.bibid = two.bibid
    LEFT OUTER JOIN table_one one_3
    ON one.bibid = one_3.bibid
    AND one_3.fieldid = 3
    LEFT OUTER JOIN table_one one_5
    ON one.bibid = one_5.bibid
    AND one_5.fieldid = 5
    LEFT OUTER JOIN table_one one_10
    ON one.bibid = one_10.bibid
    AND one_10.fieldid = 10
    

    But it would be better to normalize your data…

    BTW: Did you mean field_data instead of fied_data?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is it possible to combine two wav files into one as if they've been
I have two tables from two different databases. For example: Table: Articles1 - Database:
Is it at all possible to combine two different query results into one feed
Is it possible to combine registers in vim? For example, if I have registers
I'm not exactly sure if what I'm needing is possible. I have two tables
I have basic tables one and two. Let`s call them tbl1 and tbl2. tbl1
Is it possible to create a table with a column that combines two column
I have combined two different tables together, one side is named DynDom and the
Is it possible to write a single query that can return two rows, one
pretty straightforward question actually.. is it possible in PHP to combine two separate arrays

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.