2

Every month I have to fill in an Excel template with data from some database, that is I have to fill in about 100 cells.

I wrote SQL queries and I don't know is there any way that I could get that data into the Excel template other than copy/paste?

slhck
  • 235,242
paunic
  • 21

1 Answers1

1

In the Data tab in the ribbon, click on the From Other Sources tab. Choose Sql Server.

Type the name of the SQL Server computer in the Server name box.
Under Log on credentials, do one of the following:
a. To use your current Microsoft Windows user name and password, click Use Windows Authentication.
b. To enter a database user name and password, click Use the following User Name and Password, and then type your user name and password in the corresponding User Name and Password boxes.

You can also paste in your SQL query via the Properties tab (after a connection is set up, under the connections pane).

More details

Dave
  • 25,513