Welcome Guest! Log in
×

Notice

The forum is in read only mode.
Stambia versions 2.x, 3.x, S17, S18, S19 and S20 are reaching End of Support January, 15th, 2024. Please consider upgrading to the supported Semarchy xDI versions. See Global Policy Support and the Semarchy Documentation.

The Stambia User Community is moving to Semarchy! All the applicable resources have already been moved or are currently being moved to their new location. Read more…

Topic-icon Question Filter not exists in a mapping - Get the name of the schema

More
14 Mar 2016 14:30 #1 by Emmanuel Rambeau
Good afternoon,

I try to make a filter with a "not exists", and I would like to put the name of the schema.
See the example below :



F0150 is the name of the table.
I would like to replace the area in red by a syntax like schema.tablename. I tried several syntax, "physicalName" included (it was an advice).

I noticed that the xpath "physicalPath" on the table return the right result. But how could I use it ?

Thank you for your help.

Best regards,

Emmanuel Rambeau
Attachments:
More
15 Mar 2016 11:11 #2 by Thomas BLETON
Hi Emmanuel,
I would try something like this :
%x{md:objectPath(ref:schema('TheSchemaName'), 'F0150')}x%

... where TheSchemaName is the "Name" property of the schema.

Note : the syntax with ${...}$ is for process parameters. Here you need Xpath, so you want to use the syntax %x{...}x%
More
15 Mar 2016 17:22 #3 by Emmanuel Rambeau
Hi,

Thank you for your help. It works perfectly.

Regards,

Emmanuel Rambeau
More
18 Mar 2016 10:23 - 18 Mar 2016 10:24 #4 by Emmanuel Rambeau
Good morning,

In fact, %x{md:objectPath(ref:schema('TheSchemaName'), 'F0150')}x% returns SCHEMA.F0150 (with the name of the table).
It works if I remove the name of the table in the expression editor. It is not a problem in the case of the "not exists".

Nevertheless, I'm facing a case where I need only the name of the schema, for a mapping in the target this time.

I use some sequences Oracle, and I have to prefix it by the name of the schema only.
I tried several syntax, but I don't find the right.



What is the right syntax to put it ?
Attachments:
Last edit: 18 Mar 2016 10:24 by Emmanuel Rambeau.
More
18 Mar 2016 11:12 - 18 Mar 2016 11:13 #5 by Thomas BLETON
In this case, you want to use the schema of the current context's metadata (the target).
You can refer to the target's schema like this :
%x{md:objectPath(ref:schema(), 'SEQ_DOCUMENT_CLASS')}x%.NEXTVAL

Does this work for you ?
Last edit: 18 Mar 2016 11:13 by Thomas BLETON.
More
18 Mar 2016 11:18 #6 by Emmanuel Rambeau
Yes, it works...
I did not expected that, because SEQ_DOCUMENT_CLASS is not defined in the metadata. I thought it was necessary, also I did not try to use it.

Well, thank you.