Populatibng excel sheet from access

  • Thread starter Thread starter mjc65
  • Start date Start date
M

mjc65

First post from someone more used to using Access, so please be kind.

I have developed a database containing exam results which should the
be exported to a spreadsheet designed by someone else. the problem is
the fields in the spreadsheet are

Surname | First name | DoB | Entry 1 (0-11) | Entry 2 (12-22) etc.

My problem is merging the data and ensuring the result goes into th
correct cell. We have had a nightmare over the past couple of week
trying to do this without the office link, and I am just wondering i
it is possible to generate the required spreadsheets?

Thanks in advance.

mjc6
 
mjc65 said:
First post from someone more used to using Access, so please be kind.

I have developed a database containing exam results which should then
be exported to a spreadsheet designed by someone else. the problem is,
the fields in the spreadsheet are

Surname | First name | DoB | Entry 1 (0-11) | Entry 2 (12-22) etc.

My problem is merging the data and ensuring the result goes into the
correct cell. We have had a nightmare over the past couple of weeks
trying to do this without the office link, and I am just wondering if
it is possible to generate the required spreadsheets?

You a query, either from Excel or MS Access, aliasing the columns as required e.g.

INSERT INTO
[Excel 8.0;HDR=YES;Database=C:\MyWorkbook].[MySheet$]
(
Surname,
[First name],
DoB,
[Entry 1 (0-11)],
[Entry 2 (12-22)]
)
SELECT
last_name AS Surname,
first_name AS [First name],
birth_date AS DoB,
Col1 AS [Entry 1 (0-11)],
Col2 AS [Entry 2 (12-22)]
FROM
[Database=C:\MyJetDB.mdb;].MyTable
;

Jamie.

--
 
Back
Top