Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

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

Search results for query: *

  1. dbenoit64

    coorelated sub query with group by

    there are 2 problems with this query: select DATABASEST storm_num, max(maxwind_kt) max_wind_speed, datediff(dd, min(convert(datetime, [date],104)), (max(convert(datetime, [date],104)))) duration_days, count(*) as num_tracks, (SELECT TOP 1 [NAME] FROM NHCBestTracks1851To2001$ where...
  2. dbenoit64

    coorelated sub query with group by

    I've got an sql statement that ive developed for an application which has been giving back incorrect results for the past few months and ive finally figured out why but cant figure out how to fix it. Anyways, Here it is: ***************************** SELECT DATABASEST AS storm_num...
  3. dbenoit64

    OLEDB provider for sql server timeout expires

    1)There are no syntax errors 2)Im using the newest OLEDB driver for sql server. NOT ODBC The discussion you suggested doesnt really apply to my situation. I still tried those fixes in vain but no luck. 3) Im not actually selecting *, i just kind of threw that in there to cut down on the...
  4. dbenoit64

    sql server timeouts on remote server query

    Im running 3 distributed sql querys on a linked server (sits in a different province) through an asp page. Both databases are Sql Server the select staments both kind of look like the following: select * from openquery(MON, 'SELECT vmv_lab_code, variable_name as variable, method_code as...
  5. dbenoit64

    do a grouping of results from a group by statement

    IM no expert in writing sql statemsnt but ive finally got to one point that in needed to get but now i must do summarys on an existing query ive created: The Following sql statement: ____________________________________________________________ select DATABASEST storm_num, max(maxwind_kt)...
  6. dbenoit64

    Selecting non aggregate values within an aggregate sql statement

    okay ive got the statment almost perfect select DATABASEST storm_num, avg(systemspee) avg_trans_speed, max(maxwind_kt) max_wind_speed, datediff(dd, min(convert(datetime, [date],104)), (max(convert(datetime, [date],104)))) duration_days, (SELECT TOP 1 PRESSURE_M FROM...
  7. dbenoit64

    Selecting non aggregate values within an aggregate sql statement

    the storm data in the database are ordered by 6 hour tracks. so a storm can have multiple rows and at each 6 hour segment, pressure, yearlystormnum, date/time at strongest wind - can change with each interval. and the values i want are those that correspond to the touple where the strongest wind...
  8. dbenoit64

    Selecting non aggregate values within an aggregate sql statement

    I have a table of storm info that has multiple rows for each storm. I need to do a group by storm number (databasest). For each storm, i need to select the max of the max wind speed max(maxwind_kt), the average system speed (avg(systemspee)), I have to write an sql statement where i select...

Part and Inventory Search