sql problem [message #396067] |
Fri, 03 April 2009 12:49  |
aarti81
Messages: 235 Registered: December 2007 Location: USA
|
Senior Member |
|
|
Hi All
When i run the following query am getting the below results:
SELECT STG_ITS_EMISSIONFACTOR.OPERATION,STG_ITS_EMISSIONFACTOR.SPEED,STG_ITS_EMISSIONFACTOR.VOC,STG_ITS_EMISSIONFACTOR.CO,STG_ITS_EMISSIONFA CTOR.NOX
from STG_ITS_EMISSIONFACTOR
results:
OPERATION SPEED VOC CO NOX
Operation Speed VOC CO Nox
Indianapolis 0 4.301 24.651 2.048
Indianapolis 1 4.301 24.651 2.048
But when i use the following query am getting the below results :
SELECT STG_ITS_EMISSIONFACTOR.OPERATION,STG_ITS_EMISSIONFACTOR.SPEED,STG_ITS_EMISSIONFACTOR.VOC,STG_ITS_EMISSIONFACTOR.CO,STG_ITS_EMISSIONFA CTOR.NOX,STG_ITS_SEGMENTCATEGORY_LUT.RTDIRNTYMEAS,STG_ITS_SEGMENTCATEGORY_LUT.SEGMENT,STG_ITS_SEGMENTMULTIPLIER.MULTIPLIER
from STG_ITS_EMISSIONFACTOR,STG_ITS_SEGMENTCATEGORY_LUT,STG_ITS_SEGMENTMULTIPLIER
am getting the results as :
OPERATION SPEED VOC CO NOX RTDIRNTYMEAS SEGMENT MULTIPLIER
Operation Speed VOC CO Nox 69 s m 15.7 23 4.69
Operation Speed VOC CO Nox 465 e m 25.1 35 4.69
Operation Speed VOC CO Nox 70 e m 84.7 47 4.69
[Mod-Edit: Frank added code-tags around the results to preserve formatting]
[Updated on: Fri, 03 April 2009 12:53] by Moderator Report message to a moderator
|
|
|
Re: sql problem [message #396068 is a reply to message #396067] |
Fri, 03 April 2009 12:53   |
 |
BlackSwan
Messages: 26766 Registered: January 2009 Location: SoCal
|
Senior Member |
|
|
When I run
SELECT TRUNC(SYSDATE) FROM DUAL
I get
2009-04-03
SELECT stg_its_emissionfactor.operation,
stg_its_emissionfactor.speed,
stg_its_emissionfactor.voc,
stg_its_emissionfactor.co,
stg_its_emissionfa ctor.nox
FROM stg_its_emissionfactor
SELECT stg_its_emissionfactor.operation,
stg_its_emissionfactor.speed,
stg_its_emissionfactor.voc,
stg_its_emissionfactor.co,
stg_its_emissionfa ctor.nox,
stg_its_segmentcategory_lut.rtdirntymeas,
stg_its_segmentcategory_lut.segment,
stg_its_segmentmultiplier.multiplier
FROM stg_its_emissionfactor,
stg_its_segmentcategory_lut,
stg_its_segmentmultiplier
no WHERE clause?
[Updated on: Fri, 03 April 2009 12:59] Report message to a moderator
|
|
|
Re: sql problem [message #396069 is a reply to message #396068] |
Fri, 03 April 2009 13:01   |
aarti81
Messages: 235 Registered: December 2007 Location: USA
|
Senior Member |
|
|
Why should i use the WHERE clause as i'm not filtering any thing, and the tables dont have a field in common.
|
|
|
|
Re: sql problem [message #396088 is a reply to message #396069] |
Fri, 03 April 2009 15:11  |
joy_division
Messages: 4963 Registered: February 2005 Location: East Coast USA
|
Senior Member |
|
|
aarti81 wrote on Fri, 03 April 2009 14:01 | Why should i use the WHERE clause as i'm not filtering any thing, and the tables dont have a field in common.
|
I think you should learn basic SQL before you start to use it. I can remember some of your classic questions. You don't seem to have progressed at all yet.
|
|
|