Extracting ReceiverId

I am trying to extract ReceiverId from a
document. The trading networks is aumatically
generating an XQL query for this. The problem is
the ReceiverId is part of a string “xyz-abc”,
where “xyz” is the ReceiverId. So when the whole
string is extracted (i.e both the parts ) the
document submission is failing. How do you modify
XQL string so it extracts only first part from
the string.
Actually I figured out how to do it in WQL. But
when I type in the WQL query TN is giving me an
exception. Seems like XQL is the default.
Can we specify WQL queries in TN.

After extracting the Receiver ID use the String Substituion option
Plz refer to the TN Building Networks guidelines