Still having problem with this sql select... any suggestions!  tx

The following code has a result, I need to modify the select somehow which only gives me the rows which are common between all PLSTS.
Any suggestions?
Thank you
SELECT DISTINCT P.PLST, P.MENU, I.PNL, P.ACCESS
FROM AUTHITEM P, I.MENUITEM
WHERE P.MENU = I.MENU
AND P.PNL = I.PNL
AND P.MENU IN ('MSN, CPP')
AND P.ACESS >= 8
AND EXISTS
(SELECT K.PLST,COUNT (*)
FROM AUTHITEM K, J.MENUITEM
WHERE K.MENU = J.MENU
AND K.PNL = J.PNL
AND P.MENU = K.MENU
AND I.PNL = J.PNL
--AND P.PLST !=K.PLST
--HAVING COUNT(*)   =2
GROUP BY P.PLST, PMENU, I.PNL, P.ACCESS)
This is the result with having count (*) = 2 and plst !=plst comment
PLST MENU PNL ACCESS
C001 MSN LNAME 14
C002 MSN LNAME 14
B008 MSN LNAME 14
B005 MSN FNAME 14
M009 MSN LNAME 14
C001 MSN GNAME 14
C002 MSN GNAME 14
B008 MSN LNAME 14
C001 MSN FNAME 14
C002 MSN FNAME 14
k008 CPP MNAME 14
If I add having count (*) = 2, I do not get any results
I need this result
PLST MENU PNL ACCESS
C001 MSN LNAME 14
C002 MSN LNAME 14
C001 MSN GNAME 14
C002 MSN GNAME 14
C001 MSN FNAME 14
C002 MSN FNAME 14
Thank you

  > I need this result
  > PLST MENU PNL   ACCESS
  > C001 MSN  LNAME 14
  > C002 MSN  LNAME 14
  > C001 MSN  GNAME 14
  > C002 MSN  GNAME 14
  > C001 MSN  FNAME 14
  > C002 MSN  FNAME 14
i think based on your original posting what you need on your groupings are the columns MENU, PNL, ACCESS and exclude PLST.
  SELECT DISTINCT P.PLST, P.MENU, I.PNL, P.ACCESS
    FROM AUTHITEM P, I.MENUITEM
   WHERE P.MENU = I.MENU
     AND P.PNL  = I.PNL
     AND P.MENU IN ('MSN, CPP')
     AND P.ACESS >= 8
     AND EXISTS (SELECT 'x'
                   FROM AUTHITEM K, J.MENUITEM
                  WHERE K.MENU = J.MENU
                    AND K.PNL  = J.PNL
                    AND P.MENU = K.MENU
                    AND I.PNL  = J.PNL
                    AND P.PLST !=K.PLST
                 HAVING COUNT(*) = 2
                 GROUP BY PMENU, I.PNL, P.ACCESS)note: untested

