NEED HELP with MSI 6590 KT 400

Hi!
I got a new AMD XP 2600+ FSB 333 and 2 Corsair DDR-Ram 256MB 400 Mhz CL2.
I have the latest bios but can´t use the cpu with FSB 333 and Ram with 400Mhz. I tried only one ram but it worked not either. It shows 333Mhz Ram in both ways.
It works with CPU FSB 266 but I want to have 400Mhz with the correct multiplier and FSB 333.
Thanks for any advice!
Eddie

i've found that my samsung ddr400 doesn't work at ddr400 when i take the fsb past 151.  i just leave it on spd and supposedly it configures it 1:1.  you sometimes get better performance running 1:1 anyway.  
i would just leave the timings on spd and mabye try tweaking them.  ignore what the post says and go for the best bench results.  does your comp boot with the ram?
i wouldn't trade that ram for a 512mb stick.  keep the two and maybe get a nforce2 with dual ddr.  i don't see how 1 stick would get better results than 2 sticks.  just make sure you don't have the sticks using the same memory bus.  ie. put them in slots 1/3 or 2/3.

Similar Messages

  • MOVED: Need help with msi mega 180 + athlon xp-m combo

    This topic has been moved to Overclockers & Modding Corner.
    Need help with msi mega 180 + athlon xp-m combo

    AFAIK, you shouldn't need a pinmod for a Mobile Athlon XP CPU to work in a nforce2 mobo
    did you have any other CPU installed prior to this one? if so, refer here to clear the CMOS: Clear CMOS Guide
    next, refer to your manual, or download from MSI, for location of the FSB jumpers; ensure J8 is shorted across pins 1-2, and J7 is shorted
    finally, enter your BIOS setup menu, and under Advanced Chipset Features, set CPU FSB to 133mhz (or even 166mhz if you have DDR333 memory). the only thing i can't see in the Mega 180 manual is where you set the multiplier...
    which is where the BIOS has limited overclocking features, and you might have a problem here
    i think i'll pass this over to the Overclockers forum, where someone may be able to give a better answer....

  • Really need help with MSI R7970-2PMD3GD5/OC:(

    Greetings to all,
    I really need help with my brand new MSI R7970-2PMD3GD5/OC. I've purchased it two days ago and I didn't really have time to test the card until yesterday. The card is I think way to hot for my "liking". It idles at 56c-60c, at full load in Heaven benchmark 3.0 in 1920x1080, extreme tessellation and 8xAA card reaches 95c-97c. Stock cloacks are 1010Mhz/1375Mhz and stock voltage is 1,174v. Case is being cooled by two Noctua NF-P12 fans. Also I tried lowering the voltage and "underclocking" the card to a standard 925Mhz in small increments, but it doesn't help at all. Each and every time it results in BSOD and dx dll errors and complete system failures. Replacing the card wouldn't be a problem if I lived in a "normal" country that has access to a steady supply. Retailer that sold me a card told me that only 5 cards total have been imported from the launch day and told me that i bought the "last" card in my country. They could order a replacement but it would take them more then a month to do so.:( Ohhh and one more thing I don't overclock, everything in my case is at their default values.
    Recently, I read that "Amd released" a bios update for a standard reference boards that turns them into a "GHZ editions". Also lot of users report a lower voltage requirements and lower temps with that "boost bios". As I understand this card pcb is not Amd's reference board design, I could be wrong it's not that uncommon.. So I didn't want to risk warranty by flashing it to a position 1. Will MSI release the boost bios for this model of card? I am humbly asking MSI staff on how to proceed regarding this problem. I would be immensely grateful for any help you could provide.

    Quote from: Svet on 24-August-12, 18:13:26
    what PC case you use exactly?
    have you tried to open PC case side door and to retest?
    Hi,
    it's open case. If i close it the temps get even worse:(
    They get better for other components, but not for gpu. Two Noctua NF-P12's are cooling the case, first one is positioned above gpu, left side next to cpu. Other is right beneath the gpu, right side of case. Just under the hdd section of the case. I tested each and every component with my backup card nv 8500gt. They function within the specified parameters. I'm getting somewhat worried.
    П.С. Поздрав Свет
    да ли сте ви са наших простора да не куцам на енглеском?

  • Need help with MSI P45 Neo3-FR

    I haven't been here in a long time. My old board (just replacing it) worked perfectly for almost 4 years after I ironed out the kinks (MSI 865p Neo2-FISR) but I finally decided to upgrade my rig, but here comes the headaches...
    I bought the following for my new setup:
    MSI P45 Neo3-FR (came with BIOS 1.3 installed)
    2GB (2x1) Corsair Dominator 6400C4D
    MSI Radeon HD 4850
    Intel Pentium Dual Core E2180 (I want to overclock it hehe)
    Lite-On SATA CD/DVD-RW
    Old Hardware being used:
    Antec TruPower 550W EPS12 (single rail 36amps on +12)
    Cooler Master Centurion (forgot what model) Case
    Logitech USB Keyboard
    Logitech MX518 USB Mouse
    2x120mm fans
    2xMaxtor SATA 80GB HDDs (note: NOT SATA II, and I want to run these in RAID 0 off the ICH10R, this is specifically why I bought this board I was going to go with the P43-Neo3 over this, but the inclusion of RAID sold me on it)
    1xMaxtor SATA 160GB HDD (note: NOT SATA II)
    Aside some trouble I had with the Intel HSF installation was a breeze. Everything is in. I wanted to run everything stock first. Jumped into the BIOS and set the following:
    SATA Controller - RAID
    DRAM Voltage - 2.1v
    Drive Layout:
    SATA1 - 80GB Maxtor
    SATA2- 80GB Maxtor
    SATA7 - Optical Drive
    SATA8 - 160GB Maxtor
    First power on to get into the BIOS was quick. After setting SATA to RAID, POST will hang at Auto-Detecting ACHI Port 1....then find HDD after about 20-30 seconds. And it will repeat itself for Port 2. So its taking me close to a minute (I might be exagerrating but it sure isn't quick and long enough to irritate me having to keep booting) just to POST and even access the BIOS.
    Tried to use my current Windows XP install, got to the Windows XP Splash screen and it rebooted. Tried again, with super long ass POST, again rebooted at the splash screen. Said, fine I'll reinstall XP.
    While browsing here I forgot where I read about the SATA and long posts, so I changed my 2x80GBs to SATA3 and SATA4, it no longer takes a minute to POST, goes quick as normal.
    Set Optical to boot, go into the Windows XP Install screen, F6 for custom drivers, made a RAID disc using three sources (1. RAID drivers from MSI Website, 2. RAID drivers from MSI CD included with Motherboard, 3. RAID Drivers from Intel website) and each time at a certain point I'd get a BSOD.
    Tried again by moving my last HDD/Optical to the ICH10 and disabled the Jmicron. Same, BSOD.
    Switched off RAID in the BIOS and set it to IDE. AGain BSOD at XP Install.
    Started to think it was a Memory issue, ran Memtest both sticks passed.
    One thing I noticed in the BIOS, it has my RAM clocked at 1066. Everything is on auto minus the voltage, but I didn't think it would affect it. So I changed the Ratio from auto to 1:2 (800mhz CPU:800mhz DRAM) but still BSOD everytime I try to install Windows.
    This is getting frustrating. I've run out of ideas. Any help would be greatly appreciated.

    Quote from: BOSSKILLER on 02-August-08, 22:07:06
    Read here how to do it:
    >>> Slipstreaming Windows XP Service Pack 2 and Create Bootable CD<<<
    >>> Slipstreamed Windows XP CD Using SP2<<<
    Other option is borrow such installation disk from friends.
    I moved away from my "friends" and none PC literate, so I'd be better off driving to the store and buying Vista at this point. Haha.
    Okay, going to try this...sounds like that project I started a whiles back but got lazy.
    Thanks guys, I'll report any results.

  • I need help with MSI CR52-A2 52x24x52x CDRW Drive

    Hi,
    I am running Windows XP Home Edition.  My MSI CR52-A2 52x24x52x CDRW Drive will not work.  When I restart my computer the light on it flashes red, green, red, green, red, green, etc...  When XP is running, if I click on the drive under "My Computer" it opens up the drive but no files are found.  If I try to add new hardware, I'm told that the drive is working properly.  When I try to burn a CD with Windows Media Player I'm told no CD Burner is found on my system.  Please help!  Does this have to do with the BIOS?

    Welcome to the forum superaverage.  
    1) Before posting any problems related to your optical drive, please post full system specs AND PSU rails (look at my signature).
    2) Tell us how do you have your drive setup (Master, Slave, in primary channel or secondary channel).
    Edyros!  
    The recommended setup for ANY CD-R/W or DVD-R/W is to set them in the secondary channel as secondary master (assuming that your primary master is your HDD).
    If you're using nero as your burning program, try downloading the latest ASPI drivers for windows XP.
    Try flashing your drive's firmware to support more media and to fix minor bugs.
    ALWAYS use an 80-conductor IDE cable for ANY drive.

  • Need help with msi mega 180 + athlon xp-m combo

    Dear forummembers
    I had a question regarding the athlon xp-m. I installed the cpu in my mobo and it works at a slow speed. 600mhz (multiplier @ 6, fsb 100) So I used a pinmod. Now it runs at 1400mhz (multiplier @ 7x systembus and x14), but I have 2500+ m @ 45 watt or something so it should run at 1862. The problem is my fsb. It runs only at 100. How can I change the FSB? I selected in the bios fsb 133 but it jumps back to 100 all the time. I have the newest bios available, downloaded and installed with liveupdate. is it possible to set  the fsb in the bios, or do I have to change the pinmod again? I know the site for that: pinmod map viewer
    I selected socketview, barton and 7x systembuss + 133mhz and I checked and checked again. I did inserted the pinmodwires like it's shown. I used 5 cutted speaker fiber wires (copper) 
    My current speed is: 14x 100 mhz, but I want 14*133. The multiplier is correct, but the fsb isn't. What is the problem? Does anyone know?
    Here is an example picture, for people, who don't know what a pinmod is:

    AFAIK, you shouldn't need a pinmod for a Mobile Athlon XP CPU to work in a nforce2 mobo
    did you have any other CPU installed prior to this one? if so, refer here to clear the CMOS: Clear CMOS Guide
    next, refer to your manual, or download from MSI, for location of the FSB jumpers; ensure J8 is shorted across pins 1-2, and J7 is shorted
    finally, enter your BIOS setup menu, and under Advanced Chipset Features, set CPU FSB to 133mhz (or even 166mhz if you have DDR333 memory). the only thing i can't see in the Mega 180 manual is where you set the multiplier...
    which is where the BIOS has limited overclocking features, and you might have a problem here
    i think i'll pass this over to the Overclockers forum, where someone may be able to give a better answer....

  • Need help with MSI GeForce 6800. Pc says its an LE...

    Hi all I did a search but couldnt find anything relating to my problem. If I missed it then I apologise in advance.
    I bought an MSI 6800 and installed it but it says that the card installed is a 6800 LE.
    All the packaging and the stickers on the card itself say its a 6800 but the pc says otherwise.
    I installed all the software and searched for updates. I installed new drivers but still it says its an LE.
    How can I find out if I got a duff card or a problem with windows and drivers ??
    Is there a major difference physically on the pcb that I could check out ?
    cheers.
    JunkDuster

    Thank you very much for the pictures.
    I did what you said and guess what, yep, it said 6800 LE.
    I now have the great displeasure of having to pay for postage to return this item and hope that I can get a full refund and go elsewhere.
    That was the first and last time I will use that company again.
    Cheers for your help in stopping me from getting ripped off.
    JunkDuster

  • Need help with MSI GT70 0NC-029NE bluescreen problems

    I've just bought this new MSI computer, and downloaded a few programs like skype, steam, origins etc. When I open all of them at the same time, the bluescreen appears saying; memory management. The computer has 8gb ram, so it shouldnt really be a problem.
    Would really be nice with some help on this as it is quite annoying   

    Quote
    The computer has 8gb ram, so it shouldnt really be a problem.
    The amount of memory is not the problem, but a fault with the memory, or the memory controller (in the CPU) could be the problem.
    Is there a particular program that causes this BSOD?

  • Need help with msi 875p neo

    i just bought one of these and set up my system, but as soon as i flick the power switch on the psu there is a 2 sec delay then it automaticaly boots up without me pushing anything then it just hangs..nothing no boot screen nothing. i check that d brakect thing and it says "Inializing keyboard controller" it stays there and does not change.
    my system spec:
    msi 875P Neo-FIS2R
    intel Pentium 4 3.0GHz 800MHz Fsb
    2 x 256 mb pc-3200 OCZ EL-DDR cas 2 @ DDR400
    thermal take spark 7
    leadtek winfast A280leTD 'Geforce 4 Ti 4200'
    WD raptor 36.7 GB SATA 1
    Xaser III casing
    Thermaltake Purepower 480W
    MS intellieye Explorer
    plz help me i find no reason for it no to work

    Quote
    Originally posted by MaKoMaN
    thaks for all ur help i found the problem one of my memory sticks had a scratch the other one works fine.. but now what do i do with the scratched one?
    did you make the scratch? if not, you got warranty on it that would get you a new one...

  • Need help with MSI K7N2G-ILSR

    This is probably a really easy problem to fix, but my internet time is limited since my old system is in pieces, and I have to do this from work.
    My new MSI K7N2G-ILSR, running with a Barton XP2800 and 2 DIMMs of Geil 512MB DDR PC3200 , doesn't seem to be happy with things. When I tried to turn things on, I got no video output, and there was a regular series of beeps.
    I believed this is just a memory issue, and I intended to look into it when I get home...however, it seems things are a little more complicated than I may have thought.
    After failing to get any results with the pc3200 512 dimms, I switched to my old 2700 256 meg DIMMS, which I knew worked fine. To my surprise, the system then worked...almost. It got to a certain point, and then gave the message "no drive is connected to fastrack", or something to that effect, and then froze.
    The system also worked with combinations of my old 256meg and one of the new 512s, but not with both 512s at once. The 256s, in combination, powered up every time; however, they didn't allow me to install anything. The combination of 2 256s and 1 512 worked most of the time, but would occasionally fail to detect the the RAM - resulting in the same steady beeping as earlier.
    For the sake of curiousity, I removed the IDE cable from the DVD drive. To my surprise, Windows (the drive was not formatted) tried to load...which would not happen when the DVD was connected. I then reconected the DVD, and removed the IDE connection from the hard drive. XP tried to install, and then crashed...in fact, the whole system powered down. And now will not restart again. It's dead, and I can't seem to get a single response from it.
    This made me wonder if the problem lies with my PSU. Does this sound like something which would happen if the PSU was playing up? I have a 450 watt unit, which I thought would be ok. But the only thing I can think is that the PSU doesn't have enough power to deal with the demands of my new system. I imagine the 3200 DIMMs require a lot more power than the 2700, which might explain why the system can't power up using two of them - the PSU can't handle it.
    Any ideas at all? I'm getting more than a little frustrated now. Any advice gratefully received...

    Remove all devices from your setup except the CD-ROM (or DVD device) and the hard drive, and connect each to the end connector on different IDE cable, making sure each device is set to "cable select" (preferred) or "master" (2nd choice). Plug the CD-ROM (or DVD device) into IDE2; Plug the hard drive cable into IDE1. For now, don't plug anything into IDE3.
    Your power supply is probably adequate, but beware. While many PS'es are "high wattage," many don't deliver enough power to the critical 3.3V bus. Check to make sure that your PS is rated for AT LEAST 28 Amps for the 3.3VDC supply. If not, get a new ANTEC TRUE PS that is. Don't skimp on power; it's like you skimping on food, then running a marathon.
    Only install (1) 256MB module in one of the two slots that are together. I recommend the slot closest to the CPU.
    If you are running a video card, remove it and use the IGP for now.
    Now, power up, and when you get the logo screen, go into your BIOS by pressing the delete key. If your screen is blank and just sits there, then power off, unplug the computer, and set the "clear CMOS jumper." Wait 30 seconds, replace jumper, plug in power cord, and restart computer.
    When you get to BIOS, make certain that it sees both drives in the first BIOS screen. Set your time and day (if you like) and then go to the second screen and set your CD-ROM/DVD as the first boot device, set the HD0 as the second (it should already be that way), hit and save and exit, but don't set anything else. Your computer should now boot from the CD-ROM and try to install Windows (I assume XP.) When it asks for you to press F6 to load RAID drivers, don't.
    Choose to format your drive using NTFS, don't choose the quick format.
    Report back!

  • Need help with msi afterburner :)

    Hello i'm tryng to set Framerate monitoring in game in msi afterburner but it says 'tick checkmark to activate the graph and access graph properties i don't know how to do it?
    thx

    i solved problem :P

  • Need help with buying graphics card and ram for MSI 865PE NEO 2-V

    Hi,
    I want to buy 1GB of ram for motherboard MSI 865PE NEO 2-V I need help with finding correct parts.
    I also want to buy 512Mb or 1GB graphics card.
    as i said before i need help with finding correct ones so they match motherboard, I would appreciate if any one would post link to cheap and fitting parts.
    I found graphics card allready, i just need to know if it will fit.
    the card is
    NVIDIA GeForce 7600 GS (512 MB) AGP Graphics Card
    Thanks for help.

    here you can see test reports for your mobo:
    http://www.msi.com/product/mb/865PE-Neo2-V.html#?div=TestReport

  • MOVED: Need help with ATI R9600PRO in MSI KT3 Ultra2

    This topic has been moved to Retired motherboards.
    Need help with ATI R9600PRO  in MSI KT3 Ultra2

    Quote from: chiochio on 21-November-05, 20:20:31
    When I plugged in ATI R9600 Pro, My monitor was blank. PSU? sorry newbie .
    Power Supply details..
    try set AGP Vcore to 1.6

  • Need help with conditional query

    guys this is just an extension of this post that Frank was helping me with. im reposting because my requirements have changes slightly and im having a hell of a time trying to modify the query.
    here is the previous post.
    need help with query that can look data back please help.
    CREATE TABLE "FGL"
        "FGL_GRNT_CODE" VARCHAR2(60),
        "FGL_FUND_CODE" VARCHAR2(60),
        "FGL_ACCT_CODE" VARCHAR2(60),
        "FGL_ORGN_CODE" VARCHAR2(60),
        "FGL_PROG_CODE" VARCHAR2(60),
        "FGL_GRNT_YEAR" VARCHAR2(60),
        "FGL_PERIOD"    VARCHAR2(60),
        "FGL_BUDGET"    VARCHAR2(60)
      )data
    Insert into FGL (FGL_GRNT_CODE,FGL_FUND_CODE,FGL_ACCT_CODE,FGL_ORGN_CODE,FGL_PROG_CODE,FGL_GRNT_YEAR,FGL_PERIOD,FGL_BUDGET) values ('240055','240055','7600','4730','02','11','00','400');
    Insert into FGL (FGL_GRNT_CODE,FGL_FUND_CODE,FGL_ACCT_CODE,FGL_ORGN_CODE,FGL_PROG_CODE,FGL_GRNT_YEAR,FGL_PERIOD,FGL_BUDGET) values ('240055','240055','7240','4730','02','10','1','100');
    Insert into FGL (FGL_GRNT_CODE,FGL_FUND_CODE,FGL_ACCT_CODE,FGL_ORGN_CODE,FGL_PROG_CODE,FGL_GRNT_YEAR,FGL_PERIOD,FGL_BUDGET) values ('240055','240055','7240','4730','02','10','1','0');
    Insert into FGL (FGL_GRNT_CODE,FGL_FUND_CODE,FGL_ACCT_CODE,FGL_ORGN_CODE,FGL_PROG_CODE,FGL_GRNT_YEAR,FGL_PERIOD,FGL_BUDGET) values ('240055','240055','7600','4730','02','11','1','400');
    Insert into FGL (FGL_GRNT_CODE,FGL_FUND_CODE,FGL_ACCT_CODE,FGL_ORGN_CODE,FGL_PROG_CODE,FGL_GRNT_YEAR,FGL_PERIOD,FGL_BUDGET) values ('360055','360055','7200','4730','02','10','1','400');
    Insert into FGL (FGL_GRNT_CODE,FGL_FUND_CODE,FGL_ACCT_CODE,FGL_ORGN_CODE,FGL_PROG_CODE,FGL_GRNT_YEAR,FGL_PERIOD,FGL_BUDGET) values ('360055','360055','7600','4730','02','10','1','400');
    Insert into FGL (FGL_GRNT_CODE,FGL_FUND_CODE,FGL_ACCT_CODE,FGL_ORGN_CODE,FGL_PROG_CODE,FGL_GRNT_YEAR,FGL_PERIOD,FGL_BUDGET) values ('240055','240055','7240','4730','02','10','14','200');
    Insert into FGL (FGL_GRNT_CODE,FGL_FUND_CODE,FGL_ACCT_CODE,FGL_ORGN_CODE,FGL_PROG_CODE,FGL_GRNT_YEAR,FGL_PERIOD,FGL_BUDGET) values ('240055','240055','7600','4730','02','10','14','100');
    Insert into FGL (FGL_GRNT_CODE,FGL_FUND_CODE,FGL_ACCT_CODE,FGL_ORGN_CODE,FGL_PROG_CODE,FGL_GRNT_YEAR,FGL_PERIOD,FGL_BUDGET) values ('240055','240055','7240','4730','02','10','14','200');
    Insert into FGL (FGL_GRNT_CODE,FGL_FUND_CODE,FGL_ACCT_CODE,FGL_ORGN_CODE,FGL_PROG_CODE,FGL_GRNT_YEAR,FGL_PERIOD,FGL_BUDGET) values ('240055','240055','7240','4730','02','10','2','100');
    Insert into FGL (FGL_GRNT_CODE,FGL_FUND_CODE,FGL_ACCT_CODE,FGL_ORGN_CODE,FGL_PROG_CODE,FGL_GRNT_YEAR,FGL_PERIOD,FGL_BUDGET) values ('240055','240055','7240','4730','02','11','2','600');
    I need to find the greatest grant year for the grant by a period parameter.
    once i find the greatest year i need to check the value of period 14 for that grant for the previous year and add it to the budget amount for that grant. however if their is an entry in the greatest year for period 00 then i need to ignore the period 14 of previous year and do this calculation current period +(current period - greatest year 00)
    hope that makes sense so in other words with the new data above. if i was querying period two of grant year 11. i would end up with $800
    because the greatest year is 11 it contains a period 0 with amount of $400 so my total should be
    period 2 amount $ 600
    period 0 amount $ 400 - period 2 amount of $600 = 200
    600+200 = $800
    if i query period 1 of grant 360055 i would just end up with 800 of grnt year 10.
    i have tried to modify that query you supplied to me with no luck. I have tried for several day but im embarrased to say i just can get it to do what im trying to do .
    can you please help me out.
    here is the query supplied by frank kulash who gracefully put this together for me.
    WITH     got_greatest_year     AS
         SELECT     fgl.*     -- or whatever columns are needed
         ,     MAX ( CASE
                     WHEN  fgl_period = :given_period
                     THEN  fgl_grnt_year
                    END
                  ) OVER ()     AS greatest_year
         FROM     fgl
    SELECT     SUM (fgl_budget)     AS total_budget     -- or SELECT *
    FROM     got_greatest_year
    WHERE     (     fgl_grnt_year     = greatest_year
         AND     fgl_period     = :given_period
    OR     (     fgl_grnt_year     = greatest_year - 1
         AND     fgl_period     = 14
    ;Miguel

    Hi, Miguel,
    Are you waying that, when the greatest year that has :given_period also has period='00' (or '0', or whatever you want to use), then you want to double the budget from the given_period (as well as subtract the budget from the '00', and not count the pevious year's '14')? If so, add another condition to the CASE statement which decides what you're SUMming:
    WITH     got_greatest_year     AS
         SELECT       TO_NUMBER (fgl_grnt_year)     AS grnt_year
         ,       fgl_period
         ,       TO_NUMBER (fgl_budget)     AS budget
         ,       MAX ( CASE
                       WHEN  fgl_period = :given_period
                       THEN  TO_NUMBER (fgl_grnt_year)
                      END
                    ) OVER ()     AS greatest_year
         FROM       fgl
    ,     got_cnt_00     AS
         SELECT     grnt_year
         ,     fgl_period
         ,     budget
         ,     greatest_year
         ,     COUNT ( CASE
                       WHEN  grnt_year     = greatest_year
                       AND       fgl_period     = '00'
                       THEN  1
                         END
                    ) OVER ()          AS cnt_00
         FROM    got_greatest_year
    SELECT       SUM ( CASE
                        WHEN  grnt_year     = greatest_year                    -- New
                  AND       fgl_period     = :given_period                    -- New
                  AND       cnt_00     > 0            THEN  budget * 2     -- New
                        WHEN  grnt_year     = greatest_year
                  AND       fgl_period     = :given_period       THEN  budget
                        WHEN  grnt_year     = greatest_year
                  AND       fgl_period     = '00'            THEN -budget
                        WHEN  grnt_year     = greatest_year - 1
                  AND       fgl_period     = '14'     
                  AND       cnt_00     = 0            THEN  budget
                    END
               )          AS total_budget
    FROM       got_cnt_00
    ;You'll notice this is the same as the previous query I posted, except for 3 lines maked "New".

  • Need Help With File Matching Records

    I need help with my file matching program.
    Here is how it suppose to work: FileMatch class should contain methods to read oldmast.txt and trans.txt. When a match occurs (i.e., records with the same account number appear in both the master file and the transaction file), add the dollar amount in the transaction record to the current balance in the master record, and write the "newmast.txt" record. (Assume that purchases are indicated by positive amounts in the transaction file and payments by negative amounts.)
    When there is a master record for a particular account, but no corresponding transaction record, merely write the master record to "newmast.txt". When there is a transaction record, but no corresponding master record, print to a log file the message "Unmatched transaction record for account number ..." (fill in the account number from the transaction record). The log file should be a text file named "log.txt".
    Here is my following program code:
    // Exercise 14.8: CreateTextFile.java
    // creates a text file
    import java.io.FileNotFoundException;
    import java.lang.SecurityException;
    import java.util.Formatter;
    import java.util.FormatterClosedException;
    import java.util.NoSuchElementException;
    import java.util.Scanner;
    import org.egan.AccountRecord;
    import org.egan.TransactionRecord;
    public class CreateTextFile
      private Formatter output1;  // object used to output text to file
      private Formatter output2;  // object used to output text to file
      // enable user to open file
      public void openTransFile()
        try
          output1 = new Formatter("trans.txt");
        catch (SecurityException securityException)
          System.err.println("You do not have write access to this file.");
          System.exit(1);
        } // end catch
        catch (FileNotFoundException filesNotFoundException)
          System.err.println("Error creating file.");
          System.exit(1);
      } // end method openTransFile
      // enable user to open file
      public void openOldMastFile()
        try
          output2 = new Formatter("oldmast.txt");
        catch (SecurityException securityException)
          System.err.println("You do not have write access to this file.");
          System.exit(1);
        } // end catch
        catch (FileNotFoundException filesNotFoundException)
          System.err.println("Error creating file.");
          System.exit(1);
      } // end method openOldMastFile
      // add transaction records to file
      public void addTransactionRecords()
        // object to be written to file
        TransactionRecord record1 = new TransactionRecord();
        Scanner input1 = new Scanner(System.in);
        System.out.printf("%s\n%s\n%s\n%s\n\n",
          "To terminate input, type the end-of-file indicator",   
          "when you are prompted to enter input.",
          "On UNIX/Linux/Mac OS X type <ctrl> d then press Enter",
          "On Windows type <ctrl> z then press Enter");
        System.out.printf("%s\n%s",
           "Enter account number (> 0) and amount.","? ");
        while (input1.hasNext())  // loop until end-of-file indicator
          try // output values to file
            // retrieve data to be output
            record1.setAccount(input1.nextInt());    // read account number
            record1.setAmount(input1.nextDouble());  // read amount
            if (record1.getAccount() > 0)
              // write new record
              output1.format("%d %.2f\n", record1.getAccount(), record1.getAmount());
            } // end if
            else
              System.out.println("Account number must be greater than 0.");
            } // end else
          } // end try
          catch (FormatterClosedException formatterClosedException)
            System.err.println("Error writing to file.");
            return;
          } // end catch
          catch (NoSuchElementException elementException)
            System.err.println("Invalid input. Please try again.");
            input1.nextLine(); // discard input so user can try again
          } // end catch
          System.out.printf("%s %s\n%s", "Enter account number (> 0) ",
            "and amount.","? ");
        } // end while
      } // end method addTransactionRecords
      // add account records to file
      public void addAccountRecords()
        // object to be written to file
        AccountRecord record2 = new AccountRecord();
        Scanner input2 = new Scanner(System.in);
        System.out.printf("%s\n%s\n%s\n%s\n\n",
          "To terminate input, type the end-of-file indicator",   
          "when you are prompted to enter input.",
          "On UNIX/Linux/Mac OS X type <ctrl> d then press Enter",
          "On Windows type <ctrl> z then press Enter");
        System.out.printf("%s\n%s",
           "Enter account number (> 0), first name, last name and balance.","? ");
        while (input2.hasNext())  // loop until end-of-file indicator
          try // output values to file
            // retrieve data to be output
            record2.setAccount(input2.nextInt());    // read account number
            record2.setFirstName(input2.next());      // read first name
            record2.setLastName(input2.next());       // read last name
            record2.setBalance(input2.nextDouble());  // read balance
            if (record2.getAccount() > 0)
              // write new record
              output2.format("%d %s %s %.2f\n", record2.getAccount(), record2.getFirstName(),
                record2.getLastName(), record2.getBalance());
            } // end if
            else
              System.out.println("Account number must be greater than 0.");
            } // end else
          } // end try
          catch (FormatterClosedException formatterClosedException)
            System.err.println("Error writing to file.");
            return;
          } // end catch
          catch (NoSuchElementException elementException)
            System.err.println("Invalid input. Please try again.");
            input2.nextLine(); // discard input so user can try again
          } // end catch
          System.out.printf("%s %s\n%s", "Enter account number (> 0),",
            "first name, last name and balance.","? ");
        } // end while
      } // end method addAccountRecords
      // close file
      public void closeTransFile()
        if (output1 != null)
          output1.close();
      } // end method closeTransFile
      // close file
      public void closeOldMastFile()
        if (output2 != null)
          output2.close();
      } // end method closeOldMastFile
    } // end class CreateTextFile--------------------------------------------------------------------------------------------------
    // Exercise 14.8: CreateTextFileTest.java
    // Testing class CreateTextFile
    public class CreateTextFileTest
       // main method begins program execution
       public static void main( String args[] )
         CreateTextFile application = new CreateTextFile();
         application.openTransFile();
         application.addTransactionRecords();
         application.closeTransFile();
         application.openOldMastFile();
         application.addAccountRecords();
         application.closeOldMastFile();
       } // end main
    } // end class CreateTextFileTest-------------------------------------------------------------------------------------------------
    // Exercise 14.8: TransactionRecord.java
    // A class that represents on record of information
    package org.egan; // packaged for reuse
    public class TransactionRecord
      private int account;
      private double amount;
      // no-argument constructor calls other constructor with default values
      public TransactionRecord()
        this(0,0.0); // call two-argument constructor
      } // end no-argument AccountRecord constructor
      // initialize a record
      public TransactionRecord(int acct, double amt)
        setAccount(acct);
        setAmount(amt);
      } // end two-argument TransactionRecord constructor
      // set account number
      public void setAccount(int acct)
        account = acct;
      } // end method setAccount
      // get account number
      public int getAccount()
        return account;
      } // end method getAccount
      // set amount
      public void setAmount(double amt)
        amount = amt;
      } // end method setAmount
      // get amount
      public double getAmount()
        return amount;
      } // end method getAmount
    } // end class TransactionRecord -------------------------------------------------------------------------------------------------
    // Exercise 14.8: AccountRecord.java
    // A class that represents on record of information
    package org.egan; // packaged for reuse
    import org.egan.TransactionRecord;
    public class AccountRecord
      private int account;
      private String firstName;
      private String lastName;
      private double balance;
      // no-argument constructor calls other constructor with default values
      public AccountRecord()
        this(0,"","",0.0); // call four-argument constructor
      } // end no-argument AccountRecord constructor
      // initialize a record
      public AccountRecord(int acct, String first, String last, double bal)
        setAccount(acct);
        setFirstName(first);
        setLastName(last);
        setBalance(bal);
      } // end four-argument AccountRecord constructor
      // set account number
      public void setAccount(int acct)
        account = acct;
      } // end method setAccount
      // get account number
      public int getAccount()
        return account;
      } // end method getAccount
      // set first name
      public void setFirstName(String first)
        firstName = first;
      } // end method setFirstName
      // get first name
      public String getFirstName()
        return firstName;
      } // end method getFirstName
      // set last name
      public void setLastName(String last)
        lastName = last;
      } // end method setLastName
      // get last name
      public String getLastName()
        return lastName;
      } // end method getLastName
      // set balance
      public void setBalance(double bal)
        balance = bal;
      } // end method setBalance
      // get balance
      public double getBalance()
        return balance;
      } // end method getBalance
      // combine balance and amount
      public void combine(TransactionRecord record)
        balance = (getBalance() + record.getAmount()); 
      } // end method combine
    } // end class AccountRecord -------------------------------------------------------------------------------------------------
    // Exercise 14.8: FileMatch.java
    import java.io.File;
    import java.io.FileNotFoundException;
    import java.lang.IllegalStateException;
    import java.util.NoSuchElementException;
    import java.util.Scanner;
    import java.util.Formatter;
    import java.util.FormatterClosedException;
    import org.egan.AccountRecord;
    import org.egan.TransactionRecord;
    public class FileMatch
      private Scanner inTransaction;
      private Scanner inOldMaster;
      private Formatter outNewMaster;
      private Formatter theLog;
      // enable user to open file
      public void openTransFile()
        try
          inTransaction = new Scanner(new File("trans.txt"));
        } // end try
        catch (FileNotFoundException fileNotFoundException)
          System.err.println("Error opening file.");
          System.exit(1);
        } // end catch
      } // end method openTransFile
      // enable user to open file
      public void openOldMastFile()
        try
          inOldMaster = new Scanner(new File("oldmast.txt"));
        } // end try
        catch (FileNotFoundException fileNotFoundException)
          System.err.println("Error opening file.");
          System.exit(1);
        } // end catch
      } // end method openOldMastFile
      // enable user to open file
      public void openNewMastFile()
        try
          outNewMaster = new Formatter("newmast.txt");
        catch (SecurityException securityException)
          System.err.println("You do not have write access to this file.");
          System.exit(1);
        } // end catch
        catch (FileNotFoundException filesNotFoundException)
          System.err.println("Error creating file.");
          System.exit(1);
      } // end method openNewMastFile
      // enable user to open file
      public void openLogFile()
        try
          theLog = new Formatter("log.txt");
        catch (SecurityException securityException)
          System.err.println("You do not have write access to this file.");
          System.exit(1);
        } // end catch
        catch (FileNotFoundException filesNotFoundException)
          System.err.println("Error creating file.");
          System.exit(1);
      } // end method openLogFile
      // update records
      public void updateRecords()
        TransactionRecord transaction = new TransactionRecord();
        AccountRecord account = new AccountRecord();
        try // read records from file using Scanner object
          System.out.println("Start file matching.");
          while (inTransaction.hasNext() && inOldMaster.hasNext())
            transaction.setAccount(inTransaction.nextInt());     // read account number
            transaction.setAmount(inTransaction.nextDouble());   // read amount
            account.setAccount(inOldMaster.nextInt());     // read account number
            account.setFirstName(inOldMaster.next());      // read first name 
            account.setLastName(inOldMaster.next());       // read last name
            account.setBalance(inOldMaster.nextDouble());  // read balance
            if (transaction.getAccount() == account.getAccount())
              while (inTransaction.hasNext() && transaction.getAccount() == account.getAccount())
                account.combine(transaction);
                outNewMaster.format("%d %s %s %.2f\n",
                account.getAccount(), account.getFirstName(), account.getLastName(),
                account.getBalance());
                transaction.setAccount(inTransaction.nextInt());     // read account number
                transaction.setAmount(inTransaction.nextDouble());   // read amount
            else if (transaction.getAccount() != account.getAccount())
              outNewMaster.format("%d %s %s %.2f\n",
              account.getAccount(), account.getFirstName(), account.getLastName(),
              account.getBalance());         
              theLog.format("%s%d","Unmatched transaction record for account number ",transaction.getAccount());
          } // end while
          System.out.println("Finish file matching.");
        } // end try
        catch (NoSuchElementException elementException)
          System.err.println("File improperly formed.");
          inTransaction.close();
          inOldMaster.close();
          System.exit(1);
        } // end catch
        catch (IllegalStateException stateException)
          System.err.println("Error reading from file.");
          System.exit(1);
        } // end catch   
      } // end method updateRecords
      // close file and terminate application
      public void closeTransFile()
        if (inTransaction != null)
          inTransaction.close();
      } // end method closeTransFile
      // close file and terminate application
      public void closeOldMastFile()
        if (inOldMaster != null)
          inOldMaster.close();
      } // end method closeOldMastFile
      // close file
      public void closeNewMastFile()
        if (outNewMaster != null)
          outNewMaster.close();
      } // end method closeNewMastFile
      // close file
      public void closeLogFile()
        if (theLog != null)
          theLog.close();
      } // end method closeLogFile
    } // end class FileMatch-------------------------------------------------------------------------------------------------
    // Exercise 14.8: FileMatchTest.java
    // Testing class FileMatch
    public class FileMatchTest
       // main method begins program execution
       public static void main( String args[] )
         FileMatch application = new FileMatch();
         application.openTransFile();
         application.openOldMastFile();
         application.openNewMastFile();
         application.openLogFile();
         application.updateRecords();
         application.closeLogFile();
         application.closeNewMastFile();
         application.closeOldMastFile();
         application.closeTransFile();
       } // end main
    } // end class FileMatchTest-------------------------------------------------------------------------------------------------
    Sample data for master file:
    Master file                         
    Account Number            Name                     Balance
    100                            Alan Jones                   348.17
    300                            Mary Smith                    27.19
    500                            Sam Sharp                   0.00
    700                            Suzy Green                   -14.22Sample data for transaction file:
    Transaction file                    Transaction
    Account Number                  Amount
    100                                         27.14
    300                                         62.11
    300                                         83.89
    400                                         100.56
    700                                         80.78
    700                                         1.53
    900                                         82.17  -------------------------------------------------------------------------------------------------
    My FileMatch class program above has bugs in it.
    The correct results for the newmast.txt:
    100  Alan  Jones  375.31
    300  Mary  Smith  173.19
    500  Sam  Sharp  0.00
    700  Suzy Green  68.09The correct results for the log.txt:
    Unmatched transaction record for account number 400Unmatched transaction record for account number 900------------------------------------------------------------------------------------------------
    My results for the newmast.txt:
    100 Alan Jones 375.31
    300 Mary Smith 111.08
    500 Sam Sharp 0.00
    700 Suzy Green -12.69My results for the log.txt
    Unmatched transaction record for account number 700-------------------------------------------------------------------------------------------------
    I am not sure what is wrong with my code above to make my results different from the correct results.
    Much help is appreciated. Please help.

    From the output, it looks like one problem is just formatting -- apparently you're including a newline in log entries and not using tabs for the newmast output file.
    As to why the numbers are off -- just from glancing over it, it appears that the problem is when you add multiple transaction values. Since account.combine() is so simple, I suspect that you're either adding creating transaction objects incorrectly or not creating them when you should be.
    Create test input data that isolates a single case of this (e.g., just the Mary Smith case), and then running your program in a debugger or adding debugging code to the add/combine method, so you can see what's happening in detail.
    Also I'd recommend reconsidering your design. It's a red flag if a class has a name with "Create" in it. Classes represent bundles of independant state and transformations on that state, not things to do.

Maybe you are looking for