Groups | Search | Server Info | Login | Register
Groups > comp.databases.pick > #2287
| Newsgroups | comp.databases.pick |
|---|---|
| Date | 2013-12-26 13:18 -0800 |
| References | <ijlod1$9eb$1@news.eternal-september.org> <dd6a1871-7b38-4a2d-8310-f6cf85a46343@u17g2000yqe.googlegroups.com> |
| Message-ID | <cbfdb31f-97e3-41d4-aff5-edd8a3dc0b31@googlegroups.com> (permalink) |
| Subject | Re: openqm TRANS or XLATE with I type dictionary Item |
| From | garcia.luis.e@gmail.com |
El viernes, 18 de febrero de 2011 11:09:19 UTC-5, Martin Phillips escribió:
> Some further thoughts on why your original program did no work....
>
> > PRINT TRANS("ORDERS",1,"TEST","X") would be more correct?
> > with that you get (hex address):Invalid I-type at line number of PROGNAME
>
> When used in a program (as against a dictionary item), the third
> argument to TRANS() must be a field number, not the name of the field.
>
>
> Martin Phillips, Ladybridge Systems
Maybe I am a little bit late on this... nevertheless, I am trying to use the trans function today (Why? Because it is useful) and I am trying to use this feature (Why? Because that would mean lot of time-code-stress savings... if I could make the thing work), and I ran into this thread. Which is actually about what I was looking for. It happens to be that the company I work with owns the license for QM, and I read the manual (most of it... I think), and I have read the pages about trans() many times. First, it is not cool to have rtrans listed in the pdf within trans... it confuses, and it is not the only function without its own entry in the menu. I can live with that... Second, examples are either too few or too short, so I get a hard time figuring out how to make things work. Yet, I can deal with that, too: labor omnia vinci... And last, but no least, the ***** manual DOES say the function should work the way Wilson wrote down! Not only the pdf, but the on-line (wanna-be-up-to-date) version:
"TOTAL.VALUE = QTY * TRANS('STOCK', PART.NO, 'PRICE', 'X')" (sic, http://www.openqm.org/docs/index.html?qmb_trans.htm, Dec/26/2013).
In the same page:
"When used in a dictionary I-type expression this can also be
A data item (A/C/D/I/S-type) defined in the target file's dictionary. If the field name does not follow the rules for construction of QMBasic variable names, it must be quoted." (sic)
On the other hand, if you are right, then the manual has been wrong for years now... but it clearly says "field name", not 'field number', nor it claims that field has to be numeric.
Anyways, I am giving up with that. Just a word of advise for the next person looking for the way to make this work: do not trust the QM manual.
Best regards.
Back to comp.databases.pick | Previous | Next — Next in thread | Find similar
Re: openqm TRANS or XLATE with I type dictionary Item garcia.luis.e@gmail.com - 2013-12-26 13:18 -0800 Re: openqm TRANS or XLATE with I type dictionary Item ernievegas40@gmail.com - 2014-02-06 17:25 -0800
csiph-web