User Profile

Collapse

Profile Sidebar

Collapse
piyush12345
piyush12345
Last Activity: Nov 30 '11, 08:45 PM
Joined: Nov 17 '11
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • Sorry I forgot to mention that there are multiple records with silar data I want the unique data(With Latest LocalDataTime) for each site -

    I just executed the following query - SELECT TOP(61) S.DataValue AS 'Wind_speed',
    D.DataValue AS 'Wind_direction ',
    Sites.SiteCode,
    Sites.Longitude ,
    Sites.Latitude
    FROM DataValues S JOIN DataValues D...
    See more | Go to post

    Leave a comment:


  • It's not an aggregate query... I was just trying random stuff...

    my two queries are

    SELECT TOP(61) DataValue as 'Wind_speed', Sites.SiteCode, Sites.Longitude , Sites.Latitude, DataValues.Vari ableID, DataValues.Site ID
    FROM DataValues INNER JOIN Sites ON DataValues.Site ID = Sites.SiteID
    WHERE DataValues.Vari ableID = 3

    SELECT TOP(61) DataValue as 'Wind_direction ', Sites.SiteCode, Sites.Longitude , Sites.Latitude,...
    See more | Go to post

    Leave a comment:


  • Sorry, didn't get you, I don't know how to use pivot but tried to join two qierues but it didn't work,

    Here's my failed query-

    Select speed.DataValue AS 'Wind_speed', direction.DataV alue AS 'Wind_direction ', Sites.Latitude, Sites.Longitude , Sites.SiteCode
    FROM DataValues AS speed
    INNER JOIN DataValues AS direction ON speed.SiteID = direction.SiteI D
    INNER JOIN Sites ON speed.SiteID = Sites.SiteID
    ...
    See more | Go to post

    Leave a comment:


  • Problem with a complex SQL Query for SQL Server

    Hi,

    I want to do something like this -

    Get Wind_direction, Wind_speed, SiteCode, Latitude, Longitude side by side-

    The problem is that (DataValue as wind_direction) Wind_direction and (DataValue as)wind_speed are under the same column DataValue and for Wind_direction variableID is 4 and for Wind_speed is 3

    the schema can be found here (Fixed to show instead - NeoPa)

    And here's the query...
    See more | Go to post
    Last edited by Niheel; Nov 18 '11, 01:14 AM. Reason: Added mandatory [CODE] tags for you and showed pic in post

  • Accessing comma separated data from an javascript array object

    I have a global array to which I provide data from one function and want to use that data into another function.

    i.e. i get the values of sitecode, x and y from function A
    siteCode = x = y =

    windQueryDataAr ray = [[siteCode, x, y]];

    I want to use this array in function B from which I want to compare value of siteCode with site code value I am getting from another...
    See more | Go to post
No activity results to display
Show More
Working...