Access.2007.VBA.Bibl..

(John Hannent) #1
Forms based on tables, or queries that were successfully upsized, will look the same in the project
as in the original database (see Figure 18.44).

FIGURE 18.44
A form in an Access project displaying data from a SQL Server table.

If you attempt to upsize queries as well as tables, you will find that some query types don’t upsize
at all, because they don’t match up with views or stored procedures in SQL Server. Crosstab
queries, for example, can’t be upsized at all, nor can any query that uses a function in a calculated
field expression. If a query isn’t upsized, you need to re-create it as a SQL Server object of the
appropriate type (view or stored procedure).

See the SQL Server 2005 Bible(Wiley, 2006) for more information about working with
SQL Server features such as stored procedures and user-defined functions.

Figure 18.45 shows the four queries in the original Basic Northwind.mdb database that were suc-
cessfully upgraded to SQL Server.

The first two queries were converted to views and the third and fourth to user-defined functions, as
indicated by their distinctive icons. Figure 18.46 shows the qryOrderSubtotals view in design view,
and Figure 18.47 shows the qryCurrentProductList user-defined function in SQL view.

You now have a client/server application consisting of an Access project front end and a SQL Server
back end; from this point on you will need to use SQL Server techniques to work with the project
and the back-end tables.

CROCROSSSS-REF-REF


Part III Adding More Functionality to Office

Free download pdf