If you want to build a report that uses multiple databases of any type, you need to create a data source for each database (refer to instructions in this knowledgebase to find information on configuring your specific type of data sources).
Once your data sources are configured, you can specify separate connections in both the NL and the GL functions. You can change the connection that the NL function uses by specifying "DataSource=" as a filter field and the data source name as a filter.
When creating an NL function with the Jet Function Wizard (Jfx), you select "DataSource=" from the available keyword list:
The Jet Browser will do this automatically if you are dragging and dropping from a connection that is not the default (the connection currently listed on the Jet Ribbon):
The GL function has a separate parameter that will accept the connection name.
The following example sums the amounts from Purchase Invoice number 1000 from both a Dynamics NAV database and a Northwind Access database.
=NL("First","Purch. Inv. Header", "Amount", "No.", "1000", "DataSource=", "NAV 2013")+NL("First","Orders","Amount","OrderID","1000","DataSource=","NorthWind")
In the example, there is a data source named NAV 2013 that connects to a Dynamics NAV database and a data source named NorthWind that connects to the NorthWind Access database.
An important point to notice is that if you and a colleague both use the same report, you need to name your connections the same thing (either through shared data sources - using the Jet Service Tier - or by using identical local settings).