How to solve [CASE or DECODE]

Suppoe i ve 2 columns
Col_1 Col_2 both are number
how to write this condtion in query
if
col_1>col_2 then
return coL_1-col_2
else
return
col_2_col1i ve tried decode and case...........but fail to build query.
Waiting for Reply
Regards
Danish Hayder

case is preferable but if you want to learn about decode
SQL> select decode(sign(11-10),-1,'less',0,'=','greater') col1 from dual;
COL1
greaterhttp://www.techonthenet.com/oracle/functions/decode.php

Similar Messages

  • How to use case and decode to extract the data

    Hello PL/SQL Gurus,
    I am using Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production version
    I have a table in following format -
    drop table TT2;
    create table TT2(College, Class,gender,status,fees) as select
    'IITB','MBA','M','P',255600 from dual union all select
    'IITK','MTech','M','P',300000 from dual union all select
    'IITD','MBA','F','P',450000 from dual union all select
    'IITKH','MBA','F','P',350000 from dual union all select
    'IITC','MTech','F','P',420000 from dual union all select
    'IITB','MTech','M','P',185000 from dual union all select
    'IITC','MTech','M','P',235000 from dual union all select
    'IITD','MBA','F','F',175000 from dual union all select
    'IITM','MBA','M','F',257000 from dual union all select     
    'IITKH','MTech','F','P',335000 from dual union all select
    'IITD','MBA','F','P',540335 from dual union all select
    'IITC','MBA','F','F',125089 from dual union all select
    'IITD','MTech','M','P',290756 from dual union all select
    'IITM','MBA','M','P',200000 from dual union all select     
    'IITKH','MBA','F','F',534990 from dual union all select
    'IITD','MBA','F','P',221000 from dual ;some of the extraction conditions are as following -
    CASE CONDITION
    College in 'IITB' and status='P'- 'WestRegion Passed'
    College in 'IITC' and status='P'- 'SouthRegion Passed'
    College in 'IITD' and 'IITK' and status='P' and Gender='F' - 'NothRegion Female Passed'
    College not in 'IITK' and status='F' - 'Ex Kanpur Failed'
    Expected output -
    Region Statnding     Fees
    WestRegion Passed     440460
    SouthRegion Passed     655000
    NothRegion Female Passed     1386335
    Ex Kanpur Failed     1092079SQL Used
    I am using the following query which only make sure of case but this is not how i want the output , if i try to use the case within decode then how to work on this -
    SELECT (CASE WHEN College in ('IITB') and status='P' then sum(fees) else 0 end) WP,
    (case when College in ('IITC') and status='P' then sum(fees) else 0 end) SP,
    (case when College in ('IITD','IITK') and gender='F' and status='P' then sum(fees) else 0 end) NFP,
    (case when College in ('IITK') and status='F' then sum(fees) else 0 end) ExKF
    FROM
    TT2
    GROUP BY College, Class,gender,status

    user555994 wrote:
    Thank you so much jeneesh i am really thankful to you ...vov.
    one more query in case if any of the selection don't have the output data , then values will be displayed like -One way..
    with t as
    --"Add all your descriptions
    (select 'WestRegion Passed' region_standing from dual union all
    select 'SouthRegion Passed' region_standing from dual union all
    select 'NothRegion Female Passed' region_standing from dual union all
    select 'Ex Kanpur Failed' region_standing from dual)
    select region_standing,sum(fees) fees
            from (
            (SELECT CASE WHEN College in ('IITB') and status='P'
                                then 'WestRegion Passed'
                        when College in ('IITC') and status='P'
                                then 'SouthRegion Passed'  
                        when College in ('IITD','IITK') and gender='F' and status='P'
                                then 'NothRegion Female Passed'
                        when College in ('IITK') and status='F'
                                then 'Ex Kanpur Failed'
                        else 'Others' end region_standing,
                        sum(fees) fees
            FROM TT2
            GROUP BY  CASE WHEN College in ('IITB') and status='P'
                                then 'WestRegion Passed'
                        when College in ('IITC') and status='P'
                                then 'SouthRegion Passed'  
                        when College in ('IITD','IITK') and gender='F' and status='P'
                                then 'NothRegion Female Passed'
                        when College in ('IITK') and status='F'
                                then 'Ex Kanpur Failed'
                        else 'Others' end
            union all
            select region_standing,0
            from t
    group by   region_standing;
    REGION_STANDING              FEES
    Others                     2567835
    NothRegion Female Passed   1211335
    WestRegion Passed           440600
    Ex Kanpur Failed                 0
    SouthRegion Passed          655000
    {code}
    Edited by: jeneesh on Nov 5, 2012 5:07 PM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • How to use CASE or DECODE in this?

    Hi , I have a query like this
    AND ...smthng
    AND --smtg
    AND age BETWEEN ....For the last AND clause for age column, I have the values passed from IN param of this SP in form of strings
    '0-30', '31-60', '61-90', and '91+'. The IN param is of course VARCHAR2.
    What I want to do in this AND clause
    e.g. for age range '0-30', the AND clause should be
    AND age BETWEEN ( if this range is '0-30' then ) 0 AND 30 ( if range is '31-60') then BETWEEN 31 AND 60.. and so on...
    However this BETWEEN will work till 61-90 range but for 91+ , there is no upper bound so it should be
    AND age>91
    Now , i am not sure how to achieve this both BETWEEN and '>' clauses in the same AND statement.
    DECODE will not work and am not sure how to use the CASE in this situation as even that can not solve this issue.
    Dont want to make the last AND clause dynamic
    Please suggest me how to do this.
    Thanks,
    Aashish
    Edited by: Aashish S. on Oct 21, 2011 6:01 PM

    A third alternative would be to choose a suitably large value as a high end for the 91+ group and use something like:
    age between to_number(CASE WHEN instr(:param, '+') = 0
                                  THEN substr(:param, 1, instr(:param, '-') -1)
                                  ELSE substr(:param, 1, instr(:param, '+') -1) end) and
                to_number(CASE WHEN instr(:param, '+') = 0
                               THEN substr(:param, instr(:param, '-') +1)
                               ELSE '9999' END)John

  • CASE vs DECODE - CASE with SUM and All in Page Item is non aggregable

    Hi,
    I'm using Discoverer 9.0.4.
    After switching calculations from DECODE to CASE
    I found out that case gives a non aggregable result when using a Page Item and selecting <All>.
    The calculations
    (SUM x) / (SUM y)
    or
    (x SUM) / (y SUM)
    where x and y are variables, work fine with page item <All>.
    But for example:
    CASE WHEN 1=2 THEN 1 ELSE (SUM x) / (SUM y) END
    gives non-aggregable.
    The same code works with DECODE:
    DECODE(1,2,1,(SUM x) / (SUM y))
    and is aggregable.
    Does anyone know a reason or a way to make it work with CASE?
    Thanks,
    Joao Noronha
    P.S.: I wanted <= comparisons and CASE is the best in simplicity,
    but now I know I can do it with DECODE, still looking ok using LEAST instead of ABS of the difference.

    Hi there
    I think therefore you have answered your own question and determined that using CASE in aggregations is not a good idea. I only threw out the two CASE options as ideas not as solutions, just in case (pardon the pun) one of these worked in your situation.
    Your comment I must say that if it worked it would give a wrong result (the sum of the divisions is not the same as the division of the sums) may give the wrong answer in your case but may be correct in others. It just depends how the items in the folder have been set up. I agree though that SUM(x) / SUM(y) will more often than not give the right answer.
    This discussion about DECODE vs CASE has been going on ever since Oracle introduced CASE as a means of placating a younger breed of user who needed an IF..THEN...ELSE construct and could not get their minds around the intricacies of DECODE. The DECODE is a much more reliable function than CASE because it has been around for a long time allowing Oracle plenty of opportunity to iron the bugs out of it. If I get a chance I will always use a DECODE whenever aggregations are required. However, when no aggregations are in use then I'll use CASE, simply because it's easier for users to work with.
    Unfortunately, users need to work with aggregations and so I don't see any alternative to Plus users having to learn DECODE. Whenever I teach Plus I always teach the users both CASE and DECODE but point out that DECODE has fewer issues that CASE. Oh, and talking of issues, try getting the THEN and ELSE components to return a different datatype. CASE has a fit and will not compile.
    Best wishes and glad you got your issue solved - you did right?
    Regards
    Michael

  • TS1702 Does any one know how to solve this iPod touch error: I am tryin to pay for an app but I can because it says that I don't have enough space when I actually have more than enough space to download it so please help me

    Does anyone know how to solve this problem: I a trying to download a paid app but I cannot because the AppStore says that info not have enough space to download it even though I have more than enough space so if any of you know what can solve this problem then please let me know

    The app is compressed and needs swap space to install. As a rule of thumb you need 3 times the listed size of the app available, or in your case 4.6GB. You only have 1.7GB.

  • My external hard drive will no longer connect to my macpro......any ideas on how to solve this problem??

    My external hard drive will no longer connect to my macbook pro via FW800........Any ideas on how to solve this??

    Reset the SMC, see this Apple note: http://support.apple.com/kb/HT3964
    Also reset the PRAM:
    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.
    In most cases, those two actions will fix the port issue. If it's still an issue, you may need to see if the external hard drive can connect to another system, to ensure it's not having problems.

  • Case or decode in select statement for comparison

    Hi,
    How can I do a comparison
    like
    if sal < 50, output 1.1 * comm
    if sal > 50 and < = 100 output 1.2 * comm
    else output comm
    in a single select statement.
    I tried using case and decode but I am not sure how to use it in comparison operations.
    Please help

    use the 'case' construct:
    SELECT
    NORMAL_FIELD
    , (CASE
    WHEN (SAL < 50) THEN 1.1 * COMM          
    WHEN (SAL > 50) AND (SAL <= 100) THEN 1.2 * COMM
    ELSE COMM                    
    END
    ) AS CALCULATED_COMM
    FROM
    TB_xxxx
    WHERE xxxx
    hope this helps

  • How to solve extra commas in CSV files in FCC..!!

    Hi,
    I have the CSV file with comma(,) separator which has around 50 fields. Among them there were some description fields which has comma (ex: karan,kumar) which has to come as a single field and comes as 51 fields instead of 50.
    Due to this, im facing problem at File content conversion and it is failing with error " ERROR converting document line no. 8534 according to structure 'Header':java.lang.Exception: ERROR in configuration / structure 'Header.': More elements in file csv structure than field names specified!
    We have around 10 fields which comes in this way.Any idea how to solve this issue?
    Thanks
    Deepthi.

    Hello Deepthi,
                 The option here is use fieldFixedLengths instead of fieldSeparator. By this way evethough you have more fields in file than given filednames, it will not trigger any error. (But this one will still keep the commas which you might not need in the xml structure, though you can replace these in mapping anyway this is one solution )
    enclosureSign option you can try, but you need do include the delimeter in you file structure, which is again a troublesum.
    eg:- field1, | karan,kumar|,fieldn
    In case you are familier with Adapter Module you can do it  easily, but its a final option as far i am concern.
    Regards,
    Prasanna

  • How to solve the error:  "lightroom could not import this catalog because of an unknown error" when trying to "import from catalog"?

    I have around 400,000 photos of 15 years so given the high number, I organized all my photos into 6 catalogs to avoid potential problems. All the photos and the catalogs are in a 4TB Seagate external hard drive. I use Adobe Lightroom 5 and I use a PC with the latest Windows Office 2013.
    I wanted to have a NEW Catalog of all my rated 1 Star+ photos of all the years in a single Catalog. So I created what I called Star+ Catalog and I was told the best option is to import a Catalog at a time and given that there is no means to filter importing only Stared photos, I would import all the photos and then delete all the UnStared photos. I did that for Catalog Year 2014 but at the end gave me the message: "lightroom could not import this catalog because of an unknown error". It actually had imported around 40k photos from about 50k total. I tried again and again and every time I end up with the same thing. I created another new Catalog and stared from scratch and the same ting happened: the ONLY EXACT 40k or so photos were imported and the rest were not!! When I imported Catalog Year 2013 of around 45k photos, it worked perfectly. But when I imported Catalog Year 2012 of 35k photos, the same thing happened!! 
    Any advice: 1) on how to solve this? and 2) if there is a better and easier way to create this Master Catalog of All Stared Photos of All my Catalogs?

    OK, my starting point is that LR can happily contain 400000+ photos, and it's a mistake to create a 1 star plus catalogue as you suggest. Instead, I'd recommend you create a master catalogue of all your photos, which you can then query however you want - 2 star, or a certain keyword, or with "xyz" in the title etc.
    If you are intent on going that way, you could try a slight change from what you've done so far. Instead of trying to import an entire catalogue and then delete no-star pictures, take the 2014 and 2012 catalogues and select only the 1 star photos. Then do an Export as Catalog for these items, and import the 2014-1star and 2012-1star into your new catalogue. That may get you past the problem images which I suspect are the problem.
    If that doesn't work, or if you follow my initial advice, you're going to need to identify the image where the failure occurs. You may have a corrupt image file, and replacing it from your backup may be sufficient to resolve the problem. Alternatively, it may be a corrupt record in the catalogue, and in this case it may be sufficient to remove the image from the catalogue and import it again. You might try selecting everything in the 2014 catalogue and seeing if you can do an Export as Catalog, creating a clean 2014, and deleting 2014's previews folder might also get rid of a potential problem. Something else is to try the Export as Catalog for images 1-40000, then a second Export as Catalog for images 40002-50k.
    So a few things you'll need to try, rather than a magic bullet, and a recommendation to change the underlying direction.
    John

  • Hi, I loaded an iTunes card and bought an audiobook a few weeks back! I was unable to download it because my wifi was down, my wifi has just been fixed but now my audiobook purchase is not available but the cash has been taken? Any ideas how to solve this

    Hi, I loaded an iTunes card and bought an audiobook a few weeks back! I was unable to download it because my wifi was down, my wifi has just been fixed but now my audiobook purchase is not available but the cash has been taken? Any ideas how to solve this

    When I use find file http://www.macupdate.com/app/mac/30073/find-file (which does tend to find files that "Finder" can't), it's not coming up with any other itunes library files that have been modified in the past week, which I know it would have been - unfortunately, I don't have a very recent backup of the hard drive.  It would be a few months old so it wouldn't have the complete library on it....any ideas?  I'm wondering if restarting the computer might help but have been afraid to do so in case it would make it harder to recover anything...I was looking at this thread https://discussions.apple.com/thread/4211589?start=0&tstart=0 in the hopes that it might have a helpful suggestion but it's definitely a different scenario.

  • I bought CS6 creative suite. As of now i need to work each application in separate separate system. Can any one please help me how to solve this problem.

    I bought CS6 creative suite. As of now i need to work each application in separate separate system. Can any one please help me how to solve this problem.
    I saw the below quote on Adobe forum
    "You may install software on up to two computers. These two computers can be Windows, Mac OS, or one each."
    If i install each application in single single system the system count is more than two. In this case, are we have any license issue? Please advice how the problem will solve?
    If possible please send the advise to my mail id: <Removed by Moderator>
    Thanks
    Uvaraj S

    I already answered that.  If you purchased a Suite then you can only install and activate it on two machines.  Even if you only insdtall one of the applications of that suite, it counts as one activation of the suite.  You cannot take the six or seven different applications that might be in a suite and install and activate them in six or seven different machines... only two machines.
    If your scenario will allow for it, one thing you can do is install the programs on all the different machines and only activate two of the machines at any given time.  If you need to activate a program on a third machine then you need to deactivate on one of the currently activate machines first so that you have an open activation to use again.  I do not remember if there is a limit to the total number of activations you can process for the life of the software.

  • ** File Content Conversion Error in Receiver CC - How to solve this?

    Hi friends,
    My target structure looks like below.
    EmployeeJobDetails                                        --> Message Type
       JobCode                                                      --> Node
            EmployeeNumber            xsd:string
            Domain                           xsd:string
       JobTrack                                                     --> Node
             Department                    xsd: string
             Position                         xsd: string
    I use the FCC parameters in the receiver CC as below:
    Recordset Structure:    JobCode,JobTrack
    JobCode.fieldSeparator = |
    JobCode.endSeparator = 'nl'
    JobTrack.fieldSeparator = |
    JobTrack.endSepartor = 'nl'.
    Because, we want the output like below
    1099|Raja
    Accts|JuniorAccountant
    1100|Ram
    HR|Recruiter
    like this.
    In this scenario Source is XML and target is txt file.
    I am using XSLT Mapping. The FCC works fine, if my source input file contains some records. But, when we send empty source XML file as below
    <?xml version="1.0" encoding="UTF-8"?>
    <EMPLOYEE_DATA/>
    Mapping works fine. Message is processed successfully in SXMB_MONI. The payload in response also comes with Message Type name like below
    <EmployeeJobDetails    namespace >
    </EmployeeJobDetails>
    While convert this, the system throws below error.
    Error Message:
    Message processing failed. Cause: com.sap.aii.af.ra.ms.api.RecoverableException: Exception in XML Parser (format problem?):'java.lang.Exception: Message processing failed in XML parser: 'Conversion configuration error: Unknown structure '' found in document', probably configuration error in file adapter (XML parser error)': java.lang.Exception: Exception in XML Parser (format problem?):'java.lang.Exception: Message processing failed in XML parser: 'Conversion configuration error: Unknown structure '' found in document', probably configuration error in file adapter (XML parser error)'
    Friend, how to convert this when source XML is empty.
    But, if we remove JobTrack node in target strucutre and remove the JobTrack parameters in CC, then if we send the same empty XML file FCC is working  fine and  we  get the target text file 0 KB. (Amazing !!)
    But, in the first case, how to solve the issue?
    Kind Regards,
    Jegathees P.

    Hi friends,
    If we remove JobTrack node in target strucutre and remove the JobTrack parameters in CC, then if we send the <b>same empty XML file</b> FCC is working fine and<b> we get the target text file 0 KB</b>. (Amazing !!)
    But, if we give parameters like JobCode,JobTrack then send pass the same empty file, we face the problem 'File Content Conversion' Error.
    Searching solution for this problem ...

  • Backing up - how to solve after copying whole system - login incorrect

    Hello,
    I have done an script to backup the whole filesystem and restore it. I am making tests before using forever.
    For Windows I use ntfsclone and it works perfect, but for ArchLinux I am doing:
    I use Knoppix cd-live to manage everything. I load the script from /dev/sda4 (data partition in ntfs) and the main commands to backup and restore are:
    Without doing chroot (because it is not possible)
    sudo mount /dev/sda5 /media/sda5 #This is the / of ArchLinux
    sudo rsync -aAXv /media/sda5/* /media/sda4/seccopy/ --exclude={/media/sda5/dev/*,/media/sda5/proc/*,/media/sda5/tmp/*,/media/sda5/run/*,/media/sda5/mnt/*,/media/sda5/media/*,/media/sda5/lost+found,/media/sda5/home/*,/media/sda5/var/lib/pacman/sync/*}
    cd /media/sda4/seccopy/
    sudo tar -zcvf /media/sda4/arch_copy.tar.gz ./*
    To restore:
    sudo mount /dev/sda5 /media/sda5
    sudo rm -r /media/sda5/*
    sudo tar -zxvf /media/sda4/arch_copy.tar.gz -C /media/sda5
    I can check that the files are copied correctly.
    I can do (and really do) the same with the home partition, same process but changing sda5 by sda6, and instead of arch_copy.tar.gz, arch_home_copy.tar.gz
    When I restart to boot in the new copied system... the problem:
    I go to the normal grub option for Arch Linux and I try again to put the password for ussr1, and nothing.
    I type it, enter, wait some seconds and prompt me again.
    I try with the root user, and its password, and the same problem. Not access to the system.
    I try in tty1, and the same problem, it says:
    Login incorrect
    First question: How to solve this situation?
    I think maybe the problem is something about /etc/passwd or /etc/shadow, and also I try to make chroot to see if it works.
    If I try to do chroot from Knoppix to the ArchLinux restored, it is not possible, everything goes ok from this wiki:
    https://wiki.archlinux.org/index.php/Change_Root
    but fails in this:
    Note: If you see the error chroot: cannot run command '/bin/bash': Exec format error, it is likely that the two architectures do not match.
    I don't know what is "architectures". I installed x86_64 in ArchLinux.
    Second question: Is because the Knoppix 7.0.4 (debian based) uses other? Like i686?
    I see in Internet this:
    http://www.cyberciti.biz/tips/recoverin … -file.html
    It is not my problem, but maybe it is a way to know if is correct or not,...-
    mode "recovery", edit, add to linux line after "ro single": init=/bin/bash
    Ctrl+x
    Logged as root automatically:
    Third question: Why is not prompted the password? And illegitimate user can see everything doing this.
    $ mount -rw -o remount /
    $ mount -rw -o remount /home
    mount: /home not mounted or bad option
    In some cases useful info is found in syslog -try
    dmesg | tail or so
    Fourth question: Why i cannot mount the home? It is in the /dev/sda6, but for the / it didn't say anything to me. I cannot see the /home directory.
    $ cat /etc/passwd
    #- Has the root user and the ussr1 user
    $ cat /etc/shadow
    #- Has the root and ussr1 password coded.
    $ passwd
    Enter new UNIX password:
    Retype new UNIX password:
    Fifth question: Why is not prompted for the before password?     (following the steps i can imagine that this doesn't work, so, is not a security problem)
    $ passwd ussr1
    Enter new UNIX password:
    Retype new UNIX password:
    $ sudo reboot:
    sudo: /usr/lib/sudoers.so must be only be writable by owner
    sudo: fatal error, unable to laod plugins
    $ reboot
    Failed to talk to init daemon.
    $ exit
    exit
    [ 377.105707] Kernel panic - not syncing: Attempted to kill init! exitcode=0x00000100
    [ 377.105707]
    Sixth question: Why I cannot exit correctly? It also happen if I use the Arch in Live mode (and try to exit).
    The only way to avoid this problem is unpluging from electrical power (not even with the power button).
    I start the system again, I go to the normal grub option for Arch Linux and I try again to put the password for ussr1, and nothing.
    I type it, enter, wait some seconds and prompt me again.
    The same as first question: How to solve this situation?
    My idea is only use Knoppix live-cd to use as backup/restore system, but if it is not possible, I would like to know how to solve.
    The idea of using rsync instead of dd is because I want to save only the data, and not all the sectors (not enough space in the hard disk).
    I don't mind to have to use arch linux usb installation media as it is "knoppix live-cd", the only thing I would like to use is the same media to do all the operations, because I want to teach normal users how to do it by themselves.

    cfr wrote:What's the exit value when you run passwd? (man passwd will show what the exit values mean.)
    value 0 -> success
    cfr wrote:Have you tried changing the password to something *other* than the existing password?
    tried for example with "something" for both, "root" and "ussr1"
    but if I go to /etc/shadow, I see that the passwords coded for root and ussr1 are not the same, so must be coded with other things too.
    cfr wrote:Have you tried creating a new user and logging in as that user?
    I added another user, for example "try"
    useradd -m -g users -s /bin/bash try
    passwd try & echo "$?"
    .. (something)
    0
    Ok, after just add the user, if I go to /home/ I can see some files created automatically, and if I compare those files with the files that I pasted in my ussr1 account, there are two that are missed:
    .xinitrc
    .xsession
    xinitrc is executed by startx (so, it is because the X11..)
    and..ok, xsession the same (xdm/gdm/kdm). So nothing here.
    I also add "try" to the groups: lp, games, video, audio, optical, storage, scanner   with:
    gpasswd -a try lp
    cfr wrote:Have you run pwck and grpck to check the integrity of the files? (I doubt this is the issue but it seems an easy step to do just on the off chance.)
    Ok, if I do:
    $ pwck; echo "$?"
    0
    $ pwck /etc/passwd; echo "$?"
    0
    $ pwck /etc/shadow; echo "$?"
    invalid password file entry
    delete line 'root:ahskldfhajksdfkahsjkdhf...asdkfhjashdkfjh:15795::::::'?
    invalid password file entry
    delete line 'bin:x:14871::::::'?
    so forth..with: root, bin, daemon, mail, ftp, http, uuidd, dbus and nobody
    user 'ussr1': directory '7' does not exist
    user 'polkitd': directory '7' does not exist
    user 'usbmux': directory '7' does not exist
    user 'mysql': directory '7' does not exist
    invalid password file entry
    delete line 'kdm:!:15793::::::'?
    invalid password file entry
    delete line 'avahi:!:15793::::::'?
    user 'try': directory '7' does not exist
    pwck: no changes
    2
    $grpck /etc/group; echo "$?"
    0
    $grpck /etc/gshadow; echo "$?"
    invalid group file entry
    delete line 'root:::root'?
    invalid group file entry
    delete line 'root:::root'?
    invalid group file entry
    delete line 'root:::root'?
    ...so forth
    with: root, bin, daemon, sys, adm, tty, disk, lp, mem, kmem, wheel, ftp, mail, uucp, log, utmp, locate, rfkill, smmsp, http, games, lock, uuidd, dbus, network, video, audio, optical, floppy, storage, scanner, power, nobody, users, systemd-journal, polkitd, usbmux, mysql, kdm, avahi
    grpck: no changes
    2
    So, cat /etc/gshadow | wc -l    = 40 lines
    And grpck /etc/gshadow | wc -l  = 40 lines
    And the same for /etc/shadow = 16 lines and the pwck were 11 "delete line" and 5 "directory '7' does not exist"
    But as we see, even the try has some error... in this case with directory '7'.
    I don't understand why errors... theoretically they were copied and pasted without modifications
    NOTE** Ok, my fault, I have to execute the command like this: $ pwck -r /etc/passwd /etc/shadow; echo "$?"    and now it answers: 0         So, the integrity of both files are correct! And the same with group and gshadow
    ewaller wrote:
    Inside the chroot, run pacman -Qk | grep -v ", 0 missing"
    And see if there are any packages that should be reinstalled.
    If not, reinstall pam, just for good measure
    With
    $pacman -Qk | grep -v ", 0 missing"
    no results.
    I execute it without doing anything before with pacman, no updating, absolutely nothing.
    pam?
    i search for pam, and i find "pam mount", something like "encrypted home". But Was it activated by default?
    Last edited by Zzipo (2013-03-31 21:57:57)

  • My iPhone is a iPhone 3GS. For some reason, the ringer becomes silent although I have put the ringer on full volume. Would someone kindly teach me how to solve this problem? Many thanks!!

    My iPhone is a iPhone 3GS. For some reason, the ringer becomes silent although I have put the ringer on full volume. Would someone kindly teach me how to solve this problem? Many thanks!!

    Just to make sure... you have the phone in ringer mode right? Sometimes the switch on the side gets bumped (especially if you don't have a case on the iPhone) and goes into silent. If you see a orange line on the switch - it's on silent.
    If the switch is fine (and isn't loose or anything) try restoring the iPhone in iTunes.

  • How to solve problem occur in display

    how i solved this problem in my laptop

    Per,
    maybe this information could be helpful to solve my issue. I used your queries from On queue processing, or the lack thereof. Part #2 :
    select
    count(P.mskey) numEntries,t.taskid,t.taskname,A.Name ActionType,s.name StateName,
    case when js.name = 'Running' then 'Running, processed:'||to_char(NVL(J.CurrentEntry,0)) else js.name end as Jstate
    from
    mxp_provision P
    inner join mxp_Tasks T on T.taskid = P.actionid
    inner join mxp_state S on S.StatID = P.state
    inner join MXP_ActionType A on A.ActType=P.ActionType
    left outer join mc_jobs J on J.JobGuid = T.JobGuid
    left outer join mc_job_state JS on j.State = JS.State
    group by
    t.taskid,T.taskname, A.name, S.name,case when js.name = 'Running' then 'Running, processed:'||to_char(NVL(J.CurrentEntry,0)) else js.name end
    order by
    A.name, S.name
    and got result - I have big Queue for Modify task:
    What I have to do with such Queue? How to reset it?
    Best regards,
    Natalia.

Maybe you are looking for

  • Dynamic mail subject in mail adapter

    Hi. Two different interfaces are using the same mail adapter. Is it possible to change the subject of the email (that gets generated by the receiver mail adapter) depending on whcih interface gets triggered? Thanks. Anuradha.

  • PETTY CASH (CASH JOURNAL) PLANT WISE

    DEAR EXPERT, OUR REQUIREMENT IS TO MAINTAIN CASH JOURNAL PLANT WISE. COMPANY MOVES CASH FROM ONE PLANT TO ANOTHER ON DAILY BASIS. THE PROBLEM IS WHEN I TRIED TO MOVE CASH FROM ONE CASH JOURNAL TO ANOTHER, THE ACCOUNTING DOCUMENT IS GETTING UPDATED BU

  • Error Under "Oracle Learning Management Administrator"- Catalog Administrat

    Hi, Under "Oracle Learning Management Administrator" reponsibility choose Catalog Administration, The following error appears: JSP Error: Request URI:/OA_HTML/OA.jsp Exception: java.lang.IllegalAccessError What's can i do? Thanks nownew

  • Editing incorrect video Podcast Metadata / Tag

    Anyone have a solution for correcting a Podcast's hidden metadata tags so iTunes will properly identify a Podcast instead of filing it as a Movie? Besides Lostify and vID_Infiltr8, which do not have the Podcast stik tag, or at least I couldn't find i

  • Hunger Games iTunes Features Not Working

    I downloaded the Hunger Games movie that comes with the bonus features today. I played the bonus package but for some reason, the features on it will not play. Everything else in it works, but under the category Features, nothing will play. Can anyon