Cooking with Sloan: Stars: Find Stars with Multiple Observations
 
DR7 Help
 Site News
 Introduction
 Cooking with Sloan
     - General
     - Solar System
     - Stars
     - Galaxies
     - QSOs/Cosmology
     - Teaching/Labs
 FAQ
 
 Query Form Guide
 SQL Tutorial
 SQL in SkyServer
 Sample SQL Queries
 Query Limits
 Searching Advice
 
 Archive Intro
 Table Descriptions
 Schema Browser
 Glossary
 Algorithms
 Web Browsers
 
 Download
 Data Publications
 API
 SkyServer Sites
 
 Contact Help Desk
Multiple Observations

Back to Stars index

Search with SQL (open in new window)


  1. Go to the SQL Search tool (link opens in new window). To get there from the astronomers' main page, look under Search Tools. To get there from the public main page, look under SkyServer Tools, then Search. Or, you can practice the query in the query box at the bottom of this page.

  2. In the main window, type the following query (note that lines preceded by -- are comments):

    SELECT top 100 h.objid, m.objid2 -- return object IDs of both observations
                                                 -- for 100 objects
    FROM matchhead h, match m      -- from "match" tables
    WHERE h.objid = m.objid1           -- observations match between tables
        AND h.matchcount > 1           -- more than one observation
        AND m.type1 = 6                   -- observation 1 is of a star
        AND m.type2 = 6                   -- observation 2 is of a star

    The query returns the object ID of each observation of the star, for 100 stars.

  3. To learn more about each observation of the star, you will need to go to another tool. Save the object ID of each observation; you will need it to find the observations later. One way to save the object IDs is to request the query results as CSV, then save the resulting CSV file to your machine.

Use the query box below to practice running the query shown above. You can modify the query to return other data if you want. Click Submit to run the query or Reset to reset the query box.

 

Format HTML XML CSV

Enter your SQL query in the text box. The query is limited to 10 minutes and 100,000 rows.


Next: Explore the observations of each star

 Go to the previous page Go to the next page

Back to Cooking with Sloan main page
Back to Help main page
Contact Help Desk