+ Reply to Thread
Results 1 to 4 of 4

For each Row query SQL...

  1. #1
    Registered User
    Join Date
    08-11-2013
    Location
    Canada
    MS-Off Ver
    Excel 2003
    Posts
    2

    For each Row query SQL...

    Hi there,

    I have been searching for hours this morning and perhaps my search query is not correct however I can't seem to find the answer I am looking for.

    The hope is to have an excel worksheet that retrieves from a SQL connection on a row by row basis. So for example in Column A I would have a "Job No." and then column B would be the job status and column C would be the current job PM, but column A would be hand typed in and column B and C would be retrieved from the database.

    I can create a SQL Query and add a parameter to it however I can't make it row dependent.


    Sorry if this has been asked before, any help is greatly appreciated.

    t

  2. #2
    Forum Contributor
    Join Date
    08-11-2012
    Location
    bengalur
    MS-Off Ver
    Excel 2003, 2007
    Posts
    152

    Re: For each Row query SQL...

    Have you used Activex Data Objects Library to connect to the data base.

    Once data entering is completed in the A column then Connect to data base, Retrieve data from Table and insert in the columns in the B and C.

    Please let me know if you need some more info.

    ________________________________________________________________________________________________________________________________________
    Please click * to add reputation if this answer has helped

    “I have not failed. I've just found 10,000 ways that won't work.”
    ― Thomas A. Edison

  3. #3
    Registered User
    Join Date
    08-11-2013
    Location
    Canada
    MS-Off Ver
    Excel 2003
    Posts
    2

    Re: For each Row query SQL...

    Thanks. I'll give it a try.

    t

  4. #4
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: For each Row query SQL...

    Why not import the entire table into Excel?

    Then you could use VLOOKUP or other formulas to pull the job status and current job from the import based on what's entered in column A.
    If posting code please use code tags, see here.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 2
    Last Post: 02-01-2013, 04:21 PM
  2. [SOLVED] Loop through list, perform web query and save each query on its own page
    By anrichards22 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-07-2012, 07:50 AM
  3. Problem with selecting range with in query table after query refresh
    By shooter in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-31-2012, 11:55 AM
  4. Web Query - Change a word in query to form a new query
    By scottymelloty in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-25-2011, 04:13 AM
  5. Save data retreived from query without saving query
    By Anthony in forum Excel General
    Replies: 0
    Last Post: 01-25-2006, 03:20 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1