DATA Step, Macro, Functions and more

Write Access Violation SGIOREAD

Reply
New Contributor
Posts: 4

Write Access Violation SGIOREAD

NOTE: SGIO processing active for file INDATA.DEMOGRAPHIC.DATA.

ERROR:  An exception has been encountered.

ERROR: The SAS task name is [SGIOREAD]
ERROR:  Write Access Violation SGIOREAD
ERROR: Exception occurred at (02DBA231)
ERROR: Task Traceback
ERROR: Address   Frame     (DBGHELP API Version 4.0 rev 5)
ERROR: 0000000002DBA231  0000000003E0FBF0  sashost:Main+0xA2711
ERROR: 0000000002D289DB  0000000003E0FF20  sashost:Main+0x10EBB
ERROR: 0000000002D2E61D  0000000003E0FF50  sashost:Main+0x16AFD
ERROR: 00007FF8C74613D2  0000000003E0FF58  KERNEL32:BaseThreadInitThunk+0x22
ERROR: 00007FF8C7D154F4  0000000003E0FF88  ntdll:RtlUserThreadStart+0x34

 

 

=========== Code fragment

data _demogs (sgio=no);

  set indata.demographic (keep=patid birth_date sex hispanic race source);

  where source not in ('X' 'Y' 'Z');

  if missing(Patid)=0 and missing(Birth_date)=0 then both=1;

  if missing(Birth_date)=0 then do;

        minagedate=intnx("year",Birth_date,18,"SAMEDAY");

        if month(Birth_date) = 2 and day(Birth_date)=29 then minagedate=minagedate+1;

 

                                maxagedate=intnx("year",Birth_date,85,"SAMEDAY");

        if month(Birth_date) = 2 and day(Birth_date)=29 then maxagedate=maxagedate+1;

    end;

 

format minagedate maxagedate date9.;

run;

 

Super User
Super User
Posts: 9,211

Re: Write Access Violation SGIOREAD

Take this:

 (sgio=no)

 

Out of the code, then run it.  It is masking any real errors.  Re-run then post the log of what happens.

New Contributor
Posts: 4

Re: Write Access Violation SGIOREAD

Removing sgio=no produces the same error

Super User
Super User
Posts: 9,211

Re: Write Access Violation SGIOREAD

You must have the option setup then, autoexcec or something like that.  What software are you using?  Can you see what options are set when you open SAS?  Also, if you have write access, that sounds like you don't have access to something, either the area where the file is located, or to your temporary workspace.  Do other datasets work (i.e. write a dataset from sashelp to your work).

New Contributor
Posts: 4

Re: Write Access Violation SGIOREAD

-SGIO option is set in the global SAS config file (SAS version 9.4)

 

Removing the SGIO option from the global config and restarting SAS fixes the issue, but we wanted to take advantage of the faster data processing using SGIO.

 

Super User
Super User
Posts: 9,211

Re: Write Access Violation SGIOREAD

To be honest I have never used or even heard of that option.  I assume your using Windows and the file is on Windows?  That was the only requirement I could find on this topic.  Otherwise, contact your SAS support contact, maybe you need something else installed.

New Contributor
Posts: 4

Re: Write Access Violation SGIOREAD

@RW9Yes,

The server is using windows and the file is on a windows file system.

 

Ask a Question
Discussion stats
  • 6 replies
  • 106 views
  • 0 likes
  • 2 in conversation