Welcome Guest! Log in
×

Notice

The forum is in read only mode.
Due to some maintenance operations, stambia.org will be switched to read-only mode during the 13th November. It will be possible to read and download, but impossible to post on the forums or create new accounts. For any question please contact the support team.

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
Emmanuel Rambeau created the topic: Filter not exists in a mapping - Get the name of the schema
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
Thomas BLETON replied the topic: Filter not exists in a mapping - Get the name of the schema
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
Emmanuel Rambeau replied the topic: Filter not exists in a mapping - Get the name of the schema
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
Emmanuel Rambeau replied the topic: Filter not exists in a mapping - Get the name of the schema
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
Thomas BLETON replied the topic: Filter not exists in a mapping - Get the name of the schema
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
Emmanuel Rambeau replied the topic: Filter not exists in a mapping - Get the name of the schema
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.