Hi,
I still haven't figured out how to assign a userdefined variable in a script.
My case is that I in my script commits data several times, after every commit I need to do a new *XDIM_MEMBERSET. Every time the *xdim_memberset is exactly the same.
Example - what I do now.
*XDIM_MEMBERSET ACCOUNT="REVENUE"
*XDIM_MEMBERSET VERSION="90"
*rec
*commit
*XDIM_MEMBERSET ACCOUNT="REVENUE"
*XDIM_MEMBERSET VERSION="90"
*rec
*commit
Etc.
It would be much easier, if I the beginning of each script for Account and Version defined a variable, and then having every *xdim_memberset use the variable. Then I only need to change the definition of the variable in the beginning of each script.
Example - what I want to achieve.
//Definition of constant variables.
%ACCOUNT_VARIABLE%= "ACCOUNT = REVENUE"
%VERSION__VARIABLE% = "VERSION=90"
*XDIM_MEMBERSET %ACCOUNT_VARIABLE%
*XDIM_MEMBERSET VERSION=%VERSION__VARIABLE%
*rec
*commit
*XDIM_MEMBERSET %ACCOUNT_VARIABLE%
+*XDIM_MEMBERSET VERSION=%VERSION__VARIABLE%
*rec
*commit
I've looked at the *SELECT and *MEMBERSET - but can't really get the syntax to work.....
Thank you,
Joergen
Edited by: Jørgen Dalby Andersen on Dec 30, 2011 7:58 AM
Request clarification before answering.
Hi,
I managed to get the syntax correct.
//Definition of constant variables.
*SELECT(%ACCOUNT_VARIABLE%, [ID], ACCOUNT,ID="REVENUE")
*SELECT(%VERSION_VARIABLE%, [ID], VERSION,ID="90")
*XDIM_MEMBERSET ACCOUNT=%ACCOUNT_VARIABLE%
*XDIM_MEMBERSET VERSION=%VERSION__VARIABLE%
*rec
*commit
*XDIM_MEMBERSET ACCOUNT=%ACCOUNT_VARIABLE%
*XDIM_MEMBERSET VERSION=%VERSION__VARIABLE%
*rec
*commit
Regards,
Joergen
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 7 | |
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.