Similar Messages

  • Still having problems with opening iTunes. Any suggestions?

    I have already completely deleted iTunes, Quicktime, Apple update, and all others and tried to reinstall iTunes and Quicktime. I've tried to delete Quicktime and repair through iTunes and still the program won't work. I really need to get to my music in iTunes. Can anyone help?

    I have now resolved finally! - by resettting our Home Router

  • Still having problems with this....

    Hi all,
    Ok I want to make the published .swf file have a transparent background. So I went so the Published settings and in the HTML section I chose Transparent Windowless. But I am still getting a solid color for the background. I did make sure that in the HTML page that there was the right code to make it transparent. Here is a the code;
    <noscript>
        <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" width="550" height="400" id="Untitled-1" align="middle">
        <param name="allowScriptAccess" value="sameDomain" />
        <param name="allowFullScreen" value="false" />
        <param name="movie" value="Untitled-1.swf" /><param name="quality" value="high" /><param name="wmode" value="transparent" /><param name="bgcolor" value="#000000" />    <embed src="Untitled-1.swf" quality="high" wmode="transparent" bgcolor="#000000" width="550" height="400" name="Untitled-1" align="middle" allowScriptAccess="sameDomain" allowFullScreen="false" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
        </object>
    </noscript>
    I also confirmed  that the wmode="transparent as shown above is also in the body code.  What am I doing wrong here?  By the way this is using action script 2 if that makes any differance. Thanks for any help.

    Hey,
    I started looking at the code in the HTML and found that I had to add this code my self:
    <param name="BGCOLOR" value="#831401" />
    <param name="wmode" value="transparent">
    <embed src="viewer.swf" width="534" height="417" quality="high"
    pluginspage="your_url_here..." type="application/x-shockwave-flash" bgcolor="#831401" wmode="transparent"></embed>
    After adding that code it does indeed make a transparent background for the .swf. Would I need to do this any time I want that? Or should Flash do it when it generates the .swf? Thanks so much for the help.

  • Upgraded iTunes last week since then having big problems with runtime library, uninstall iTunes, tried to reinstall still same problem with runtime library. Any suggestion?

    Last week I upgraded iTunes, since then it did not work. Was getting message
    Runtime error program C:\Program files(x86)\iTunes\iTunes.exe
    R6034
    An application has made an attemps to load C runtime library incorrectly. Please contact application's support team for more information.
    Other message i get is window error 1114 - error 7
    \or Service Apple Mobile Device failed to start. Verify that you have sufficient privileges to start system services
    Can anyone help?
    Thanks

    Hi there  - I've spoken with Apple and here is their response (worked for me). You need to uninstall not only iTunes, but also (in this order):
    1) iTunes
    2) Apple Software Update
    3) Apple Mobile Device Support
    4) Bonjour
    5) Apple Application Support
    Then you restart your computer.
    Then you install the latest version of iTunes (which will reinstall all those things you uninstalled).
    Then you restart your computer again.
    Mine is working perfectly again now.
    I hope it works for you,
    Carmen.

  • I am still having problems with my music videos freezing (all purchased from iTunes) since the update.  Have restarted, rebooted etc. and it is worse than before.  Help!  Spent a lot of money on these and they won't play properly.

    I am still having problems with my music videos freezing (all purchased on iTunes) since the update.  The first day of the update, no problems...played 6 hours of music videos and no freezing.  Today...every single video froze!!! So frustrating!  I rebooted, restarted, powered down and no help.   I would appreciate any suggestions.  Thanks.

    I don't know how to do this without using a mouse point.
    This may help, http://www.computerhope.com/issues/ch000542.htm
    As for question #2, you call tell how iTunes is sorting songs by the up or down arrow next to a header name.
    Even the original order that the songs were entered or date added or last played can be sorted.
    Much easier with a mouse or touch pad.

  • I use only two channels, have plenty of memory in my hard disk, and external hard drive, no effects, and still having problems with Garage band. Giving messages as you have too many live channels

    I'm frustrated, I am doing everything you recommend, I use only two channels, have plenty of memory in my hard disk, and external hard drive, no effects, and still having problems with Garage band. Giving messages as you ave too many live channels, the disk is slow prepare...can you help?

    Quote from: Richard on 15-November-07, 20:33:05
    tornado2003,
    What you need to do is boot into Safe Mode. Then delete the VGA Drivers.
    After that boot normally and install the latest nVidia ForceWare Drivers
    Take Care,
    Richard
    i guess you missed that:
    Quote from: tornado2003 on 15-November-07, 17:26:52
    ive tryed booting xp in safe mode but it just freezes after it loads up a couple of needed files .
    ive even formatted my hard drive and tryed installing a fresh xp on it but it just keeps locking up when it gets to the "starting windows setup" .(this is just after it loads all the drivers from the xp cd)

  • Hi all, I'm still having problems with my security questions as they were not the ones I answered. Now I'm confused

    Still having problems with my security questions as they were not the ones I answered and now I'm confused.

    Howdy Paul,
    If you are having an issue with your Apple ID security questions, you can reset them using the steps in this article -
    If you forgot the answers to your Apple ID security questions - Apple Support
    Thanks for using Apple Support Communities.
    Best,
    Brett L 

  • I had already update mi new factory unlocked iPhone 4S to iOS 5.1.1 and I still having problems with "invalid sim". I'm from Argentina and here we don't have official service. PLEASE HELP ME, WHAT CAN I DO??? In Argentina is too expensive an iPhone 4S.

    I had already update mi new factory unlocked iPhone 4S to iOS 5.1.1 and I still having problems with "invalid sim". I'm from Argentina and here we don't have official service. PLEASE HELP ME, WHAT CAN I DO??? In Argentina is too expensive an iPhone 4S. Please I need help to continue believing in Apple. Thanks a lot. If anybody speak spanish better.  

    Was it purchased from an official Apple Store, not a reseller?  Only Apple Stores sell official factory unlocked phones.  The others sell hacked to unlock phones, and the unlocking is unstable.
    Try these steps, as needed:
    1. Reset phone - press both home and on/off buttons for at least 10 seconds until the Apple logo appears.
    2. Settings > General > Reset > Reset Network Settings.
    3. Replace SIM card (and reset network settings again)
    4. Restore Phone in iTunes using a backup
    5. Restore in iTunes as new, without using a backup

  • Still having problems with wireless connections with the new lions os

    is anyone else still having problems with there wireless connections on the new lions os?  What a poor job apple did

    No.

  • Still having ******* problems with downloading apps

    Still having ******* problems with downloading apps

    I know. Alot of people think that 1.1.2 solved it. Looks like it didn't.
    lenn

  • HT4528 my podcast app is shutting down after a few seconds iv tried to reinstall several times but nothing is working even after the podcast update last week im still having no luck getting it working any suggestions?

    my podcast app is shutting down after a few seconds iv tried to reinstall several times but nothing is working even after the podcast update last week im still having no luck getting it working any suggestions?

    if you are subscribed to the Hardwell podcast... quickly open the Podcast app and delete the most recent Hardwell podcast from 3/22.
    for some reason that's causing the crash. i've deleted and it works fine again.

  • Still having problems with images

    I am still having problems putting images into an Oracle 9i database and fetching them back out.
    I think I have finally managed to force a blob image into the database, but can't seem to get it back out into a byte array.
    After many iterations, I have come up with something that might be getting close.
    The code is listed below.
    Everything has been simplified as much as I can.
    The function get_user_picture_func1 returns a single blob for a specified index.
    In this case, I have hardcoded the index = 3 and I think there is an image in the database for that index. (it says there are bytes there anyway).
    The byte array to store the image is defined outside the method fetchImage().
    byte[] imageData;
    When I call fetchImage() I get the following exception:
    Invalid argument(s) in call: getBytes().
    at the line
    imageData = picture.getBytes(zro, k);
    It looks like getBytes has two parameters, Long offset, int length.
    I had diagnostic statements and I confirmed that the statement:
    int k = (int)picture.length(); returned k=4198 (the same size as the image).
    I am at a loss to understand what the exception is trying to tell me.
    I'be been trying to get this to work for a week now and am really getting burned out trying to find anything that works.
    void fetchImage()
    Blob picture;
    String query = "{ ? = call get_user_picture_func1( ? ) }";
    try
    CallableStatement cs = con.prepareCall( query );
    cs.registerOutParameter(1, OracleTypes.BLOB);
    cs.setInt(2,3);
    cs.execute();
    picture = cs.getBlob(1);
    if( picture != null)
    InputStream in = picture.getBinaryStream();
    int k = (int)picture.length();
    imageData = new byte[k];
    long zro = 0;
    imageData = picture.getBytes(zro, k);
    catch( Exception e)
    }

    I have been using my iPad mini with keynote to make slide presentations in  my classes.There has been no problem until I upgraded to Keynote 5.3. Now the refresh rate on the iPad mini is so slow and out of sync with the projected image that I was forced to not use keynote! I have 2 years of work invested that I will have to toss unless this gets fxed. I have not had this problem with this equipment/files before. Only change was upgrade to keynote 5.3. ( Some details: I connect to the projector with a  VGA cable and Apple lightining adaptor to the iPad Mini. All updates current on theiPad Mini.)  Yes I did turn on and off all equipment. And I did check all cable connections. Thanks for any help you may give!

  • I'm still having problems with XUL Runner - please help am getting desperate!

    I recently sought help over a problem I am having with FF. When I try and load it, I get a message telling me that XUL runner 1.9.2.11 is not compatible with 1.9.2.12. The advice I received was to do a clean install. I have done this a number of times - using the Uninstall option in Control Panel as well as running the uninstall utility in the Firefox program folder. Each time I reinstall, and get the same problem. The only difference is that a few days ago I was installing FF 3.6.10, and that gave the error message that XUL runner 1.9.2.11 was not compatible with 1.9.2.10.
    I have FF set as my default browser, so when I click on links in e-mails, etc. I get the same failure to load symptoms. However, I found by chance that FF works OK in conjunction with System Mechanic 10 - a maintenance utility I have on my machine. If I select the on-line help option from that Menu, FF loads and runs OK. I can open new tabs and have no problem loading other pages. However, even with FF open, if I click a link in an e-mail, I get the XUL Runner error message.
    Although not all symptoms are the same, I am also having problems with IE8. When I run the program it loads, shows a 'connecting' message in the tab header, then closes. If I uninstall FF, then System Mechanic selects IE8 as the default browser, and as with FF, loads OK.
    Chrome and Safari both run OK (thankfully). there must be someone out there who knows what this all points to - is that person you?!
    Note: Trouble shooting information retrieved using FF when opened with System Mechanic.

    If you have such problems then you need remove the Firefox program folder before installing a new copy of the full Firefox installer.
    It is important to delete the Firefox program folder to remove all the files and make sure that there are no problems with files that were leftover after uninstalling.

  • Still Having problems with my Iphone 3g ive uninstalled itunes an reinstalled it an still not working

    Hi everyone ive put up a few posts as regards to my iphone, im still currently having problems with windows recognizing it the usb cord an the itunes logo appears on the phone along with the message on my computer USB Device not Recognized, One of the USB Devices attached to this computer has malfunctioned an Windows does not recognize it "Unknown Device Properties comes up an in the genral properties Device Status box says no drivers are currently installed for this device please help

    Put the device in DFU mode (google it) and restore as new.

  • Still having problems with some apps from ovi stor...

    so i am still having trouble installing this app i have pain for the full version after having g the trial i am still getting the finalizing installation cancelling installation problem i have UN-installed all fmobi related files and tried re-installing it but not joy i thought maybe it was a QT file problem but i downloaded another QT dependent app from the store no problem any help would be great thanks 
    N8-00

    join the club im trying to find a way to remove it as mine keeps crashing and freezing the screen i have spoken to apple support and what a waste of time

Maybe you are looking for

  • My bubble sort doesn't work, and does anyone know

    how to count and print the scores of a certain grade.... all the 90's with a's, all the 80's with b's etc.... This is my first java program with two classes. I've been messing with it for about 24hours over the last week. :O. Any suggestions? import

  • ORACLE LOG ERRORS - Bug in oracle??

    Hi, we are using oracle log errors to capture oversized err records for varchar2 type fields. Sql is something like: INSERT INTO abc (col1,col2) VALUES ('asdsass','weqwewqee') LOG ERRORS INTO abc_err('1') REJECT LIMIT UNLIMITED; But, data captured in

  • Populate values selects with select one choice

    How I can to create in Java??

  • Login problem in application in APEX 4.0

    Hi All, Im new to this apex tool...currently i created a DB application with 3 pages....... *) login page *) PAGE 1 *) PAGE 2 Since this application is used by two users... So the PAGE 1 should be accessible to A user....(A should not see PAGE 2) PAG

  • Workflow question - creating artwork for client approval

    I am going to start on a large project with many different pieces of artwork that will need to be approved along the way. As each piece is approved, it will be integrated with other artwork to eventually form the final piece. 1. Just curious what you