× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Best way to handle it is not to change the compiler default but add this
in your code:

c/exec sql
C+  Set option dynusrprf = *OWNER
c/end-exec

Then when you upgrade OS levels you won't have to remember to change the
compiler default again ;) 


Thanks,
Tommy Holden


-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Pete Helgren
Sent: Wednesday, June 07, 2006 3:55 PM
To: RPG programming on the AS400 / iSeries
Subject: Re: SQL0551 Error when running SQLRPGLE program

Bingo!  That was it!

I knew it was something simple.  I'll change the command default while I

am at it...

Thanks,

Pete


Holden Tommy wrote:

On compiling use USRPRF(*OWNER) & DYNUSRPRF(*OWNER)  seems that the SQL
in the program uses the DYNUSRPRF setting for authority which defaults
to *USER. 


Thanks,
Tommy Holden


-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Pete Helgren
Sent: Wednesday, June 07, 2006 3:17 PM
To: RPG Midrange Discussion
Subject: SQL0551 Error when running SQLRPGLE program

I am not sure what I am missing here.  I have two SQLRPGLE programs
that

I have written that run OK when the user has *ALLOBJ authority but I
get

an SQL0551 error when run with user level security.  Normally I compile

the program with *OWNER User Profile and I don't have a problem.  The 
files and the programs are all owned by the same user and I use adopted

authority.

But something is not working the same here.  These programs have *OWNER

user profile, Use Adopted Authority *YES and are owned by the proper 
user profile but they still get the "Not authorized to object XXX in
XXX

type *FILE" error.  What did I miss?

Pete Helgren
 


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.