Forum Discussion

Colin_McCrae's avatar
Colin_McCrae
Community Hero
10 years ago

Wildcards in name mapped object properties?

Hi



Am I right in thinking that we can only use * and ? wildcards in the identification properties for name map objects?



We can't use ful Regular Expression syntax?



I want to set up a property description for a URL. The end of the URL consists of numbers. But there are additional pages where this URL form the start of another one. So I want to identify if I there is anything after the numbers.



eg.



website.com/user/123 (mapped as - website.com/user/*)



vs



website.com/user/123/details/part1 (not yet mapped but the map for the first one finds it)



So I want the page map for the first one NOT to also work with the second one. The number of digits is not consistent. It may be 123, or it may just be 1. So I can't just use "?" as I don't know how many there will be. If I map the end part as "??" it will find a page with 2 digits, but not one with 1 or 3.



Is there any way to do this? None of the other RegEx controls seem to work with name map properties .... which seems a bit limiting?



(I'm terrible with RegEx ... I must admit .... but only * and ? seem to work in name map properties as far as I can tell ...)

6 Replies

  • TanyaYatskovska's avatar
    TanyaYatskovska
    SmartBear Alumni (Retired)
    Hi Colin,

     


    You can use wildcards ('*' and '?') in properties' values when mapping objects. It's currently impossible to use regular expressions. We have a suggestion to make it possible to use them and your request has increased its rating.


     

  • Yep.



    Read through that page.



    It mentions name map templates, but not the properties of name map identifiers. The page for that isn't explicit. Although it does only mention ? and * .... but then at the bottom of the page links you to the page about RexEx Syntax.



    None of the RegEx stuff works except * and ? so I assume they're all we can use.



    Which is a bit rubbish.



    Now hitting more mapping woes. Fresh thread incoming ....
  • That's what I thought. Thanks Tanya.



    Simple wildcards only is a little limiting. Full RegEx would be far more flexible.



    Please add your vote to the suggestion if you're reading this!



    :)