× 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.



Scott,
I use them everyday and have no problems with auto-extending them. I
auto-extend 100% of my user spaces when they are created. Never had a
problem.
-Bob Cozzi Consulting

-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx]
On Behalf Of Mel Rothman
Sent: Tuesday, January 20, 2004 12:00 AM
To: rpg400-l@xxxxxxxxxxxx
Subject: [SPAM] Re: User Space problems.

Scott,

I've had success extending a user space.  After creating the the user space,

the change user space attribute (QUSCUSAT) API is used to make it
extendible.

In a small test program, I created a 1024 byte user space and extended it to

over 15 MB with 300 writes of 50,000 bytes each.

The code to change the extendibility attribute, copied from CGIDEV2's
XXXUSRSPC 
module is:

D rtnlib          s             10
D QualUsrSpc      s             20
D AttrToChg       ds
D  attrcount                    10i 0 inz(1)
D  attrkey                      10i 0 inz(3)
D  attrlen                      10i 0 inz(1)
D  attrvalue                     1    inz('1')
D qusec           ds
D  qusbprv                      10i 0 inz(%size(qusec))
D  qusbavl                      10i 0 inz(0)
D  qusei                         7
D                                1
D  msgdata                     500

  * Make user space automatically extendible
C                   call      'QUSCUSAT'
C                   parm                    rtnlib
C                   parm                    qualusrspc
C                   parm                    AttrToChg
C                   parm                    qusec

For more information about CGIDEV2, see http://www-922.ibm.com/

Mel Rothman, CGIDEV2 Author
Mel Rothman, Inc.

Scott Klement wrote:
> I've had bad experiences with "automatically extending" user spaces.  I've
> found things work much better if you first calculate how big the user
> space can be and use that to create it.
> 
> Is it just me, or do users spaces only "automatically extend" for APIs
> which are designed for it?   Are they intended to expand when they're
> populated by my own programs?  I've never managed to get them to do so.
> 
> 
> 
>>The point where the User space crash occurs it is hardly loaded upto
>>even 1 MB. Still we face this problem. What do you reckon could be the
>>problem.
> 


_______________________________________________
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.