Oops, that won't work:

set x="^TMP(1,2,3,,5)"
w $ql(x) -->
%GTM-E-NOCANONICNAME Value is not a canonic name (^TMP(1,2,3,,5))
w $q2(x,1) -->
%GTM-E-NOCANONICNAME Value is not a canonic name (^TMP(1,2,3,,5))


Kevin




On 2/12/06, Kevin Toppenberg <[EMAIL PROTECTED]> wrote:
> excellent, it looks like $qsubscript() is the function I was looking
> for.  My function is not mission critical.  I just want to screen for
> null nodes in a referenct, because $Get() won't protect against these.
>
> Thanks!
>
> Kevin
>
>
> On 2/12/06, Gary Monger <[EMAIL PROTECTED]> wrote:
> > Check out $QS.
> >
> > If you are doing something dangerous, where the success of the operation is
> > in question because it is beyond your control, you probably should be using
> > an error trap. For example, virtually any device operation, anytime you want
> > to execute strings input by a user, or use a reference input by a user.
> > The Kernel does provide utilities for handling devices, and they are
> > trapped.
> >
> >
> > -----Original Message-----
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED] On Behalf Of Kevin
> > Toppenberg
> > Sent: Sunday, February 12, 2006 12:08 AM
> > To: hardhats-members@lists.sourceforge.net
> > Subject: Re: [Hardhats-members] Protecting against indirection errors.
> >
> > On 2/11/06, Gary Monger <[EMAIL PROTECTED]> wrote:
> > > You could validate the string to make sure it is a valid global reference.
> > > I'm sure there is a clever pattern match that would serve for most cases.
> > > If you want to handle variables in the string like "^VA(200,DUZ,0)" you
> > > might need a loop.
> > > The error trap is faster to build, easier to prove correct and complete,
> > and
> > > a better solution.
> > >
> >
> > I think that an error trap is the way to go.  It's just a bit awkward
> > to have to fill one's codes with error traps everywhere.  But perhaps
> > I could just isolate those places where user input is planed.
> >
> > The main problem I have run into is when one of the nodes is null,
> > with GT.M doesn't allow in VistA (I think it is possible to configure
> > it to allow this!).  Isn't there a command to list out the various
> > nodes in a reference?
> >
> > Thanks
> > Kevin
> >
> >
> > -------------------------------------------------------
> > This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
> > for problems?  Stop!  Download the new AJAX search engine that makes
> > searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
> > http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642
> > _______________________________________________
> > Hardhats-members mailing list
> > Hardhats-members@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/hardhats-members
> >
> >
> >
> > -------------------------------------------------------
> > This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
> > for problems?  Stop!  Download the new AJAX search engine that makes
> > searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
> > http://sel.as-us.falkag.net/sel?cmdlnk&kid3432&bid#0486&dat1642
> > _______________________________________________
> > Hardhats-members mailing list
> > Hardhats-members@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/hardhats-members
> >
>


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
_______________________________________________
Hardhats-members mailing list
Hardhats-members@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/hardhats-members

Reply via email to