Skip to Content
0

using SYS_CONTEXT( 'CLIENTCONTEXT','S_LANGU') in view defintions

Feb 02, 2017 at 10:02 AM

295

avatar image

Hi all,
we start upgrading our development System to 750.
Now we faced the problem that the transaction se38 dumps with "ora-01403 no data found" if you start writing the name of the report you're looking for.

The underlying view for this input is the view SEDT_PROG_VIEW.
If i try to select this view via se16 i get the same dump.

After some investigation on the database i think the problem is the using of SYS_CONTEXT( 'CLIENTCONTEXT','S_LANGU') to get the preferred language.

This is the view defintion in 750:


SELECT "TRDIR"."NAME" AS "NAME",
"T002"."SPRAS" AS "LANGUAGE",
"TRDIRT"."TEXT" AS "DESCRIPTION"
FROM ( "TRDIR" "TRDIR"
INNER JOIN "T002" "T002" ON ( NOT ( "TRDIR"."NAME" = ' ' )
OR NOT ( "T002"."SPRAS" = ' ' )
)
)
LEFT OUTER JOIN "TRDIRT" "TRDIRT" ON ( "TRDIR"."NAME" = "TRDIRT"."NAME"
AND "T002"."SPRAS" = "TRDIRT"."SPRSL"
)
WHERE ( ( "T002"."SPRAS" = SYS_CONTEXT( 'CLIENTCONTEXT','S_LANGU')
OR "T002"."SPRAS" = 'E'
)
AND NOT ( "TRDIR"."NAME" LIKE '_______________________________%' )
);

But in the older system the where-clause looks like this:

 WHERE (  ( "T002"."SPRAS" = 'D'  OR "T002"."SPRAS" = 'E' 

It's a hard-coded search for german and english.
But a simple

select SYS_CONTEXT( 'CLIENTCONTEXT','S_LANGU') from dual;

returns 1 rows with a NULL value.

If i understand the oracle documentation correctly then the namespace 'CLIENTCONTEXT' has to be managed by the user or application. It's not managed by oracle.
http://docs.oracle.com/cd/B19306_01/network.102/b14266/apdvcntx.htm#DBSEG14000

In my 740 system i found 30 views using these construct. One of them is the View SEPM_CMPPRODUCT. And with this view the se16 dumps also in the 740 system.

Is this a bug or some missung customizung in my systems ?

kind regards
Kay

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

3 Answers

Prithviraj Rajpurohit Feb 02, 2017 at 11:06 AM
0

Hi

You can perform something similar to the views if found, as mentioned in the sapnote

2272266 - LONGPOST.LOG contains error messages for SEPM_C_RAMP_PRODUCT

Did you try upgrading DBSL libraries?

Regards

Prithviraj

Share
10 |10000 characters needed characters left characters exceeded
Kay Kanekowski Feb 03, 2017 at 11:17 AM
0

Hi all,
i did a new test with another 750 system. Identical software- and productcomponents, identical DBSL-lib. Both views use the SYS_CONTEXT.
And here it works as expected. The se16 shows both german and english entries of table SEDT_PROG_VIEW.

So i did a st12-trace on both systems.
Both systems executed this

  SET SESSION VARIABLE S_CLIENT=$session.client='099' S_USER=$session.user='YI00060' S_LANGU=$session.system_language='D'

I think that has to be done for SYS_CONTEXT-call within the view.

After setting these variables one system did the select of SEDT_PROG_VIEW and showed the result.
But the other systems did a DEQ_ALL and all the other things that had to be done to collect the dump-information.

regards
Kay


Share
10 |10000 characters needed characters left characters exceeded
Kay Kanekowski Feb 07, 2017 at 12:55 PM
0

Hi all,

after submitting a service request the SAP support answers this:

"the mentioned issue seems to be a known ORACLE bug. Please check the following note: 2174705 - Session variables
and implement oracle client version 12.1.0.2.0, V2 (currently V1 is running in your system)."

We upgraded the client and the problem is gone.

Kind regards
Kay

Share
10 |10000 characters needed characters left characters exceeded