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 SkipVought 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. huddles

    update first record found

    Hello, I have the following query that finds all records which have count(col_A) > 1 and stat = '5'. SELECT DISTINCT TOP 100 i1.egc_id,i1.stat FROM dbo.table i1 INNER JOIN dbo.table i2 ON i1.egc_ID = i2.egc_ID GROUP BY i1.egc_ID, i2.egc_ID,i1.stat HAVING...
  2. huddles

    SQL Query

    I have tried the Report...Options Select Distinct, but this does not seem to work.
  3. huddles

    SQL Query

    ok, think I am almost done. I created a view, as mentioned by James. The report is looking quite sharp, except for this last issue, so one more push and this baby is over the cliff. I feel like Sisyphus. The report now stands at: The report prints this out: QTY Col_B Col_A...
  4. huddles

    SQL Query

    sure, here it is SELECT Packing_List."TRNS_NBR", Packing_List."RGST_ID", Packing_List."ITM_ID", Packing_List."STYLE_ID", Packing_List."CHAR_VALUE_1", Packing_List."CHAR_VALUE_2", Packing_List."CHAR_VALUE_3&quot...
  5. huddles

    SQL Query

    PAJR I have succeeded in adding the view as a table, and it joins nicely on the Itm_id. When preview, I get the following error The column prefix 'vPacklistUpc' does not match with a table name or alias name used in query. any thoughts?
  6. huddles

    SQL Query

    pajr, you may be on to something. I have created the view, and it display what I need, but I just can't seem to get Crystal to let me see it as a table. I see another view (created a while ago) as a valid table, but not this new one. I have refreshed SQL Server, as well as through Crystal...
  7. huddles

    SQL Query

    sorry, I have the view created, but do not know how to use this with Crystal
  8. huddles

    SQL Query

    James, I have created the view, and it works just lovely. From the above thread, I the following: Col_A Col_B 12345 88 88 88 999 999 777 777 444 35 35 35 The report prints this out: QTY Col_B Col_A Header4 Header5 1 88...
  9. huddles

    SQL Query

    sorry mate, same message with either sum or maximum. I have the CDbl on all instances of Col_A or Col_B.
  10. huddles

    SQL Query

    sorry Reebo, no dice. I now get a "summary/ running total could not be created" Frustrating for something that seems so simple.
  11. huddles

    SQL Query

    Hello Reebo, unfortunately the Col_A and Col_B are varchar type, and I get a warning that number is required right after the "IF"
  12. huddles

    SQL Query

    Lisa, and others. I must apologize. There will be time whwre the Col_A and Col_B values will be a 1:1 situation, such as Col_A Col_B 12345 88 88 88 999 999 777 777 444 35 35 35 What I need to see is 12345 999 777 444 Therefore if count(Col_A) >...
  13. huddles

    SQL Query

    Hello, Even with the suppress, the Crystal Code is as follows: SELECT Packing_List."TRNS_NBR", Packing_List."RGST_ID", Packing_List."ITM_ID", Packing_List."STYLE_ID", Packing_List."CHAR_VALUE_1", Packing_List."CHAR_VALUE_2&quot...
  14. huddles

    SQL Query

    Dtaylor, thank you. The report uses one database, and two tables. It gets an item from table1. Table two is joined on the common item record (Col_B). The second table has this structure: Col_A Col_B 12345 88 88 88 The query I have derives the unique number. I have a column in...
  15. huddles

    SQL Query

    I need to enter a sql query for a field. I have the following query, which will populate the field. How do I enter this or the equivalent? SELECT distinct i1.scan_id FROM item_xref i1 join item_xref i2 on i1.itm_id = i2.itm_id WHERE i1.scan_id <> i2.itm_id It essentially queries the...

Part and Inventory Search

Back
Top