Fewer connections to unittest db.
Generate better queries for empty collections.
Re-enable Null/Not Null constraints on refs/cols in query builder.
Prevent classes being added to the FROM list without being joined to anything.
Initial tests for null/not null references and collections.
Parially complete code to make NULL/NOT NULL constraints work with outer joins.
Make NULL/NOT NULL constraints work on refs/cols that are also outer joins.
We can create constraints in all situations now.
Merge branch 'beta' into i54

Conflicts:
	intermine/api/main/src/org/intermine/api/query/MainHelper.java
Remove quoting of index fields that contain upper case characters, this was causing problems with simple objects.
Merge pull request #711 from rnsmith/i54

I54
Merge pull request #729 from rnsmith/i714

Remove quoting of index fields that contain upper case characters, this ...
merge beta into branch
Merge branch 'emma' of github.com:intermine/intermine into emma
Fix compilation error.