cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Queries considering "emtpy" fields

ppeters
Contributor

Dear community,

 

When I send a query on my repository searching for all objects, which have NOT a specific source tag, I would expect that I get as return all other objects, which have either NO entry (NULL value) in the source field OR all other source names.

 

E.g. I have 20 applications, 10 have as source "ERP", 5 "SAP" and 5 no entry.

 

However, I get as return only these having "SAP" when I say "Source Not Like ERP". Values as"Null" are not returned in the results. Is this correct and if yes, how do I get the "null" values?

 

Thx

Regards

Philip Peters

 

3 Replies

lionel
MEGA
MEGA

You should write your request with "not source like ERP" instead of "source not like ERP"...

If you write "source not like" you first indicate that you want a source, ant then you indicate that the source should not be like ERP...

But if you place the "not" before "source"  (not source like ERP) you just indicate that you want all applications (even those with no source) but the ones linked to the ERP source.

 

Hope that helps 🙂

 

Lionel

hsoegaard
MEGA Partner
MEGA Partner

Hi,

 

Without knowing the exact nature of your query, this is problably what you are looking for:

 

Select [Org-Unit] Where [Internal/External] Not ="I" Or [Internal/External] Is Null 

 

BR

Henrik

jhorber
MEGA
MEGA

Hello Philipp

 

 When I send a query on my repository searching for all objects, which have NOT a specific source tag

--> It is difficul to answer as long as we do not know what you mean by 'specific source tag'

 

How is implemeted this specification in the MEGA metamodel?

It is a specific MetaAttribute (Enumeration: ERP, SAP..)

It is a specific MetaAssociation (Nomenclature)

 

 

Jerome