473,385 Members | 1,814 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Not showing the rows which is having the digits < 6 !!!

Hi All,
Can anybody look into this below query? I’m running these below queries on Oracle SQL developer.

Expand|Select|Wrap|Line Numbers
  1. SELECT * FROM BATCH.ITEM@SCPOREADDB WHERE ITEM LIKE '%82128%'   
Expand|Select|Wrap|Line Numbers
  1. SELECT * FROM EXCEED.CRECOVER@EXERPTDB206 WHERE PROD_ID LIKE '%82128%'
Expand|Select|Wrap|Line Numbers
  1. SELECT C.PROD_ID, I.UDC_BDMNAME, I.ITEM FROM EXCEED.CRECOVER@EXERPTDB206 C INNER JOIN BATCH.ITEM@SCPOREADDB I ON TO_CHAR(TRIM(C.PROD_ID)) = TO_CHAR(TRIM(I.ITEM)) AND I.ITEM LIKE '%82128%'
First two queries are working fine, but when I join using INNER JOIN condition it is not showing the ITEM/PROD_ID which is less than 6 digits.

Expand|Select|Wrap|Line Numbers
  1. Where PROD_ID is of type CHAR(18bytes) and ITEM is of type VARCHAR2(50Char)
It will display the rows which is having 6 digit Item & Prod_id but if it is < 6 digits those rows are not displaying while joining.

Thanks in advance...
Aug 4 '08 #1
1 2642
r035198x
13,262 8TB
1.) Are you using Oracle? You posted this in the PostgreSQL forum
2.) Why did you trim and to_char in the query with the join when you didn't do it on the one without?
Aug 14 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

8
by: F. Da Costa | last post by:
Following is a snippet of html in which I hide a whole table and try to hide a single row. Here is my question (plz don't chew my head off if its css related instead): Why does the divTable...
2
by: Neil Zanella | last post by:
Hello, I would like to know whether having a <table> element with two <tr> elements each containing one <td> elements and two <td> elements, respectively, is legal from the point of view of...
2
by: c.anandkumar | last post by:
Hi All - I have some problems getting a small piece of javascript working correctly for Firefox. Here is what I am trying to do - 1. I have a form (like a search form) 2. I have many groups...
6
by: robin9876 | last post by:
In an Access 97 (and 2000) database that has linked tables to Oracle which is showing some fields as text when they are numbers in Oracle. In Oracle they are specified to a size e.g. Number(38)....
6
by: Tony | last post by:
The w3schools HTML tag reference for <textarea> http://www.w3schools.com/tags/tag_textarea.asp says that the attributes 'cols' and 'rows' are REQUIRED attributes for the textarea tag. Looking at...
7
by: rcamarda | last post by:
I wish to build a table based on values from another table. I need to populate a table between two dates from another table. Using the START_DT and END_DT, create records between those dates. I...
1
by: archana | last post by:
Hi all, I am having one dataset in which i am taking data from database. Then in my application i am creating one new column into datatable of that dataset and assigned one default value for...
7
by: underground | last post by:
I have a problem that I've spent countless hours on and I'm more than certain this is a obviuos issue to an expert but I am still learning. I have a paging script that I have modified to display a...
1
by: mahmoodtyagi | last post by:
oci_num_rows(ocirowcount) is always showing 0 records(while having more rows) in PHP with Oracle to fetch total no of records. Code wrote as follows: $qry2="select * from...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.