Date: Thu, 20 Nov 2003 14:26:42 -0700
Reply-To: Jack Hamilton <JackHamilton@FIRSTHEALTH.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Jack Hamilton <JackHamilton@FIRSTHEALTH.COM>
Subject: Re: proc report ?
Content-Type: text/plain; charset=us-ascii
Interesting. When I change the program to this:
=====
data test;
*length filename $300.;
filename=urlencode('fs00235a/scripts/broker.exe?_program=devl.ho_report3.sas'
||
'&_service=devl&_debug=0&firstrun=YES&firstchoice=Central&format=P'
|| '&program=D&drilldown=1&where1=where promo_name eq
''Event Apr 03''&by=hh_rm*promo_name');
hh_pres= 'Central';
file log;
put filename=;
run;
ods pdf file='c:\file2.pdf';
ods listing close;
proc report data=test nowd;
column filename hh_pres ;
define filename / noprint;
define hh_pres / display ;
compute hh_pres;
call define(_col_, 'URL', filename);
endcomp;
run;
ods pdf close;
ods listing;
=====
I get a message in the log saying that filename is assigned a length of
200 by default, so the underlying value stops at the "p".
Adding
length filename $300.;
to the data step results in no message, and mysteriously the URL link
in the PDF is no longer set - no messages, but also no link.
So I don't know. Looks like a bug. What does SAS Tech Support say?
--
JackHamilton@FirstHealth.com
Manager, Technical Development
Metrics Department, First Health
West Sacramento, California USA
>>> "Richard Wilson" <Richard.J.Wilson@RBC.COM> 11/20/2003 11:34 AM
>>>
Substitute this in for the filename variable.
filename=urlencode("fs00235a/scripts/broker.exe?_program=devl.ho_report3.sas
&_service=devl&_
debug=0&firstrun=YES&firstchoice=Central&format=P&program=D&drilldown=1&wher
e1=
where promo_name eq 'Event Apr 03'&by=hh_rm*promo_name" );
You should notice that in the address box of the browser it stops at
"p" in
the &where1 macro variable. Which is the 200th character. Let me
know if
this is not happening for you.
Thank you for you help.
-----Original Message-----
From: Jack Hamilton [mailto:JackHamilton@FIRSTHEALTH.COM]
Sent: Thursday, November 20, 2003 2:13 PM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Re: proc report ?
You're not assigning a value to hh_pres in the compute block, so the
length restriction shouldn't make a difference. When I run the code
below, I get a message saying that filename is too long, but
uncommenting the define for filename makes that go away. Then the PDF
file is created, and clicking on the link tries to open a file with
the
name given.
So I'm not yet sure what your problem is.
--
JackHamilton@FirstHealth.com
Manager, Technical Development
Metrics Department, First Health
West Sacramento, California USA
>>> "Richard Wilson" <Richard.J.Wilson@RBC.COM> 11/20/2003 10:42 AM
>>>
This is what I am trying to do. But in the documentation the compute
block
has a max of 200 characters for character variables.
data test;
filename='This is a is a really long url to a sas\internet
program
that has some macro variables and is longer
than 200
characters ';
hh_pres= 'Central';
run;
ods pdf file='c:\file2.pdf';
proc report data=test nowd;
column filename hh_pres ;
define filename /noprint;
define hh_pres /display ;
*define filename / width=50 left;
compute hh_pres / char length=200;
call define(_col_,"URL",filename);
endcomp;
run;
ods pdf close;
-----Original Message-----
From: Jack Hamilton [mailto:JackHamilton@FIRSTHEALTH.COM]
Sent: Thursday, November 20, 2003 1:24 PM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Re: proc report ?
Please send to the list an example of what you are trying to do.
--
JackHamilton@FirstHealth.com
Manager, Technical Development
Metrics Department, First Health
West Sacramento, California USA
>>> "Richard Wilson" <Richard.J.Wilson@RBC.COM> 11/20/2003 10:09 AM
>>>
Is there any way to get around the length limitation (200) for a
compute
block in proc report?
Richard J. Wilson
RBC Centura
____________________________
Tel: 252.454.4964
Fax: 252.977.6362
------------------------------------------------------------
This e-mail may be privileged and/or confidential, and the sender does
not
waive any related rights and obligations. Any distribution, use or
copying of
this e-mail or the information it contains by other than an intended
recipient
is unauthorized. If you received this e-mail in error, please advise
me
(by
return e-mail or otherwise) immediately.
============================================================
------------------------------------------------------------
This e-mail may be privileged and/or confidential, and the sender does
not
waive any related rights and obligations. Any distribution, use or
copying of
this e-mail or the information it contains by other than an intended
recipient
is unauthorized. If you received this e-mail in error, please advise
me
(by
return e-mail or otherwise) immediately.
============================================================
------------------------------------------------------------This e-mail
may be
privileged and/or confidential, and the sender does not waive any
related
rights and obligations. Any distribution, use or copying of this e-mail
or the
information it contains by other than an intended recipient is
unauthorized.
If you received this e-mail in error, please advise me (by return
e-mail or
otherwise) immediately.
============================================================