IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

help in selecting rows with low values.


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Roshnii

New User


Joined: 30 Sep 2008
Posts: 45
Location: bangalore

PostPosted: Tue Nov 25, 2008 7:05 pm
Reply with quote

Hi,

Is there any way where I can select rows from table with low values in the where clause?

There is a text field in my table which will be populated with low value. I want all the rows with low values in that particular column from the table. Is that possible?



Thanks,
Roshnii
Back to top
View user's profile Send private message
Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Tue Nov 25, 2008 7:40 pm
Reply with quote

Yes, just compare with x'00'!
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Tue Nov 25, 2008 7:40 pm
Reply with quote

yes. What is the definition of the text field?
Back to top
View user's profile Send private message
Roshnii

New User


Joined: 30 Sep 2008
Posts: 45
Location: bangalore

PostPosted: Tue Nov 25, 2008 7:59 pm
Reply with quote

the column is char(30)
Back to top
View user's profile Send private message
Roshnii

New User


Joined: 30 Sep 2008
Posts: 45
Location: bangalore

PostPosted: Tue Nov 25, 2008 8:00 pm
Reply with quote

I am sorry, its not a varchar field, its a char field
Back to top
View user's profile Send private message
Roshnii

New User


Joined: 30 Sep 2008
Posts: 45
Location: bangalore

PostPosted: Tue Nov 25, 2008 8:21 pm
Reply with quote

I have to pick up rows which are either low values or ---------.
I have tried giving x'60' but it did not pick up the rows with values as ---------.
Back to top
View user's profile Send private message
Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Tue Nov 25, 2008 8:24 pm
Reply with quote

x'60' would not be low values!
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Tue Nov 25, 2008 8:36 pm
Reply with quote

is this text column NULLABLE?
Back to top
View user's profile Send private message
Roshnii

New User


Joined: 30 Sep 2008
Posts: 45
Location: bangalore

PostPosted: Wed Nov 26, 2008 11:45 am
Reply with quote

yes the field is nullable.

I need rows which have the value --------- also which is '606060'
Back to top
View user's profile Send private message
Roshnii

New User


Joined: 30 Sep 2008
Posts: 45
Location: bangalore

PostPosted: Thu Nov 27, 2008 11:43 am
Reply with quote

I am using Column_name IS NULL and its working.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Fri Nov 28, 2008 3:12 am
Reply with quote

Hello,

If IS NULL is working, your questions about x'00' and x'60' have nothing to do with the query that you say meets your requirement.

If the requirement is to find rows with te NULL value, why the discussion about the other hex values? Might the query be only partly working?
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts INCLUDE OMIT COND for Multiple values... DFSORT/ICETOOL 5
No new posts To get the count of rows for every 1 ... DB2 3
No new posts Replace Multiple Field values to Othe... DFSORT/ICETOOL 12
No new posts Exclude rows with > than x occurre... DFSORT/ICETOOL 6
No new posts Null values are considered in Total c... DFSORT/ICETOOL 6
Search our Forums:

Back to Top