ODBC - running SDB

Hi

I'm trying to run a SDB query for sales invoices, some of these invoices are raised through SAGE via the INVOICES AND CREDIT MODULE and then we have

those imported from other software. Can anyone advise best way to do or should I be looking at running a nominal ledger query of sort any help would be appreciated.

thanks