+ Reply to Thread
Results 1 to 5 of 5

Database query from same worksheet

  1. #1
    Hall
    Guest

    Database query from same worksheet

    I know how to create a database query from another worksheet.

    But can the query be from the SAME worksheet? How is that done?



  2. #2
    Nick Hodge
    Guest

    Re: Database query from same worksheet

    If you want to 'query' data on the same worksheet, I would use Auto or
    advanced filter

    --
    HTH
    Nick Hodge
    Microsoft MVP - Excel
    Southampton, England
    [email protected]HIS

    "Hall" <[email protected]> wrote in message
    news:%[email protected]...
    >I know how to create a database query from another worksheet.
    >
    > But can the query be from the SAME worksheet? How is that done?
    >
    >




  3. #3
    Hall
    Guest

    Re: Database query from same worksheet

    But that's a filter not a query. By query, I'm looking at doing an SQL as
    in querying from an external database. I can do that for external
    worksheets. I'm asking if I can query from the same worksheet. I'm not
    sure you understood my question.

    I hope the response you gave won't keep others from offering an answer.

    "Nick Hodge" <[email protected]> wrote in message
    news:ej%[email protected]...
    > If you want to 'query' data on the same worksheet, I would use Auto or
    > advanced filter
    >
    > --
    > HTH
    > Nick Hodge
    > Microsoft MVP - Excel
    > Southampton, England
    > [email protected]HIS
    >
    > "Hall" <[email protected]> wrote in message
    > news:%[email protected]...
    > >I know how to create a database query from another worksheet.
    > >
    > > But can the query be from the SAME worksheet? How is that done?
    > >
    > >

    >
    >




  4. #4
    Nick Hodge
    Guest

    Re: Database query from same worksheet

    I'm obviously not understanding your question. If you want to query data
    from the *same* worksheet, by definition, the data is already on the
    *worksheet*. If it's already there then you can effectively 'query' the
    data by using autofilter.

    Do you mean from the same *workbook*?

    If the answer to the above is yes, then no, you can build a pivot table from
    the same source, but not a query via Data>Import External Data. If you try
    this, it will get to the final screen, but you will get a syntax error as it
    cannot query from itself

    --
    HTH
    Nick Hodge
    Microsoft MVP - Excel
    Southampton, England
    [email protected]HIS

    "Hall" <[email protected]> wrote in message
    news:[email protected]...
    > But that's a filter not a query. By query, I'm looking at doing an SQL as
    > in querying from an external database. I can do that for external
    > worksheets. I'm asking if I can query from the same worksheet. I'm not
    > sure you understood my question.
    >
    > I hope the response you gave won't keep others from offering an answer.
    >
    > "Nick Hodge" <[email protected]> wrote in message
    > news:ej%[email protected]...
    >> If you want to 'query' data on the same worksheet, I would use Auto or
    >> advanced filter
    >>
    >> --
    >> HTH
    >> Nick Hodge
    >> Microsoft MVP - Excel
    >> Southampton, England
    >> [email protected]HIS
    >>
    >> "Hall" <[email protected]> wrote in message
    >> news:%[email protected]...
    >> >I know how to create a database query from another worksheet.
    >> >
    >> > But can the query be from the SAME worksheet? How is that done?
    >> >
    >> >

    >>
    >>

    >
    >




  5. #5
    Lisa B.
    Guest

    Re: Database query from same worksheet


    On 14-Apr-2005, "Nick Hodge" <[email protected]>
    wrote:

    > Do you mean from the same *workbook*?
    >
    > If the answer to the above is yes, then no, you can build a pivot table
    > from
    > the same source, but not a query via Data>Import External Data. If you
    > try
    > this, it will get to the final screen, but you will get a syntax error as
    > it
    > cannot query from itself


    But it can! I've just started doing this, and it works well. I haven't
    tried querying data from the *same* worksheet, but I have tried querying
    data from the *same* workbook (i.e., query in one worksheet, source data in
    another). Basically, the question here is - can you query an open workbook?
    And, in my experience, you can. I am using Excel 2002.

    The only odd thing I have noticed is that when you set up your query in the
    wizard, you need to check the box for showing "system tables", otherwise MS
    Query will complain that there are no visible tables in the source. This
    weirdness happens, though, whenever I try to use an Excel workbook as
    source, whether it is "external" or not.

    Lisa B.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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