Scalar function STRIP used in a SPUFI SELECT

Georg Peter

Scalar function STRIP used in a SPUFI SELECT
Environment: DB2 z/OS version 8 NFM
Interface : SPUFI (Process SQL statements)
-------------------------------------------------------------------

When I do a spufi SELECT against a catalog table, e.g.

select sTRIP(creator) !! ' ' !! strip(name)!! ' ' !!

encoding_scheme

from sysibm.systables

where creator = 'ORDN'

........



The strip function works and The result is okay:



ORDN DAA001 E

ORDN DAA003 E

ORDN DAA013 E

ORDN DAA022 E

ORDN DAA031 E

ORDN DAA041 E

ORDN DAA101 E



The same spufi statement without concatenation but with comma-separated
column names:

select sTRIP(creator), /* varchar(128)*/
, strip(name)! /* the same */

, encoding_scheme /* CHAR(1) */


from sysibm.systables

where creator = 'ORDN'

........


now the strip function does not work in spufi:

ORDN


ORDN


ORDN


ORDN


ORDN



HMMMM......SPUFI cannot deal with the strip function, when the columns
in the select are comma-separated ?????????



Any info that anybody can provide on the above would be greatly
appreciated.

With kind regards - mit freundlichen Gruessen,
G e o r g H . P e t e r
-------------------------------------------------------------------
Datenzentrale Baden-Wuerttemberg
Development and Product Support (E3)
Krailenshaldenstrasse 44

Ground Floor, Room 018

70469 Stuttgart, Germany, Europe
e:mail [login to unmask email]
Phone 0049-711-8108-27271

PC-Fax 004971189696071
Internet (only in german language):http://www.dzbw.de
< http://www.dzbw.de/ >
----------------------------------------------------------------------






Abonnieren Sie unseren Infobrief und erfahren Sie regelmäßig die neuesten Nachrichten über unsere Lösungen, aktuellen Projekte und Entwicklungen. Melden sie sich an mit diesem Link http://www.datenzentrale.de/Info-Brief
_______________________________________________________________________________

Datenzentrale Baden-Württemberg, Anstalt des öffentlichen Rechts
Krailenshaldenstr. 44, 70469 Stuttgart
Telefon (0711) 8108-20, Telefax (0711) 8108-21350
E-Mail [login to unmask email], Internet www.datenzentrale.de
Vorstand: Karl Tramer (Vors.) und Harald Schätzle, Vorsitzender des Verwaltungsrats: Gunter Czisch
USt-Id-Nr. DE147794223
_______________________________________________________________________________




_____________________________________________________________________
* IDUG North America * Anaheim, California * May 2-6 2011 * http://IDUG.ORG/NA *
* Your only source for independent, unbiased, and trusted DB2 information. *
_____________________________________________________________________
http://www.IDUG.org/mentor
Mentoring should be a rewarding experience for everyone...
IDUG is offering up to 80% off when you both come to the conference!
_____________________________________________________________________

If you need to change settings, http://www.idug.org/cgi-bin/wa?A0=DB2-L is the home of IDUG's Listserv

Walter Jani&#223;en

AW: Scalar function STRIP used in a SPUFI SELECT
(in response to Georg Peter)
Hello Georg

Long time, no see.

I think, you are wrong, because STRIP does not change the format, which the data is presented in. So for your second example you get 3 columns, the first with a width of 128, while for the first example you get one column.

P.S. Hope to see you at the next GUIDE here in Duesseldorf in April

Mit freundlichen Grüßen
Walter Janißen

ITERGO Informationstechnologie GmbH
Anwendungsentwicklung
Systeme Laufzeitarchitektur
Victoriaplatz 2
D-40198 Düsseldorf
[login to unmask email]<mailto:[login to unmask email]>

