How to add multiple ranges in X++ query code

Please refer to the blog I was reading

http://dynamicsuser.net/ax/f/120/t/71585

I was wondering if I had another filter that is the date range along with the accountNum, how will I incorporate two ranges. Moreover also I have more than one table as a datasource. How will I get it to work?
I am new to ax, your help is appreciated.

Thanks