not logged in login | register
Docs:
Up
Since you can query the spectrum database using SQL query, you should get familiar with the database structure. Our database server uses the T-SQL 92 standard query language, so joins and aggregate function can be used. Text fields are stored in two-byte unicode.
Note! If you use the WebService to return data in a VOTable format, you are allowed to use SELECT [column[, column ...]] format to specify the columns to return. When using the web form or the webservice, but you want the results in a SOAP object format, you always have to use SELECT * (star) instead of a column list.
We implemented a SQL preparser to allow using predefined constants in queries. These constants are detailed at the description of each column in parentheses. All of these constants are upper case!
This table contains spectrum header information
Column name
Data type
Description
ID
bigint (8)
Primary key of the Spectra table
Name
nvarchar (255)
Name of the spectrum
ntext
Long description of the spectrum
UCD
Universal Content Descriptor
Ra
float (8)
Right ascenation in J2000
Dec
Declination in J2000
Cx
Cy
Cz
HtmlID
HTM id calculated from the coordinates
Synthetic
bit
Z
real (4)
Redshift of the object
ZError
Absolute error of redshift of the object
ZStatus
smallint (2)
ZWarning
int (4)
ZConfidence
Class
Class of the object 0: Unknown (UNKNOWN) 1: Star (STAR) 2: Galaxy (GALAXY) 3: Qso (QSO) 4: Hiz_Qso (HIZ_QSO) 5: Sky (SKY) 6: Star_Late (STAR_LATE) 7: Gal_Em (GAL_EM) 101: Merger (MERGER) 102: BrightStarHalo (BRIGHTSTARHALO)
SurveyID
ID of the survey from which the spectrum comes. Foreign key to the Surveys table. 1: SDSS DR1 (SDSS) 2: 2dF GRS (2DF) etc.
ObjectID
ID of the object in the original survey catalog
DateMeasured
datetime (8)
Date of exposition
DateCreated
Date of registration into the database
DateModified
Date of last modification
WavelengthMin
Minimum of the wavelength interval
WavelengthMax
Maximum of the wavelength interval
WavelengthScale
Wavelenght scale 0: Linear (LINEAR) 1: Logarithmic (LOGARITHMIC) 2: Other (OTHER)
ValueUnitID
Unit of spectral data. Foreign key to the SpectrumValueUnits table 1: Jy (10e-17 erg/cm^2/s/A) - calibrated 2: counts - uncalibrated
Public
UserFolder
Indices on the Spectra table
Index name
Columns
PK_Spectra
Primary key, Unique
IX_Spectra_HtmID
HtmID
This table contains the spectra's custom key pairs. The SpectrumID column determines the corresponding row in the Spectra table and should be used for join queries. Since each value can be either numeric or textual, use the appropriate field when writing queries. The value type is recognized by the web service and stored in the NumValue or StringValue field, the other field is always NULL.
SpectrumID
Foreign key to the Spectra table
NumValue
Numeric data
StringValue
nvarchar (50)
Textual data, or storing unit if NumValue is not null
Indices on the SpectrumPoints table
FK_SpectrumKeys_Spectra
SpectrumID -> ID
Foreign key
This table contains the spectra's wavelength-value pairs. The SpectrumID column determines the corresponding row in the Spectra table and should be used for join queries. The unit of the values is determined by the ValueUnitID int the Spectra table. Since the database stores uncalibrated spectra too, be sure to use calibrated spectra only (ValueUnitID= 1, Jy) when calculating magnitudes.
Wavelength
Wavelength in Angstroms
Value
Spectrum value. See notes above!
Error
Error of value
Mask
Gives extra information about the validity of value at the given wavelength, following the SDSS convetions. *** more doc needed ***
FK_SpectrumPoints_Spectra
The table contains the common spectrum value units.
Primary key on the table
Text
Written form of the unit
Calibrated
Flag for calibrated values (can be used for magnitude calculation)
Indices on the SpectrumValueUnits table
***
This table contains the name of different surveys from which we loaded spectral data. The table contains only surveys loaded at JHU, other users should use SurveyID = 0.
Name of the survey