Highlighted

Initial User Selection and Xpath

_jerome_dinnat_

15-05-2008

Hi,



I try to select an initial user by Xpath expression.

I have a form with a field name binding with commonname from the edcprincipalentity table, a field userid binding with id from the same table.

I have in my process variables username (Type string)and userid (Type string) and i try to map them with my fields but they are still empty.

I try to send a form fill by a user to a user specify in the form by fill the xpath expression in initial user selection with :

- /process_data/@iduser (doesn't work)

- /process_data/@username (does'nt work)

-

/process_data/InitForm/object/data/xdp/datasets/data/RECORDS/RECORD/commonname

(does'nt work)

- /process_data/InitForm/object/data/xdp/datasets/data/RECORDS/RECORD/id (doesn't work)



Thank you for helping me.



Sorry for my English.

Replies

Highlighted

Jasmin_Charbonn

15-05-2008

If you have only one field called commonname, you can try /process_data/InitForm//commonname



It'll search for a field called commonname in the whole xml. If it finds it, at least you know it's there and it's just your xpath that's not correct.



Jasmin
Highlighted

_jerome_dinnat_

15-05-2008

Hi,



In my form I have a field name binding with commonname in my xml schema built with the edcprincipalentity table.



I tried /process_data/InitForm/object/data/xdp/datasets/data/RECORDS/RECORD/commonname



in the xpath expression but i have this error :



Assignment to XPath was specified with the following expression: /process_data/InitForm/object/data/xdp/datasets/data/RECORDS/RECORD/commonname, but this expression did not evaluate to anything.
Highlighted

_jerome_dinnat_

16-05-2008

yes, i just did it and I got the same error :



Assignment to XPath was specified with the following expression: /process_data/InitForm//commonname , but this expression did not evaluate to anything.
Highlighted

Jasmin_Charbonn

16-05-2008

So I'm questioning your xml file. Can you use a logger and log it to the file system and post the content of your xml?



Jasmin

_jerome_dinnat_

19-05-2008

I have a new error : No active group found with GroupPrincipalId: Tony Blue



I don't know how i did but once Tony Blue received the form fills with the corrects fields ( alex pink filled the name Tony Blue and he received the form with Tony Blue and his ID filled, I want a user fills the field "name" (ex Tony Blue) and the form will be receive by this correct person.



I changed nothing but now I have this error : No active group found with GroupPrincipalId: Tony Blue



Can you explain me how to do what I want to do ?



Thank you.
Highlighted

_jerome_dinnat_

19-05-2008

Finally, I can send the form fill from a user to another with a "query single row" with the SQL statement

"SELECT id FROM edcprincipalentity WHERE commonname = '{$ /process_data/InitForm/object/data/xdp/datasets/data/RECORDS/RECORD/commonname $}'"



I use a variable for the id.



My new problem is that the field id binding with the id from the edcprincipalentity table is still empty. I can have it with the variable but with the binding the id's field must be fill, isn't it ?



Thank you.