473,324 Members | 2,179 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,324 software developers and data experts.

Space instead of Null

Can we use the word “space”(instead of null) in DB2 query.

I have given You the query here.



EXEC SQL UPDATE DOEORDER

SET CHRG_CARD_NBR = SPACE

WHERE ADD_TO_DB_DT < '2006-06-01'

END-EXEC.

Is this a right one.

SET CHRG_CARD_NBR = SPACE
Jul 12 '07 #1
2 4148
MindBender77
234 100+
Can we use the word “space”(instead of null) in DB2 query.

I have given You the query here.



EXEC SQL UPDATE DOEORDER

SET CHRG_CARD_NBR = SPACE

WHERE ADD_TO_DB_DT < '2006-06-01'

END-EXEC.

Is this a right one.

SET CHRG_CARD_NBR = SPACE

You might want to try: SET CHRG_CARD_NBR = " "
A space keystroke between quotes should work. I would try a select statement using the " " to make sure your updating the correct data.
Jul 16 '07 #2
dewa81
14
SPACE is not the same as NULL

So it is better to use if the column to be updated is a nullable column

EXEC SQL UPDATE DOEORDER

SET CHRG_CARD_NBR = NULL

WHERE ADD_TO_DB_DT < '2006-06-01'
Jul 23 '07 #3

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

Similar topics

31
by: Robert Brown | last post by:
Let's say I have a type hierarchy: (just an example) the general entity customer: CREATE TABLE customer(customer_id int, customer_name varchar(250), customer_type int) three specific...
11
by: kenneth | last post by:
I just ran across this. #1 <DBColumn> 1 </DBColumn> #2 <DBColumn> </DBColumn> The data for #1 will be parsed and returned as " 1 ". I get a sequence of...
12
by: David Thielen | last post by:
Hi; I have an element: <space> </space> When I call SelectSingleNode() on it, the InnerXml is a 0 length String, not a String containing 1 space. Any ideas?
0
by: Fred | last post by:
Hello, I found a CLOB column in a DMS table that programmers were using to store tiny strings (less than a couple kilobytes). Since CLOB columns can only allocate entire kilobytes of space at...
5
by: N | last post by:
Hi, I got an error during load on a couple of the tables. And it seems to be complaining that I'm running out of tempspace (possibly during index rebuild). Below is the load command and error....
37
by: hasadh | last post by:
Hello, probably this may be a simple qn to u all but I need an answer plz. In my software i used macros like OK,TRUE,FALSE,FAILURE . A friend who included this code as a library into his module...
3
by: Zheng Da | last post by:
Program received signal SIGSEGV, Segmentation fault. 0x40093343 in _int_malloc () from /lib/tls/libc.so.6 (gdb) bt #0 0x40093343 in _int_malloc () from /lib/tls/libc.so.6 #1 0x40094c54 in malloc...
2
by: CFAN | last post by:
Why the disk space keep on decreasing,is that due to use popen()? I have wrote a monitor program to ensure my program on working by using popen to use 'ps' command, but the disk space keep on...
6
by: JackC | last post by:
Hi, My program takes a series of encoded file segments, and decodes each segment and writes it to the output file. I am trying to approach this as follows: I know the size of the output...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
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...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
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...

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.