sql query

  1. G

    Update sql query parameter from excel cell

    Hi, I have a sql query stored in power query. I have managed to change some of the settings of that query with values from the excel sheet. For instance I stored a value 1, or a text chain in excel cell so that I can update my query without using VBA. However, some of the parameters I need to...
  2. S

    SQL Query Question

    This question is a little off topic but the users on this form have helped me out a lot with my VBA so I was hopeful someone could answer an SQL question. My company uses a SQL server to log all of the events that happen on a piece of equipment every day. Each day the server creates a new...
  3. R

    Odbc/sql server access in Excel - repeatedly asking for password

    Hi, I have created a macro which creates a SQL Server connection and returns data as requested - this works fine, however, my macro involves running the same code a number of times - also works fine, just with different connections - still all working! However, because I am making a number of...
  4. B

    Union SQL and Excel Data

    I currently have two data sources 1 A SQL Data table 2 An Excel data table Both tables have the same fields. Is there a way of unioning them in MSQuery so I can return all the results in one table? I had a go below but it didn't like it SELECT * FROM "dbo"."VMS_Nominal_SUMMARY" UNION ALL...
  5. J

    SQL Queries in Excel

    I have the following seven Access queries that I need to convert into an Excel macro because there is not a lot of data in the two source tables and my coworkers are more comfortable working in Excel than Access. I am not sure of how to write the VBA around these SQL queries so that it will run...
  6. A

    execute multiple mySQL statements at once

    I am working on some code that needs to add data into a database. I have no problems adding data when I am trying to execute one SQL statement at a time. My problem comes in when I attempt to execute 2 or more SQL statements at once. I know my syntax is correct, as I am able copy the value of...
  7. O

    RunTime Error 1004 Invalid Object Name when connection to SQL Server Database

    Hi, I've searched the forum and not found any posts reporting this problem. When running a QueryTable command in VBA I keep getting the error: RunTime Error 1004: Invalid object name: 'MyDatabase.Data.Amount_Source' What I cannot understand is that when I copy the SQL Query Command Text...
  8. Avatar

    Excel VBA + Massive Array + SQL INSERT = HELP!

    Greetings, I have an array (dimensions: 1.5mil,14) containing data entries that i need to INSERT into an Access 2003 table. I am hoping to do this as a single SQL string... Is this possible? below is the code in a nut shell. Sub sbRun() Dim aryDataSet() Dim i As Long, _ lngTopRow As...
  9. Dan DeHaven

    End a BackgroundQuery of a ListObjects SQL Query?

    I'm using Excel 2010 to pull data via a Worksheets ListObjects with an ODBC connection to a SQL Server. I haven't had problems with this till I ran into an empty record set. In the case of no records Excel continues to Refresh the external query and displays this in the bottom left corner of the...
  10. B

    SQL query using list of numbers in a sheet

    Good Afternoon, I have a simple .xlsm book into which users can paste a list of file numbers and when run, the macro reads each file number, one at a time, and runs a query against a SQL DB and then pastes the results back into the book. Is there a way to read all of the file numbers...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top