Question about xlate (AREV Specific)
At 13 APR 2000 03:38:46PM Dale Walker wrote:
In the past, I have been able to use a key as follows:
c=xxx*yy
for the a=xlate('filename',c,{colname],'x') in a rbasic routine,
but when I
use c=xxx*yyy*zz
in a symbolic field for an xlate, arev crashes big time.
Specs: win98, pentium233, 64mb ram, using color.user/x/m4096 in the startup command.
All comments, insights, jeers are gratefully accepted.
TIA
Dale
At 13 APR 2000 03:58PM Don Bakke wrote:
Dale,
Is there an error message when AREV crashes? This shouldn't be a problem. I'm guessing, with all due respect, that this is a simple oversight (e.g. VNAV.)
At 13 APR 2000 04:24PM Dale Walker wrote:
Don,
Yes there was an error message. It happened at home and I am here at work. I got an arev error message and a win98 error message indicating a memory address at 0000.00xx. Way down at the bottom of the memory. As soon as I get home I'll enter it as a response to this. Any ideas??
Dale
At 13 APR 2000 05:11PM Don Bakke wrote:
Dale,
When I see AREV crash the OS like that it's usually because the data record or key has an invalid character in it or the memory is a bit flaky.
At 13 APR 2000 07:16PM Dale Walker wrote:
Ok, here's the error message"
Avail Line1 B114 maximum no of variables exceeded
Avail is the field from the other file. A symbolic.
@ans={seats}- {sold}
Perhaps I should use @record.
The field in the data entry screen that I am testing in paint (Shift-F1) is as follows:
the following are mv fields
t=@record
d=@record
s=@record
tcnt=count(t,@vm)+1
if t=' or s=' or d=' then zz=' else
long=len(t)
if long =2 then thea=t1,1 else thea=t1,2
f=thea:"*":d:"*":s
zz=xlate('filename',f,{avail},'x')
end
@ans=zz
Dale
At 13 APR 2000 08:04PM [email protected] wrote:
Does it crash only one set of value? or does it crash regardless of what the key value are. e.g., A*B*C is okay, but 1*2*3 are not.
If it crash only under one set of value, what is it?
I seem to remember that under some circumstance where the Key has an "E" that AREV will bomb. It looks at the value as some scientific notation and if the number is very large it will bomb, e.g., E999.
Just a thought,
[email protected] onmouseover=window.status=imagine … ;return(true)"
Ray Chan ~ Symmetry Info
At 14 APR 2000 08:00AM Kevin Gray - Graycorp wrote:
This is your code …..
t=@record
d=@record
s=@record
tcnt=count(t,@vm)+1
if t=' or s=' or d=' then zz=' else
long=len(t)
if long =2 then thea=t1,1 else thea=t1,2
f=thea:"*":d:"*":s
zz=xlate('filename',f,{avail},'x')
end
@ans=zz
This is how we would consider doing it …..
t=@record
d=@record
s=@record
tcnt=count(t,@vm)+1
for tt=1 to tcnt
t1='
s1='
d1='
zz='
thea='
t1=@RECORD
s1=@RECORD
d1=@RECORD
BEGIN CASE
CASE t1 EQ
zz=' CASE s1 EQ
zz='
CASE d1 EQ
zz=' CASE d1 NE
long=len(t1
END CASE
BEGIN CASE
CASE long EQ 2
thea=t11,1
CASE long NE 2
thea=t11,2
END CASE
f=thea:"*":d:"*":s
zz=xlate('filename',f,{avail},'x')
GOTO nxtt
nxtt:
@ANS=zz
next tt
@ans=zz
This code is very different from yours but hopefully provides a different perspective on things.
Yes, it is a longer way around ….. but sometimes that helps!
Regards,
Kevin Gray
Graycorp
(email [email protected])
At 17 APR 2000 10:12AM Dale Walker wrote:
I guess we overlooked the location of where the problem was occuring.
The xlate was calling for info from a symbolic in a different table.
It was solved by calling for the two data fields (f) with two xlates and giving the answer as
@ans=x-y
x being the first xlate and y being the second.
Thanks to all that contributed.
Dale