Darren,

The field ID = 98 is a "special" field. It is in the reserved range
and this is how a "Push by matching field IDs" action is recorded.
So... I think that part of the push action is a kind of magic variable
that the ARS server expands to an intersection of the field ID's
between the two listed forms.
(
Ref  arstruct.h line: 39
#define AR_LIKE_ID                98  /* Reserved for Push/Set Like Field id */
)


However to try to talk to how I think Application-Parse-Val-SField
would work ....

First understand what the docs say:
"
Application-Parse-Val-SField <form1> <field> <form2> <assignment_statement>

Converts a Set Fields or Push Fields filter assignment statement into
an internal representation. See "Syntax exception—Special commands
with qualifications" on
page 617.
"

Then read up on this function over here. :)
"
Application-Format-Qual-SField <form1> <form2> <internal_qualifier>

Converts an internal representation of a qualifier from a Set Fields
or Push Fields filter action into a qualification string.
See "Syntax exception—Special commands with qualifications" on
page 617.
"

Note:
 What "internal representation" is never really explained. :)



If your pulling data from the DB and you want to convert it to "Human
readable" then you want to use Format to decode the value you find in
the meta data. :) But there is some more work to be done here too.


Example time:

I will pick on the sample application from v6.3. ( If you did not load
it, then do so and you can see what I see too.)

I will work with the following Active link:
Sample:Enroll05(PushFields) .  It does not to a push by matching ID's,
but I think once you get the hang of this example the other condition
will make sense too.

So first lets get some parts together. :)

select actlinkId,name from actlink where name='Sample:Enroll05(PushFields)'
--> actlinkId = 228 (for me, your value will be different)
--> name = 'Sample:Enroll05(PushFields)'  ( no surprise there. :) )

We also need:

select actlinkId, name from actlink_mapping a, arschema b where
a.actlinkId=228 and b.schemaId = a.schemaId
--> name='Sample:ClassCentral'

select actlinkId,actionIndex,fieldId,sampleSchema, assignShort from
actlink_push where actlinkId = 228

You will see 8 rows that match that search. I will deal with the row
for the fieldId = 536870921. (Since the others are fairly boring. :)

That returns (of most interest)
 --> assignShort =
'[EMAIL 
PROTECTED]:Enrollments\1\536870921\4\1\2\2\1\2\2\0\4\6\102\1\*\1\*\1\536870940\0\1\4\'


So now how to use this stuff with "Application-Format-Qual-SField" you ask?


Application-Format-Qual-SField

<form1> = "Sample:ClassCentral"
<form2> = "Sample:Enrollments"
<internal_qualifier> = 4\1\2\2\1\2\2\0\4\6\102\1\*\1\*\1\536870940\0\1\4\

[ Note that the value you send to this function is not the full
assignShort  value. You have to strip the leading "headers" that tell
the active link the server and "form2" values to get data from and the
field on "form1" where the results should be returned too.
(AKA: '[EMAIL PROTECTED]:Enrollments\1\536870921\')
]

When used in a Filter Set Field $PROCESS$ action the return value is:
1 = 0

[ Which is what the Push field Qualification is in that active link. :) ]


We can reverse the process by making use of the
Application-Parse-Val-SField function:

Application-Parse-Val-SField
<form1> = "Sample:ClassCentral"
<field>   = 536870921
<form2> = "Sample:Enrollments"
<assignment_statement> = "1=0"

Which works [er... does not return an error] for me, but the returned
results a very strange value via an Active Link $PROCESS$ (When run on
the server via the @: notation) to the screen. So maybe that function
does not work that way? But the Format function did... <shrug>)

BTW: a sample value assignShort for a "push by matching ID" looks like
the following:
 [EMAIL PROTECTED]@[EMAIL PROTECTED]


HTH.

P.S. Get that support contract renewed... you never know when you are
going to need support. :)

P.S.S. Sorry for the slow response, but I wanted to document the
function in enough detail that you could try to follow. (And these
functions are not the most straight forward. :)

--
Carey Matthew Black
Remedy Skilled Professional (RSP)
ARS = Action Request System(Remedy)

Love, then teach
Solution = People + Process + Tools
Fast, Accurate, Cheap.... Pick two.

On 2/5/07, LAU, DARREN (ASI) <[EMAIL PROTECTED]> wrote:
**
I did a search on this but didn't even get one hit.  Anyways here are the
commands I'm using.

Application-Parse-Val-SField <form1> <field> <form2> <assignment_statement>

Application-Format-Val-SField <form1> <field> <form2> <internal_assignment>

I'm doing this on a value I'm pulling from the QueryShort column from the
actlink_push table.



[EMAIL PROTECTED]@\32\ES-AccountAdministrationRequests\1\98\0\4\6\



My question is what do I put in the <field> parameter?  Is that supposed to
be the field that is being set?  One thing to note is that the field 98 no
longer exists on the form referenced above.  So far with all my attempts I
haven't been able to convert that into something human readable.  TIA for
any help.



Darren Lau

_______________________________________________________________________________
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org ARSlist:"Where the Answers 
Are"

Reply via email to