Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. rclawson

    Referring to a Computed column in WHERE clause

    Thanks. That looks like that will do the trick. RC
  2. rclawson

    Referring to a Computed column in WHERE clause

    Is it possible to do something like this? select (BillPrefix + ' ' + BillNumber) as Bill from Bills where Bill like 'HF 3%' I get an error when I execute this, but I want to be able to do a partial match over both columns. Is this something that could be done with a dynamic view (i.e., in the...
  3. rclawson

    Optimizing Complex Query

    Dieter, Thanks for the response. This query also works great. It took my full query down from 1:22 to 18 seconds; much better than before. I will probably go with PH's query as the performance gain is better. Thanks again. Rob
  4. rclawson

    Optimizing Complex Query

    PH, Thanks! That approach works great. It took my full query down from 1:22 to only 9 seconds. This should work great in my view. I have not worked much with derived tables in the FROM clause. I see it definitly bears further investigation. Thanks again. Rob
  5. rclawson

    Optimizing Complex Query

    Dieter, This is close. Let me clarify a few things to better define the problem. Here are some updated sql statements: create table ActivityHistory( BillRequestID int not null, ActivityCode int not null, Pos int not null, SentToID varchar(15) not null, primary key (BillRequestID...
  6. rclawson

    Optimizing Complex Query

    PH, Thanks for the reply. I have tried the simple inner join, but because of the complexity of the where clause, the inner join is not sufficient. Thanks, RC
  7. rclawson

    Optimizing Complex Query

    I'm needing some help optimizing a query. The following simplified query returns the results that I need, but the performance is terrible. Here is a simplified view of my data: Table: BillRequests BillRequestID ------------- 1 2 3 4 Table: ActivityHistory...

Part and Inventory Search

Back
Top