Some search engines, like Google, allow for more complicated regular expressions. Be aware that not all search engines might understand this logic. The most useful feature this adds is the $, which indicates the end of a URL. In the following example you can see what this does:

کد HTML:
Disallow: /*.php$
This means /index.php could not be indexed, but /index.php?p=1 could be indexed. Of course, this is only useful in very specific circumstances and also pretty dangerous: it’s easy to unblock things you didn’t actually want to unblock.