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 biv343 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: *

  • Users: GISql
  • Content: Threads
  • Order by date
  1. GISql

    Autonumbering in update per order

    Hi, I have orders with unique numbers. These orders have orderlines. How can I do an update query to update all order lines in a table to autonumber all lines from 1 to n? Background info: I have orderlines. Some have to be summed and combined to one order line. I get these plus others in a...
  2. GISql

    How to build special where clause based on parameter value?

    Hi, I have a parameter called @Type. This parameter can have different values, like 'STOP', 'START', etc. Based on this value I have to built different where clauses LIKE when 'STOP' I have to set: "WHERE STATUS = 0", while when it's 'START' I have to set: "WHERE CHECKED_OUT = 0" What is the...
  3. GISql

    Better to split procedure?

    Hi, I have the following question: My SP has a paramter @GROUP_MODEL, and based on this value, a different query will be built, for example: IF @GROUP_MODEL = '1' begin set @sql = 'SELECT MO.MODEL_TYPE AS SORTGROUP_3, ' + 'Max(M.SORTGROUP_2) SORTGROUP_2, ' /*'''0'' AS...
  4. GISql

    dynamic column without building sql string

    Hi, I have a parameter called @version which can be 1, 2, 3, 4, 5 I have 5 columns in my table, price_1, price_2, etc. I have a stored procedure to get a price which has a parameter called @version So depending on the value, I have to get price_1, _2, etc. Right now I build an SQL string and...

Part and Inventory Search

Back
Top