Vorsitzender des Aufsichtsrats: Jürgen Vetter
Geschäftsführung: Dr. Bettina Anders (Vorsitzende),
Ina Kirchhof, Dr. Christian Nymphius, Dr. Michael Regauer, Wolfgang Schön
Sitz: Düsseldorf, Handelsregister: Amtsgericht Düsseldorf, HRB 37996



________________________________
Von: IDUG DB2-L [mailto:[login to unmask email] Im Auftrag von Peter, Georg
Gesendet: Mittwoch, 9. Februar 2011 15:11
An: [login to unmask email]
Betreff: [DB2-L] Scalar function STRIP used in a SPUFI SELECT

Environment: DB2 z/OS version 8 NFM
Interface : SPUFI (Process SQL statements)
-------------------------------------------------------------------

When I do a spufi SELECT against a catalog table, e.g.

select sTRIP(creator) !! ' ' !! strip(name)!! ' ' !!
encoding_scheme
from sysibm.systables
where creator = 'ORDN'
……..

The strip function works and The result is okay:

ORDN DAA001 E
ORDN DAA003 E
ORDN DAA013 E
ORDN DAA022 E
ORDN DAA031 E
ORDN DAA041 E
ORDN DAA101 E

The same spufi statement without concatenation but with comma-separated column names:

select sTRIP(creator), /* varchar(128)*/
, strip(name)! /* the same */
, encoding_scheme /* CHAR(1) */
from sysibm.systables
where creator = 'ORDN'
……..

now the strip function does not work in spufi:

ORDN
ORDN
ORDN
ORDN
ORDN

HMMMM……SPUFI cannot deal with the strip function, when the columns in the select are comma-separated ?????????

Any info that anybody can provide on the above would be greatly appreciated.

With kind regards - mit freundlichen Gruessen,
G e o r g H . P e t e r
-------------------------------------------------------------------
Datenzentrale Baden-Wuerttemberg
Development and Product Support (E3)
Krailenshaldenstrasse 44
Ground Floor, Room 018
70469 Stuttgart, Germany, Europe
e:mail [login to unmask email]
Phone 0049-711-8108-27271
PC-Fax 004971189696071
Internet (only in german language):http://www.dzbw.de < http://www.dzbw.de/ >
----------------------------------------------------------------------





Abonnieren Sie unseren Infobrief und erfahren Sie regelm��ig die neuesten Nachrichten �ber unsere L�sungen, aktuellen Projekte und Entwicklungen. Melden Sie sich an mit diesem Link http://www.datenzentrale.de/Info-Brief

_______________________________________________________________________________

Datenzentrale Baden-W�rttemberg, Anstalt des �ffentlichen Rechts
Krailenshaldenstr. 44, 70469 Stuttgart
Telefon (0711) 8108-20, Telefax (0711) 8108-21350
E-Mail [login to unmask email] <mailto:[login to unmask email]>, Internet www.datenzentrale.de< http://www.datenzentrale.de >
Vorstand: Karl Tramer (Vors.) und Harald Sch�tzle, Vorsitzender des Verwaltungsrats: Gunter Czisch
USt-Id-Nr. DE147794223
_______________________________________________________________________________

________________________________

[ http://www.idug.org/images/stories/db2/db2_10_savings.jpg ] < http://www-01.ibm.com/software/data/db2/zos/db2-10/ >

The IDUG DB2-L Listserv is only part of your membership in IDUG. If you are not already an IDUG member, please register here. < http://www.idug.org/register >

_____________________________________________________________________
* IDUG North America * Anaheim, California * May 2-6 2011 * http://IDUG.ORG/NA *
* Your only source for independent, unbiased, and trusted DB2 information. *
_____________________________________________________________________
http://www.IDUG.org/mentor
Mentoring should be a rewarding experience for everyone...
IDUG is offering up to 80% off when you both come to the conference!
_____________________________________________________________________

If you need to change settings, http://www.idug.org/cgi-bin/wa?A0=DB2-L is the home of IDUG's Listserv