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

  • Home
  • SEARCH
  • 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 5928363
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T14:17:00+00:00 2026-05-22T14:17:00+00:00

I have been given the task of selecting key data from an Oracle database,

  • 0

I have been given the task of selecting key data from an Oracle database, but I am noticing that my select is returning duplicate rows. I don’t need them for my report yet I don’t want them to delete them. Could someone help to get only the data that I need. I have tried the following code but this doesn’t help.

SELECT distinct bbp.SUBCAR "Treadwell",
       bbp.BATCH_ID "Batch ID",
       bcs.SILICON "Si",
       bcs.SULPHUR "S",
       bcs.MANGANESE "Mn",
       bcs.PHOSPHORUS "P",
       to_char(bcs.SAMPLE_TIME, 'dd-MON-yy hh24:MI') "Sample Time",
       to_char(bbp.START_POUR, 'dd-MON-yy hh24:MI') "Start Pour Time",
       to_char(bbp.END_POUR, 'dd-MON-yy hh24:MI') "End pour Time",
       bofcs.temperature "Temperature"
FROM  bof_chem_sample bcs, bof_batch_pour bbp, bof_celox_sample bofcs
WHERE bcs.SAMPLE_CODE= to_char('D1')
AND bbp.BATCH_ID=bcs.BATCH_ID
AND bcs.SAMPLE_TIME>=to_date('01-jan-10')
  • 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-22T14:17:01+00:00Added an answer on May 22, 2026 at 2:17 pm

    If you look at the query translated to SQL Server type SQL you will see that there is no relation between your bofcs table and the rest of your data. Basically it is returning every record in the bofcs’ temperature field, and that may be producing duplicate results?.

    SELECT
         bbp.SUBCAR "Treadwell", 
         bbp.BATCH_ID "Batch ID", 
         bcs.SILICON "Si", 
         bcs.SULPHUR "S",
         bcs.MANGANESE "Mn", 
         bcs.PHOSPHORUS "P", 
         to_char(bcs.SAMPLE_TIME,'dd-MON-yy hh24:MI') "Sample Time", 
         to_char(bbp.START_POUR, 'dd-MON-yy hh24:MI') "Start Pour Time",
         to_char(bbp.END_POUR, 'dd-MON-yy hh24:MI') "End pour Time", 
         bofcs.temperature "Temperature"
    FROM 
         bof_chem_sample bcs, 
    INNER JOIN 
         bof_batch_pour bbp,
    ON
         bbp.BATCH_ID=bcs.BATCH_ID
    INNER JOIN
         bof_celox_sample bofcs
    ON
         **-- NO RELATION B/N BOFCS and the other tables????**
    WHERE 
         bcs.SAMPLE_CODE= to_char('D1') AND 
         bcs.SAMPLE_TIME>=to_date('01-jan-10')
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have been given the task to design a database to store a lot
I have been given the task of devising a custom forms manager that has
I have been given a new task from the client which is basically creating
I have been given a task to display data on an ASP .net page
I have been given a task of inputting some student data, like option 1:
I have been given the task of creating a sql database and creating a
I have been given task to check for url that site:domain (If index in
I have been given a task that can be simplified to this scenario: Customers
I have been given a task to create a Python file that will take
I have been given the task of internationalizing a large client-server application. The remit

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.