Solved

Code Help wih Joins

Posted on 2012-04-06
3
309 Views
Last Modified: 2012-04-09
Hi - I am struggling with trying to get this join to work as it should.

I am attaching the code and the files needed to reproduce it.

I am trying to match up for every entry of diff.compr_fld_nm and bring in the fn.g_field_name for it.

Also trying to match up every entry of test_SCN1_id and bring in the ship_ID for it as well.  

All I am getting is duplicates.
TEST.zip
0
Comment
Question by:j2911
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 

Author Comment

by:j2911
ID: 37817860
The code I have is working except for the join part.
0
 
LVL 30

Accepted Solution

by:
hnasr earned 500 total points
ID: 37820411
This question requires much time to recreate the problem.
Try to limit the number of tables, and fields in each table.
Check the simplified query then add more fields and tables.

In your current query you are only joining two tables that are used as one entity joined with other table without specifying the ON clause. The data is filtered using the where clause. This creates duplicate records and most are insignificant.

Try to use joins.

You can list the contents of few tables (3-4) with few records (~4 in each) and list the expected output.
0
 

Author Comment

by:j2911
ID: 37821819
Although I appreciate your help - I don't do well learning with theory but something I can see.  Would someone have the time to help me out here?
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
MULTIPLE DATE QUERY 15 103
Oracle Listener Not Starting 11 66
oracle RMAN - trying to duplicate a database 5 52
Extract Currency data from a string and put them in a new field 3 49
How to Unravel a Tricky Query Introduction If you browse through the Oracle zones or any of the other database-related zones you'll come across some complicated solutions and sometimes you'll just have to wonder how anyone came up with them.  …
From implementing a password expiration date, to datatype conversions and file export options, these are some useful settings I've found in Jasper Server.
This video shows how to copy a database user from one database to another user DBMS_METADATA.  It also shows how to copy a user's permissions and discusses password hash differences between Oracle 10g and 11g.
This video shows how to configure and send email from and Oracle database using both UTL_SMTP and UTL_MAIL, as well as comparing UTL_SMTP to a manual SMTP conversation with a mail server.

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question