How to assign to both SEF and non-SEF urls

The URL assignment will look at whatever the url is in the browser. So if you want to make sure the assignment works for both SEF and non-SEF urls, you will need to place assignments in the URL field for both.

How to prevent the URL assignment also matching urls you don't want

The URL assignment will match any url that contains the part you place in the URL assignment field.

For instance, if you place foobar=1 in that field, it would match any of these urls:

index.php?foobar=1
index.php?foobar=1&baz=qux
index.php?foobar=10
index.php?baz=qux&foobar=123

Let's say you only want it to match the first 2 urls, but not the other 2 that have a number starting with a 1 but are not 1.
The solution is to use Regular Expressions.

In this case you want the assignment to only match urls containing foobar=1 but is either followed by something other than a number or is at the end of the url.

In that case, this assignment should work (with the Regular Expressions option on):

foobar=1([^0-9]|$)

To explain:
(...|...) match any of these possibilities.
[^0-9] match any character that is not a number.
$ match the end of the string.

More on Regular Expressions

For documentation on regular expressions, check out the Regular Expressions Cheat Sheet.

For more info on Regular Expressions: http://www.regular-expressions.info/reference.html
For testing them: http://gskinner.com/RegExrhttp://regexpal.comhttp://www.phpliveregex.com

I want to assign my module to something not available in the assignments

If you are using the FREE version, see if the assignment is available in the PRO version.

In the PRO version there is also the ability to assign by custom PHP code. This gives you the opportunity to assign to just about anything you can think of. You just need to know what PHP code you should use.

With PHP you can call on all data/information available in the variables, url, database, etc. And then do your checks on this data. You can tell the module whether it should be displayed by ending the PHP code with a return true or false based on your checks.

For examples and ready-to-use PHP scripts, check out the PHP Assignment Guide.

Some modules can not be edited with Advanced Module Manager

Some modules (like RocketTheme modules) do fancy stuff in the administrator, causing conflicts with Advanced Module Manager. Stuff like overruling and styling core elements of Joomla, from toggle buttons to whole layouts.

That pretty much means you cannot use Advanced Module Manager to control those modules (until they stop messing with the layouts in the admin).

To access these modules using the core module manager, simply change the url from option=com_advancedmodules to option=com_modules. So you don't have to disable or uninstall Advanced Module Manager to get to those modules.