Inserting Ascii codes (non printable characters) into a string V5R1

Inserting Ascii codes (non printable characters) into a string V5R1

Post by Kevin Steve » Wed, 25 Jun 2003 03:34:16



Hello, I am using a stored procedure where I read some varchar fields
from an old table and am trying to put them in one clob delimited by
newline characters. However, I can not find a function or method of
inserting the new line between fields. Essentially I am looking for a
function that works like the CHAR() function on SQL server and other
systems, where I can pass in the value of the ascii code and have that
inserted into my string.

I have looked fairly extensively through my DB2 manuals, google, and
IRC.

my code looks something like this:

Select Field1, field2, field3 from BLAH
INSERT INTO New_table(New_filed)
VALUES  ( field1 || char(10) || field2 || char(10) || field3);

RTFM's are more than welcome as long as you tell me which FM to read.
I am using V5R1.

Thank you.

 
 
 

Inserting Ascii codes (non printable characters) into a string V5R1

Post by pm3iinc-nospa » Fri, 27 Jun 2003 00:33:42


CHR(10)

PM

 
 
 

1. help: Insert non-printable characters

Hi,

i can access the database when the query string only contains printable
ascii chars. but when i encrypt the message and insert, database generates
error for some characters like "smiling face". what can i do?

thanks,
Stephen

2. Documentapp in OpenROAD

3. Comparing strings with non-ASCII characters

4. bi file has wrong cluster size

5. insert non-ascii character through DBD-Oracle

6. Help!!! SQLServer 7.0 Database Growth

7. non-printable characters

8. Problems installing Oracle 9i on Win2k Server

9. Non-printable characters in SQL

10. How to store non-printable characters ?

11. Null and non printable character with Parameter object