Wrong o/p giving

Hi Below query is giving different o/p in different versions (I'm trying on both 10g and 11g)
On 10g it gives me correct o/p i.e correct tablespace utilisation is giving and 11g is not giving correct o/p. i.e wrong tablespace utilisation is giving
What I have analyzed is 'decode' in the statement is doing the trick.
Can some help me please?
select 'Used space for '|| a.tablespace_name|| ' in ORACL is',
round(100*(SUM(a.bytes)/1024/1024 - round(c."Free"/1024/1024))/(SUM(decode(b.maxextend, null, A.BYTES/1024/1024, b.maxextend*8192/1024/1024))))  "UPercent" ,'%'
from dba_data_files a, sys.filext$ b, (SELECT d.tablespace_name , sum(nvl(c.bytes,0)) "Free"
FROM dba_tablespaces d,DBA_FREE_SPACE c where d.tablespace_name = c.tablespace_name(+)
group by d.tablespace_name) c where a.file_id = b.file#(+) and a.tablespace_name = c.tablespace_name
having round(100*(SUM(a.bytes)/1024/1024 - round(c."Free"/1024/1024))/(SUM(decode(b.maxextend, null, A.BYTES/1024/1024, b.maxextend*8192/1024/1024))))>=70
GROUP by a.tablespace_name, c."Free"/1024
order by round(100*(SUM(a.bytes)/1024/1024 - round(c."Free"/1024/1024))/(SUM(decode(b.maxextend, null, A.BYTES/1024/1024, b.maxextend*8192/1024/1024)))) desc

user4587979 wrote:
Hi Below query is giving different o/p in different versions (I'm trying on both 10g and 11g)
On 10g it gives me correct o/p i.e correct tablespace utilisation is giving and 11g is not giving correct o/p. i.e wrong tablespace utilisation is giving
What I have analyzed is 'decode' in the statement is doing the trick.
Can some help me please?
select 'Used space for '|| a.tablespace_name|| ' in ORACL is',
round(100*(SUM(a.bytes)/1024/1024 - round(c."Free"/1024/1024))/(SUM(decode(b.maxextend, null, A.BYTES/1024/1024, b.maxextend*8192/1024/1024))))  "UPercent" ,'%'
from dba_data_files a, sys.filext$ b, (SELECT d.tablespace_name , sum(nvl(c.bytes,0)) "Free"
FROM dba_tablespaces d,DBA_FREE_SPACE c where d.tablespace_name = c.tablespace_name(+)
group by d.tablespace_name) c where a.file_id = b.file#(+) and a.tablespace_name = c.tablespace_name
having round(100*(SUM(a.bytes)/1024/1024 - round(c."Free"/1024/1024))/(SUM(decode(b.maxextend, null, A.BYTES/1024/1024, b.maxextend*8192/1024/1024))))>=70
GROUP by a.tablespace_name, c."Free"/1024
order by round(100*(SUM(a.bytes)/1024/1024 - round(c."Free"/1024/1024))/(SUM(decode(b.maxextend, null, A.BYTES/1024/1024, b.maxextend*8192/1024/1024)))) desc
For you own sanity, you really should format your code. For the sanity of those from whom you seek assitance, you should preserve that formatting with use of the \ tags;SELECT 'Used space for ' || a.tablespace_name || ' in ORACL is',
ROUND (
100
* (SUM (a.bytes) / 1024 / 1024 - ROUND (c."Free" / 1024 / 1024))
/ (SUM (
DECODE (b.maxextend,
NULL, a.bytes / 1024 / 1024,
b.maxextend * 8192 / 1024 / 1024))))
"UPercent",
FROM dba_data_files a,
sys.filext$ b,
( SELECT d.tablespace_name, SUM (NVL (c.bytes, 0)) "Free"
FROM dba_tablespaces d, dba_free_space c
WHERE d.tablespace_name = c.tablespace_name(+)
GROUP BY d.tablespace_name) c
WHERE a.file_id = b.file#(+) AND a.tablespace_name = c.tablespace_name
HAVING ROUND (
100
* (SUM (a.bytes) / 1024 / 1024 - ROUND (c."Free" / 1024 / 1024))
/ (SUM (
DECODE (b.maxextend,
NULL, a.bytes / 1024 / 1024,
b.maxextend * 8192 / 1024 / 1024)))) >= 70
GROUP BY a.tablespace_name, c."Free" / 1024
ORDER BY ROUND (
100
* (SUM (a.bytes) / 1024 / 1024 - ROUND (c."Free" / 1024 / 1024))
/ (SUM (
DECODE (b.maxextend,
NULL, a.bytes / 1024 / 1024,
b.maxextend * 8192 / 1024 / 1024)))) DESC

Similar Messages

  • Reporting the Same Score Regardless of Right/Wrong

    Hi everyone,
    This is a very odd request...my client, for some reason, wants to report the same score for the quiz regardless of whether it's right or wrong.
    So, if the learner gets the correct answer, they get 1 point. If they get it wrong (even after giving them 2 attempts), they still want it to report 1 point.
    It sounds like they don't want to change it to 0. I've already offered that as a solution.
    They want the pass/fail settings to report 0%.
    This request doesn't make any sense to me. It completely goes against the point of reporting a score.
    Any ideas on how I should address this with them and give the same score regardless of right/wrong answers?
    Thanks,
    Kristen

    Hi everyone,
    Rod, the client wants to give a percentage. They don't care about the score. And as much as I question their request, I was asked to just research potential solutions and not question it. Frustrating, I know.
    Lieve was able to give me two solutions offline that they will consider. Thank you, Lieve!
    I can't give them unlimited attempts. The client has made it VERY clear that they only want to allow 2 attempts. And they also don't want to rely solely on slide views...they would like for it to report the same score for every learner that basically shows they attempted to answer the question (right or wrong).
    Thanks everyone!
    Kristen

  • Weird! What am I doing wrong?

    I am working on a project for church - I have been going fine with it. I am adding "cutshots" to a broadcast and everytime I mark in/out and try to drag it to the timeline, it only brings down the audio - no video. It was working a few minutes ago - what happened? Did I click something?

    well the first thing you're doing wrong is not giving an specific description of your problem in the subject line. You'll get more help if you do this.
    More than likely you've undone the "patching" for the video between the source and destination. Look at the left side of the timeline to the left of the lock icon. Make sure the appropriate video source and destination patches are connected.
    This is very basic stuff. You might want to spend some time with the tutorials and manuals to get a better grasp on the program.

  • Problem in Idoc creation in ME22N

    Hi All,
    We are facing a problem in Idoc creation in transaction ME22N.Our requirement is to trigger an output type and create a idoc everytime a change is made to a particular Purchase Order.
    Presently however,for some vendors,when we change the plant at the item level,an Idoc is not created(with a message that the changes are not relevant to create an Idoc).Any other change to the Purchase Order like changes in quantity or price,results in successful Idoc creation.
    We have also noticed that this happens only in the case of certain vendors.The Customer Info records and vendor data are all believed to be fine.
    Are any other config settings required to be maintained for this?
    Thanks in advance!
    Regards,
    Nejuma Iqbal

    Hi Nejuma,
    I don't think there is any problem with cofiguration settings.u r getting the idocs for some vendors .
    if iam not wrong u r giving LS in the tcode(we20).The method which u r using is change pointers.As u r using standard idoc all the settings will be done.
    Only settings u have to do is
    1>generate partner profiles(WE20)
    2>Distribute model view(BD64).
    REGARDS,
    Nagaraj

  • External hard drive music folder

    While upgrading to iTunes 6.0.2 I must have done something wrong. iTunes kept giving me the message "The song "xxxxx..." could not be used because the original file could not be found". I have about 10,000 songs on my external HD. I followed the directions on moving your iTunes music folder as suggested by the Apple info article. I created a new folder, selected the Keep iTunes music folder organized, consolidated, etc. However, many of my songs did not copy over the new folder. If an album had, for instance, 14 songs in its folder, only 6 or 7 songs copied over. Some of the folders that contained an artist's complete album / cd did not copy over at all. I went through my previous music folder and the new one I created and copied everything over manually. I hope I got all the music. Now that I hope that all my music is in one place / folder on my external HD, is there anything I can do to get iTunes on my mac mini to recognize the path to the external HD and recognize all the songs there?

    Main Menu>File>Add to Library...?

  • Inventory values

    Hi experts,
    I have loaded inventory data by installing standard objects from
    business content and then included some fields into cube and as per the fields included,changed the infosource,transfer rules and update rules and then loaded the data.As per my knowledge the data flow is fine.
    When i see the data in the cube some of the field values are appearing differently like:
    In r/3 for a particular materail and plant for a particular month
    the values of issued quantity are 1164.40- and 465.76-(should appear in the cube in the field Value issued from valuated stock).And value of receipt quantity is 176 ( should appear in the cube in the field Value received into valuated stock) .
    But in the cube, 1164.40- and 176 are appearing in the Value received into valuated stock and 465.76 is appearing in
    Value issued from valuated stock.Actually 1164.40- should also appear in the Value issued from valuated stock.
    My requirement is 1164.40- should go to Value issued from valuated stock and also like 465.76 it should also be displayed as postive value in the value issued from valuated stock.
    Only for some materials it is showing like this i.e for which blocked stock, quality stock, transfer posting etc are maintained.
    And also same with the quantities.
    Can any guide me how to proceed to solve this ?
    Bhadri M.

    Hi
    i have loaded the Opening stock from BX and then i have loaded the BF with movements and i have done the right compression sequence as well...
    but when i check my cube its giving right movements which are same as r/3 but the report value is wrong like its giving negative values actually i don't have any value for 30-03-2007 my values in the cube start from 31-03-2007 but i have a negative value in displaying on 30-03-2007 where as this date is not available at all in my cube ....
    what could be the reason
    thanks and regards
    sreedhar

  • Buzzing Sound from Powerbook G4

    I'm experiencing this problem with my Powerbook G4. The problem has been occurring pretty much ever since I owned the machine, and it's driving me up the wall!!
    Whenever the machine is using some sort of Firewire Audio device it emits a loud buzzing/scraping sound, coming from under the left hand speaker. The buzzing gets worse when I start an audio App of some sort, such as Pro Tools, Ableton Live, Sibelius and even humble iTunes!
    I've tried a Digidesign MBox 2 Pro, and an M-Audio FW410, both of which exhibit the same behaviour, and don't cause the same problem when I try it on other Macs (I've tried it on an Intel Mac Mini, a MacBook, and a MacBook Pro so far).
    Things I've tried to fix it:
    1. Unplugging the Mac from the mains power and unplugging the interface from the mains, and all combinations of the two.
    2. Reinstalling Mac OSX (I've tried both 10.4 and 10.5).
    3. Updating drivers.
    I've got AppleCare, and the technicians at my local Apple Store kindly took in the machine and have now replaced the entire Logic Board twice, and still no change in behaviour. I'm now in discussion with Apple Technical support, who take the line that there isn't a problem with the machine, it must be the third party device. I would agree with this of course, except I've tested the devices on other machines, and they work fine, plus the two devices are from two different manufacturers. I do feel a bit like Apple don't know what's wrong and are giving me the easy answer of "it's not our fault".
    One of the technicians did mention the sound was coming from one of the logic chips on the board if that helps anyone!
    Is anyone else experiencing anything like this?

    The speaker volume is stored in the PRAM, so you might try resetting it next time you have the problem:
    Shut down the computer.
    Locate the following keys on the keyboard: Command, Option, P, and R. You will need to hold these keys down simultaneously in step 4.
    Turn on the computer.
    Press and hold the Command-Option-P-R keys. You must press this key combination before the gray screen appears.
    Hold the keys down until the computer restarts and you hear the startup sound for the second time.
    Release the keys.

  • Login Details

    I need to find the IP address who are all connecting to the database thru application or sqlplus

    Niket Kumar wrote:
    col "SID/SERIAL" format a10
    col username format a15
    col osuser format a15
    col program format a40
    select     s.sid || ',' || s.serial# "SID/SERIAL"
    ,     s.username
    ,     s.osuser
    ,     p.spid "OS PID"
    ,     s.program
    from     v$session s
    ,     v$process p
    Where     s.paddr = p.addr
    order      by to_number(p.spid)
    you can find ip information in listener lgs also.your statements is wrong which not giving Ip
    SID/SERIAL USERNAME        OSUSER          OS PID
    PROGRAM
    16,1                       SYSTEM          3760
    ORACLE.EXE (MMNL)
    25,1                       SYSTEM          3920
    ORACLE.EXE (Q001)
    29,69      SPP             Administrator   4484
    JDBC Thin Client
    SID/SERIAL USERNAME        OSUSER          OS PID
    PROGRAM
    32,5       SCDB            Administrator   5792
    JDBC Thin Client
    33,99                      SYSTEM          6080

  • Problem in IDOC segment E1MTXLM

    Hi all,
    Basic type : MATMAS05
    One of the segments is E1MTXLM has the data as below
    "Heater assy., with NTC <(>&<)> protector, 240V, 3000W"
    where as in the MM03 transaction Basic data text is shown as below
    "Heater assy., with NTC & protector, 240V, 3000W"
    I think there is problem while the IDOC is getting created but i have no idea what could be the problem.
    Can any help in this regard.

    Hi Nejuma,
    I don't think there is any problem with cofiguration settings.u r getting the idocs for some vendors .
    if iam not wrong u r giving LS in the tcode(we20).The method which u r using is change pointers.As u r using standard idoc all the settings will be done.
    Only settings u have to do is
    1>generate partner profiles(WE20)
    2>Distribute model view(BD64).
    REGARDS,
    Nagaraj

  • Alert Configuration and Alert inbox showing error

    I have activated all services in SICF which are related to alert configuration and changed the HTTP ABAP port according the note 750287
    com.sap.aii.rwb.server.centralmonitoring.httpport to the HTTP port number mentioned in SMICM -> goto -> services -> HTTP port number.
    This is error i am facing after chaning the port number in Exchange profile and activated and refreshed all cache using
    you can also try to reset just ine case:
    a) the RWB
    http://<J2EE-Host>:<HTTP-Port>/rwb/rtc?op=init
    b) exchange profile
    http://<J2EE-Host>:<J2EE-Port>//rep/support/admin/index.html
    Repository, Directory, Runtime
    (All properties -> Refresh )
    <i>Call of URL http://Hostname:8001/sap/bc/bsp/sap/alertinbox/index.htm terminated due to error in logon data.</i>
    what are the changes expected to do..
    Regards,
    Govada.

    > I have activated all services in SICF which are
    > related to alert configuration and changed the HTTP
    > ABAP port according the note 750287
    This is perfect.
    >
    > com.sap.aii.rwb.server.centralmonitoring.httpport to
    > the HTTP port number mentioned in SMICM -> goto ->
    > services -> HTTP port number.
    This is again correct.
    >
    > This is error i am facing after chaning the port
    > number in Exchange profile and activated and
    > refreshed all cache using
    >
    > you can also try to reset just ine case:
    > a) the RWB
    > http://<J2EE-Host>:<HTTP-Port>/rwb/rtc?op=init
    This is wrong. Try to reset using the J2EE port.
    > b) exchange profile
    > http://<J2EE-Host>:<J2EE-Port>//rep/support/admin/inde
    > x.html
    > Repository, Directory, Runtime
    > (All properties -> Refresh )
    This is correct as well.
    Correct the wrong step, by giving the correct URL and then try again.
    Regards
    Bhavesh

  • Workflow integration with Aperture or iPhoto, and storage/deletion questions.

    I have been using my iPad to download and view photos when I am travelling. I liked the fact that I could delete bad photos or do basic edits like crops and straightens in the "Photos" app and those edits would be saved when I transferred the photos to Aperture. And furthermore, the edits would be shown in Aperture as edits with the ability to revert back to the original or modify those edits later (for example if I wanted to change a crop or fine tune a straighten). This is an example of nearly perfect workflow integration, only problem is that the tools are pretty basic, for example the straighten tool requires an awkward gesture and has no control for fine tuning.
    Now when I bought iPhoto for iOS I figured it would be a more advanced version of that except with more complex editing abilities. However, when I make my edits in iPhoto for iOS, no matter how I import my photos onto my mac there seems to always be two different versions of each photo rather than having both the original and the edit combined like when I edit directly in the "Photos" app. And there's no way to fine tune the edits once imported into iPhoto or Aperture like there is when I edit the photos inside of the Photos app. Is this the correct behavior, and if so, is there anyway to make iPhoto for IOS behave more like the Photos app editing mode in terms of workflow integration.
    Also, I am unsure how the photos are stored in iPhoto for IOS. If I have a bunch of freshly imported photos in my "Photos" app's film roll, and then I edit them all in iPhoto for iOS, I now have two versions of each photo - one in iPhoto and one in the film roll. If I want to delete some photos to save space, can I delete all of the originals in the Film Roll and just keep the edits in iPhoto until I can sync with my Mac, or will that delete it in both places? Manually saving each edit as a new photo in the Film Roll and then deleting the original is tedious. Is the iPhoto app's library only storing the edited versions while the film roll is only storing the originals? Seems kind of like a weird way to handle things, and very unintuititive for those of us used to either iPhoto or the iOS film roll method of editing.
    I'm a fairly advanced user and all of this is pretty confusing to me. It seems like I might just have to ignore iPhoto for iOS and go back to my old method of editing in the Photos app for workflow integration purposes, but I wanted to check to see if I was missing something or doing something wrong first before giving up on iPhoto for iOS.

    Hello Robert. wow, dense prose...
    this wil be more transversal.. hope you'll forgive me.
    iPhoto has several shortcomings that other people might point out. I'll just mention a few.
    when you adjust the image, using the adjustement HUD that floats around just like the one in aperture, you're making destructive pixel changes. True, iP 6 has a way of keeping the original untouched, but the two images will live separate lives (in albums, etc). Furthermore: once you move to the next picture you want to enhance, all the adjustment HUD sliders return to zero. This means that you'll never be able to return to an image and visualize the changes you made to the picture looking at the sliders. You'll have to guess. and restart from scratch.
    About quality: the adjustement sliders in Aperture are waaay more subtle. iPhoto sliders impact the image in a very visible way.... as you "touch" will immprove, you might start to feel that adjusting with iPhoto is a bit gross.
    File renaming: personnal opinion: don't bother. set your camera to increase numbering always... and if possible choose a meaningful prefix (few cameras allow that, the Nikon D200 does). beyond that, I don't have time for this, and don't need it... keywording images is a much more effective way of making them easier to locate. my own view. others will disagree.
    duplicates: lots of people have identified this shortcoming in aperture. considering in version 1.5 they took the time to be able to identify referenced masters in a pretty comprehensive way (using a bunch of data like name+ date/time of capture to reconnect to a lost master), I'd be really surprised if the next major version doesn't fix that.
    Aperture accepts to import/reference your iPhoto folder but I don't think the former will see changes made in the latter..?
    just a few ideas.... HTH
    yours
    maxpol

  • Unknownhostexception while connecting to webservice

    Hi,
    We have an application which connects to a webservice on a different box. If the webservice URL is accessed from the box itself, it works fine. But when we try to hit it from the application, it gives the following error:
    [15-08-2007 03:38:39 AM] DEBUG (CommonAppOperations) CommonAppOperations: validateUser: AppConstants.SECURITY_WS_URL: http://as63alyn:7232/securityWebService/SecurityWebService.jws?WSDL=
    [15-08-2007 03:38:41 AM] DEBUG (CommonAppOperations) CommonAppOperations: validateUser: Exception:
    java.rmi.RemoteException: SOAP Fault:javax.xml.rpc.soap.SOAPFaultException: Failed to send request
    Detail:
    <detail>
    <bea_fault:stacktrace xmlns:bea_fault="http://www.bea.com/servers/wls70/webservice/fault/1.0.0">java.net.UnknownHostException: stg-wlms3.genworth.net: stg-wlms3.genworth.net
         at java.net.InetAddress.getAllByName0(Ljava/lang/String;Z)[Ljava/net/InetAddress;(Unknown Source)
         at java.net.InetAddress.getAllByName0(Ljava/lang/String;)[Ljava/net/InetAddress;(Unknown Source)
         at java.net.InetAddress.getAllByName(Ljava/lang/String;)[Ljava/net/InetAddress;(Unknown Source)
         at weblogic.net.http.HttpClient.openServer(Ljava/lang/String;I)V(HttpClient.java:279)
         at weblogic.net.http.HttpClient.openServer()V(HttpClient.java:355)
    The URL says as63alyn, but the error says unknownhostexception : stg-wlms3.genworth.net
    I checked out and found that it might be a cache forever problem, so disabled the caching forever by changing the java.security file to have the value set to 0 instead of -1 and have the manage servers and the admin server restarted, but still the same problem.
    Can you please suggest why it might be picking up the wrong name and giving me the unknownhostexception.
    Let me know if any more information is required.
    Regards,
    Prashant Kale.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

    I'm sure someone will reply to one of your two OTHER nearly identical threads.

  • How can I get it to accept my serial number?

    I installed the wrong disk yesterday giving my serial number. I uninstalled the wrong disk. Now I am trying to install the correct disk but it is saying my serial number is not a serial number.

    Sounds like Elements. you may wanna (re-)read this stuff:
    Install Premiere Elements, Photoshop Elements
    For everything else some more info would indeed be required.
    Mylenium

  • How do I stop text from resizing to the size of the browser window

    Hello there,
    I am using a DW CS3 template that has a sidebar div and a
    main content div - the text in the main content div keeps resizing
    to the size of the browser window - I don't want the text to resize
    if I make the browser window smaller - I want it to remain the
    same. I am trying to float the text right and input a width but
    this is not working for me. What am I doing wrong?
    HELP!
    Many thanks!

    >>What am I doing wrong?
    Not giving us a link to the uploaded page so we can see the
    page, how it
    behaves and the actual code.
    Until we see that you are unlikely to get a definitive
    answer. The problem
    is unlikely as you state it because text itself is never
    dependant on the
    browser viewport size.
    Walt
    "Fun Leprechaun" <[email protected]> wrote
    in message
    news:g9f7rq$ie4$[email protected]..
    > Hello there,
    >
    > I am using a DW CS3 template that has a sidebar div and
    a main content
    > div -
    > the text in the main content div keeps resizing to the
    size of the browser
    > window - I don't want the text to resize if I make the
    browser window
    > smaller -
    > I want it to remain the same. I am trying to float the
    text right and
    > input a
    > width but this is not working for me. What am I doing
    wrong?
    >
    > HELP!
    >
    > Many thanks!
    >

  • Why doesn't Spotlight actually find stuff

    Unless there is something I am doing wrong, I am giving up on Spotlight. It rarely finds what I am looking for whenever I do a search. I can know the exact name of a document I am searching for, do a search and have it not show up in the search results. Then I spend 10 minutes manually looking for it and when I find it, it has the exact same name I used in the search string. I can try searching on file name mode and contents mode and it rarely finds stuff on my computer with the name or content I am looking for. Why is that?

    Start with http://www.pinkmutant.com/articles/Leopard/leospot.html and my mod to Finder's Find at http://discussions.apple.com/message.jspa?messageID=6725932 for what you can change so you can find stuff excluded by the default structure.

Maybe you are looking for

  • RG1 updation for Reversal of Goods Issue

    Hi, I am a SD person . We recently started RG1 for our client by deleting all the previous data from J_2IRG1BAL table & also mantaining the initial balances for finished goods . When we do a goods reversal for a cancelled sales order ( say movement t

  • Error on hover panel of people search result "We weren't able to find additional information"

    In people search result while hovering over all result item, in the hover panel in the middle I can see a message "We weren't able to find additional information". I saw a msdn post for the same question in this MSDN Link but there it is said that "I

  • Using the toggleOnOff()

    right now my buttons are public and i was woundering how i can make them private and when i make them private i cant use the if else statement. So i need help incorporating the public void toggleOnOff() method to my program so that it works the same

  • Can paging an html dataset be accomplished?

    I have created a standard Master/Detail HTML dataset that is working very nicely. However the client wants to be able to click arrows to advance to the next portfolio item. Here is an example of the page: http://www.studioabsolute.com/dev/websites2.p

  • Can API variables such as RES.PvarTemp1 be set or edit in FDM web tier (ASPX) ?

    I'm working on transferring data via FDM and I want to transfer data by entity. Can I set a global variable or something in session for USS to read. Nathan K