Compare Packages

How can I compare 2 packages to see how they differ? The packages can eiether be in the same schema and database but have different names, or be in different databases. I would like to be able to see the results in line-by-line in the same way as a tool like DiffMerge. The build-in Database Diff Tool can show two objects differ between schemas in different datbases (only) but not how they differe line-by-line.

The easiest way might be to extract the source from both packages using a GUI tool and cut & paste or by querying all_source. Put the source in 2 files and use a diff (file compare) utility to compare the contents. Some GUJI tools (TOAD?) might have built-in utilities to do this

Similar Messages

  • [solved] pacman command to compare package config files

    Hi, Id like to know if there is a pacman command similar to this:
    pacman -Qii | awk '/^MODIFIED/ {print $2}'
    from pacman tips, but where it just checks if the files are not identicle to the default config file of the package?
    From what I can tell, this checks if a file was modified at all (I have copied a config file from a package to a modified package and the file still appears in the output, even though their contents is identicle.
    pacman -Qii | awk '/^MODIFIED/ {print $2}'
    Last edited by jrussell (2013-04-13 17:59:39)

    graysky wrote:
    jrussell wrote:... but where it just checks if the files are not identicle to the default config file of the package?
    Unless I am misunderstanding you, pacman does that by default; when the upgrade is written to disc, the file in question becomes foo.pacnew which you can easily vimdiff or whatever against the original.
    Yes, but I would like to print out a list of config files that are not identical
    I basically want to see a list of all the config files installed that are not identical to thier original config file,
    pacman -Qii | awk '/^MODIFIED/ {print $2}'
    still lists files which are identical because I think it uses modification times or something else

  • Database Diff - Identical package bodies are reported as different

    SQLDeveloper - Version 3.2.10.09
    Package bodies (DDL) on both source and destination database are identical but package body on the source database is marked as "invalid" and package body on destination database is marked as "valid" - then Database Diff reports that package bodies different. (but on panel showing DDL for both compared package bodies there is visible no difference).
    After compiling package body on the source database (no changes in DDL) and when status of that package body changed to "valid" - now Database Diff correctly shows no difference.
    Is that intentional behavior or bug?

    >
    According to the CM team, in the previous (pre-MDAPI) incarnation of CM, status was not compared, and got complaints about that.
    >
    Point taken. Though it seems these days whichever path you take you will get complaints. ;)
    >
    It would be possible to provide the option whether to compare status of objects that have status (PL/SQL objects, triggers, views, indexes) provided MDAPI reports the status, but it's a fairly hefty enhancement.
    >
    I take that to mean that the results do now, and will continue to, take status into account.
    Perhaps my experience is using the functionality differently than what your team is working with.
    I make heavy use of the DBMS_METADATA and DBMS_METADATA_DIFF packages. Much of that functionality operates on CLOBS containing data in either the raw XML or the SXML format.
    So, to me, an XML in a CLOB has no status. So in comparing XML1 in CLOB1 to XML2 in CLOB2 the status that MIGHT have existed on the real object in the real database is irrelevant. I do comparisons between what is in version control and what is from some other source. That other source might have been, or might still be, an object in a database but status is meaningless since DDL in version control has no status. That is why, for my use cases, I wouldn't want to see a comparison fail due to a status issue.
    Oracle® Database PL/SQL Packages and Types Reference
    http://docs.oracle.com/cd/E14072_01/appdev.112/e10577/d_metadiff.htm
    >
    85 DBMS_METADATA_DIFF
    The DBMS_METADATA_DIFF package contains the interfaces for comparing two metadata documents in SXML format. The result of the comparison is an SXML difference document. This document can be converted to other formats using the DBMS_METADATA submit interface and the CONVERT API.
    >
    That is the basis for the comments I was making; that METADATA doesn't necessarily represent an actual object in an actual database.
    Thanks for the links; I will add my vote there.

  • 3.1EA1: Database Diff Package Body

    I've had some problems when comparing package bodies.
    1. Sometimes two or more lines in package bodies are combined into one in the DDL and script tabs of the comparison pane in the difference report.
    2. Sometimes differences in package bodies are missed completely. When this happens, the package body text shown in both sides of the DDL tab of the comparison pane are from the same connection.
    Rodney

    Turns out the consequences of the first problem (merging lines) I mentioned can be severe. The problem occurs when a line ends with a single quotation mark as in the following contrived example.
    CREATE PACKAGE b AS END;
    CREATE PACKAGE BODY b AS
        v       --'
        INTEGER --'
        :=      --'
        1;      --'
    END;
    /The difference process produces the following:
    CREATE OR REPLACE PACKAGE BODY "B" AS
        v       --'    INTEGER --'    :=      --'    1;      --'END;/That ends up in the final script as well which means the script will fail upon execution.
    Rodney

  • Java Comparator - Sorting - using predefined order

    I want to sort the items in my list with a predefined order....Is it possible? I can sort my List using a natural sort as in the below example. But that is not am looking for.....Am looking for sorting my list using an already defined order which i can hold using another list. IS IT POSSIBLE USING Comparator
    package com.nationwide.ag.integration.adapter.party;
    import java.util.*;
    public class TestUsingMe {
    static class AppComparator implements
    Comparator {
    public int compare(Object o1, Object o2) {
    int cc = ((Integer)o1).compareTo(o2);
    return (cc < 0 ? 1 : cc > 0 ? -1 : 0);
    static Comparator appcomparator =
    new AppComparator();
    static void sort(List list1) {
    Collections.sort(list1, appcomparator);
    public static void main(String[] args) {
    List list1 = new ArrayList();
    list1.add(new Integer(90));
    list1.add(new Integer(43));
    list1.add(new Integer(21));
    sort(list1);
    System.out.println(list1);
    Please reply................

    Tried as per your advice, as below. But, it didn't work out. (Hope I have done the changes correctly). Please find the changed code below:
    import java.util.*;
    import com.dto.search.PersonDTO;
    public class TestUsingMe {
    public static void main(String[] args) {
         PersonDTO pDTO0 = new PersonDTO();
         pDTO0.setCifId("Named Non-Owner");
         PersonDTO pDTO1 = new PersonDTO();
         pDTO1.setCifId("Restored");
         PersonDTO pDTO2 = new PersonDTO();
         pDTO2.setCifId("Antique/Classic");
    List list1 = new ArrayList();
    list1.add(pDTO0);
    list1.add(pDTO1);
    list1.add(pDTO2);
    List list2 = new ArrayList();
    list2.add("Private Passenger");
    list2.add("Restored");
    list2.add("Antique/Classic");
    list2.add("Named Non-Owner");
    list2.add("Trailer");
    AppComparator appcomparator = new AppComparator(list2);
    Collections.sort(list1, appcomparator);
    static class AppComparator implements Comparator {
    private List list;
    public AppComparator(List list) {
    this.list = list;
    public int compare(Object o1, Object o2) {
    return list.indexOf("cifId") - list.indexOf("cifId");
    Please respond...................

  • Should I stay or should I go.....................

    .........if I go will there be trouble, if I stay I'll end up paying (nearly) double?
    So, I have BT BB Option 3 and Anytime calls - Been with BT since 1989.
    Due to distance from the exchange and the size of said exchange my BB connection is only @ 4Mb.
    Just payed my quarterly bills (2 accounts - long story) - £155 in total - that is an awful lot for awfully little.
    BT seem to offer comparable packages to new customers - even offering Infinity packages where available for a lot less than I am being charged.
    No attempt to offer me anything to retain my custom.
    BT seem to charge for weekend calls to mobiles - from my latest bill - where The Post Office say these are free.
    Having never switched phone or BB provider, I am unsure what differences to expect.
    For instance, is 1571 BT specific, or is it available to other providers and if not is there an alternative option?
    I assume that I will lose Digital Vault - or can this still be accessed? I can do without this to be honest what with Dropbox and Skydrive and Amazon to name but 3.
    Would I retain access to my BT email account (provided I access it regularly so it doesn't get deemed lapsed) as I have all my email history there - or do I need to set up Outlook and archive it all off?
    Presumably the physical line is the same but what is different for non-BT BB providers - at what point does the connection get routed differently (at the local exchange) and through different servers? I ask this due to the frequency of BB hangups/dropouts and in hope that this may be improved by going elsewhere.
    Presumably, if I leave BT, I then have the option to come back as a new customer and get offered incentives accordingly. Assuming a 12 month minimum contract elsewhere - can I assume that BT will view me as a new customer in 12 months?
    Regards
    Steve O.

    If I were you I'd pay the cancellation fee and get out. BT are never going to improve their customer service, the contempt they have for their customers is palpable.

  • Storing file contents in a Collection

    Hi All,
    Im trying to read a csv file, break the lines by comma, then store them and sort them.
    I have the test code working from: http://java.sun.com/docs/books/tutorial/collections/interfaces/order.html
    I am reading the file, but when I System.out.println() I keep getting the last line of the file only. Why is that?
         try {
              BufferedReader in = new BufferedReader(new FileReader("/Users/custodian/Desktop/list.csv"));
    String line;
    //Start reading the file while
    while ((line = in.readLine()) != null) {
    // System.out.println(line);
    StringTokenizer st = new StringTokenizer(line, ",");
    //Counting tokens while
    while (st.hasMoreTokens()){
         count++;
         //System.out.println(st.nextToken());
         fullname = st.nextToken();
         StringTokenizer wsp = new StringTokenizer(fullname, " ");
         //breaking full name apart while
         while(wsp.hasMoreTokens()){
              fname = wsp.nextToken();
              lname = wsp.nextToken();
         email = st.nextToken();
         phone = st.nextToken();
         streetaddress = st.nextToken();
         city = st.nextToken();
         state = st.nextToken();
         zip = st.nextToken();
         contactArray = new Contact(fname, lname, email, phone, streetaddress, city, state, zip);
         System.out.println(contactArray.toString());
         List <Contact> contacts = Arrays.asList(contactArray);
         Collections.sort(contacts);
         System.out.println(contacts);

    Hi,
    im trying to sort by state then write to another file:
    I keep getting an error on Collections.sort(contacts, new StateComparator());
    Collections.sort(contacts, new StateComparator());
                             try {
                                  BufferedWriter out = new BufferedWriter(new FileWriter("state-sort.csv"));
                                  //PrintWriter p = new PrintWriter(out);
                                  out.write(firstLine + "\n");
                                  Iterator it = contacts.listIterator();
                                  while(it.hasNext()) {
                                  Object o = it.next();     
                                  out.write(o.toString() + "\n");
                                  out.flush();
                                  out.close();
                             }catch(FileNotFoundException ee) {}
                             catch(IOException ioe) {}
    Here is my Comparator
    package mybeans;
    class StateComparator implements Comparable
         String state;
         public String getState() { return state; }
         public int compare(Object obj1, Object obj2)
              if(obj1 == obj2)
                   return 0;
              Contact c1 = (Contact) obj1;
              Contact c2 = (Contact) obj2;
              return c1.getState().compareTo(c2.getState());
         public int compareTo(Object obj)
              Contact c = (Contact) obj;
              return (state).compareTo(c.state + c.state);
    Any help appreciated.

  • Conky - update notifier in python

    Hello there,
    I make update notifier for conky and I hope that it will be useful for someone. Code may be bad, but it works
    Installation:
    1. insert into conky something like this ${texeci 10800 python path/to/python/script}
    2. into cron insert (e.g. /etc/cron.hourly/) shell script
    pacman -Sy
    3. insert somewhere this python script (e.g. /home/user/notify.py)
    #!/usr/bin/env python
    # -*- coding: utf-8 -*-
    # Description: Python script for notifying archlinux updates.
    # Usage: Put shell script with command 'pacman -Sy' into /etc/cron.hourly/
    # Conky: e.g. put in conky '${texeci 1800 python path/to/this/file}'
    # Author: Michal Orlik <[email protected]>, sabooky <[email protected]>
    # SETTINGS - main settings
    # set this to True if you just want one summary line (True/False)
    brief = False
    # number of packages to display (0 = display all)
    num_of_pkgs = 5
    #show only important packages
    onlyImportant = False
    # OPTIONAL SETTINGS
    # PACKAGE RATING - prioritize packages by rating
    # pkgs will be sorted by rating. pkg rating = ratePkg + rateRepo for that pkg
    # pkg (default=0, wildcards accepted)
    ratePkg = {
    'kernel*':10,
    'pacman':9,
    'nvidia*':8,
    # repo (default=0, wildcards accepted)
    rateRepo = {
    'core':5,
    'extra':4,
    'community':3,
    'testing':2,
    'unstable':1,
    # at what point is a pkg considered "important"
    iThresh = 5
    # OUTPUT SETINGS - configure the output format
    # change width of output
    width = 52
    # if you would use horizontal you possibly want to disable 'block'
    horizontally = False
    # separator of horizontal layout
    separator = ' ---'
    # pkg template - this is how individual pkg info is displayed ('' = disabled)
    # valid keywords - %(name)s, %(repo)s, %(size).2f, %(ver)s, %(rate)s
    pkgTemplate = " %(repo)s/%(name)s %(ver)s"
    # important pkg tempalte - same as above but for "important" pkgs
    ipkgTemplate = " *!* %(repo)s/%(name)s %(ver)s"
    # summary template - this is the summary line at the end
    # valid keywords - %(numpkg)d, %(size).2f, %(inumpkg), %(isize).2f, %(pkgstring)s
    summaryTemplate = " %(numpkg)d %(pkgstring)s"
    # important summary template - same as above if "important" pkgs are found
    isummaryTemplate = summaryTemplate + " (%(inumpkg)d important %(isize).2f MB)"
    # pkg right column template - individual pkg right column
    # valid keywords - same as pkgTemplate
    pkgrightcolTemplate = "%(size).2f MB"
    # important pkg right column template - same as above but for important pkgs
    ipkgrightcolTemplate = pkgrightcolTemplate
    # summary right column template - summay line right column
    # valid keywords - same as summaryTemplate
    summaryrightcolTemplate = "%(size).2f MB"
    # important summary right column template - same as above if "important" pkgs are found
    isummaryrightcolTemplate = summaryrightcolTemplate
    # seperator before summary ('' = disabled)
    block = '-' * 12
    # up to date msg
    u2d = ' Your system is up-to-date'
    import subprocess
    import re
    from time import sleep
    from glob import glob
    from fnmatch import fnmatch
    program = []
    pkgs = []
    url = None
    def runpacman():
    """runs pacman returning the popen object"""
    p = subprocess.Popen(['pacman','-Qu'],
    stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
    return p
    def cmpPkgs(x, y):
    """Compares packages for sorting"""
    if x['rate']==y['rate']:
    return cmp(x['size'], y['size'])
    else:
    return x['rate']-y['rate']
    if onlyImportant:
    pkgTemplate, pkgrightcolTemplate = '',''
    p = runpacman()
    #parse pacmans output
    for line in p.stdout:
    if re.match('(Cíle|Pakete|Targets|Se procesará|Cibles|Pacchetti|'
    'Celuje|Pacotes|Цели):', line):
    program = line.split()[1:]
    for line in p.stdout:
    if not line.strip():
    break
    program += line.split()
    for item in program:
    pkg = {}
    desc_path = False
    desc_paths = glob('/var/lib/pacman/sync/*/%s'%item)
    if not desc_path:
    desc_path = desc_paths[0] + '/desc'
    pkg['repo'] = desc_path.split('/')[-3]
    desc = open(desc_path).readlines()
    checkName = 0
    checkSize = 0
    checkVersion = 0
    for index, line in enumerate(desc):
    if line=='%NAME%\n' and checkName == 0:
    pkgName = desc[index+1].strip()
    pkg['name'] = pkgName
    checkName = 1
    if line=='%CSIZE%\n' and checkSize == 0:
    pkgSize = int(desc[index+1].strip())
    pkg['size'] = pkgSize / 1024.0 / 1024
    checkSize = 1
    if line=='%VERSION%\n' and checkVersion == 0:
    pkgVersion = desc[index+1].strip()
    pkg['ver'] = pkgVersion
    checkVersion = 1
    pkgRate = [v for x, v in ratePkg.iteritems()
    if fnmatch(pkg['name'], x)]
    repoRate = [v for x, v in rateRepo.iteritems()
    if fnmatch(pkg['repo'], x)]
    pkg['rate'] = sum(pkgRate + repoRate)
    pkgs.append(pkg)
    # echo list of pkgs
    if pkgs:
    summary = {}
    summary['numpkg'] = len(pkgs)
    summary['size'] = sum([x['size'] for x in pkgs])
    if summary['numpkg'] == 1:
    summary['pkgstring'] = 'package'
    else:
    summary['pkgstring'] = 'packages'
    summary['inumpkg'] = 0
    summary['isize'] = 0
    lines = []
    pkgs.sort(cmpPkgs, reverse=True)
    for pkg in pkgs:
    important = False
    if pkg['rate'] >= iThresh:
    summary['isize'] += pkg['size']
    summary['inumpkg'] += 1
    pkgString = ipkgTemplate % pkg
    sizeValueString = ipkgrightcolTemplate % pkg
    else:
    pkgString = pkgTemplate % pkg
    sizeValueString = pkgrightcolTemplate % pkg
    if len(pkgString)+len(sizeValueString)>width-1:
    pkgString = pkgString[:width-len(sizeValueString)-4]+'...'
    line = pkgString.ljust(width - len(sizeValueString)) + sizeValueString
    if line.strip():
    lines.append(line)
    if not horizontally:
    separator = '\n'
    if not brief:
    if num_of_pkgs:
    print separator.join(lines[:num_of_pkgs])
    else:
    print separator.join(lines)
    if block:
    print block.rjust(width)
    if summary['inumpkg']:
    overallString = isummaryTemplate % summary
    overallMBString = summaryrightcolTemplate % summary
    else:
    overallString = summaryTemplate % summary
    overallMBString = isummaryrightcolTemplate % summary
    summaryline = overallString.ljust(width - len(overallMBString)) \
    + overallMBString
    if summaryline and not horizontally:
    print summaryline
    else:
    print u2d
    4. make python script executable (chmod +x notify.py)
    5. enjoy!
    And there is how it looks:
    If you have some ideas for improving the program, I will be glad to know it
    Is there someone, who knows how to handle with colors in conky with "exec"?
    UPDATED
    - thanks to sabooky for his idea (package info from disk)
    - important package setting and showing with '*!*' prefix
    - number of printed packages
    - summary line
    - horizontal output
    Last edited by Majkhii (2008-06-07 21:55:33)

    Ok, I think the script is working now. Since I used my local copy to fix the script I'll list the changes. These are changes I've made every now and then, I apologize for not posting some of these changes earlier.
    Changes:
    - 'pacman -Sup' changed to 'pacman -Qu'
       - This takes out the need for checking lck files, the whole sleep/try again code is gone now
       - Even when pacman -Sup was runnable as user it created a system wide lock on the pacman db, the change to root is a good thing IMO.
    - changed '/var/lib/pacman/' to '/var/lib/pacman/sync' (also means this will no longer work with the older pacman, will implement backwards compatibility if requested)
    - Added show "onlyImportant" option (Never actually used this, might be buggy)
    - ipkgTemplate no longer dependent on pkgTemplate.
    - packages with equal 'rating' are sorted based on 'size'
    - if package name is wider then width, it is cropped and followed with a '...'
    Customization differences:
    - Width = 52 (instead of 47)
    To do:
    - I'd like to break the script down into functions to make maintainability easier.
    - If anyone has any feature requests post it here or email me.
    EDIT:
    - changed "Targets:" to do a regex search for all the languages.
      - except for hu.po, can't figure out how to extract that, if anyone knows please tell me. I get "Clok:"
    conkypac.py:
    #!/usr/bin/env python
    # -*- coding: utf-8 -*-
    # Description: Python script for notifying archlinux updates.
    # Usage: Put shell script with command 'pacman -Sy' into /etc/cron.hourly/
    # Conky: e.g. put in conky '${texeci 1800 python path/to/this/file}'
    # Author: Michal Orlik <[email protected]>, sabooky <[email protected]>
    # SETTINGS - main settings
    # set this to True if you just want one summary line (True/False)
    brief = False
    # number of packages to display (0 = display all)
    num_of_pkgs = 5
    #show only important packages
    onlyImportant = False
    # OPTIONAL SETTINGS
    # PACKAGE RATING - prioritize packages by rating
    # pkgs will be sorted by rating. pkg rating = ratePkg + rateRepo for that pkg
    # pkg (default=0, wildcards accepted)
    ratePkg = {
    'kernel*':10,
    'pacman':9,
    'nvidia*':8,
    # repo (default=0, wildcards accepted)
    rateRepo = {
    'core':5,
    'extra':4,
    'community':3,
    'testing':2,
    'unstable':1,
    # at what point is a pkg considered "important"
    iThresh = 5
    # OUTPUT SETINGS - configure the output format
    # change width of output
    width = 52
    # pkg template - this is how individual pkg info is displayed ('' = disabled)
    # valid keywords - %(name)s, %(repo)s, %(size).2f, %(ver)s, %(rate)s
    pkgTemplate = " %(repo)s/%(name)s %(ver)s"
    # important pkg tempalte - same as above but for "important" pkgs
    ipkgTemplate = " *!* %(repo)s/%(name)s %(ver)s"
    # summary template - this is the summary line at the end
    # valid keywords - %(numpkg)d, %(size).2f, %(inumpkg), %(isize).2f, %(pkgstring)s
    summaryTemplate = " %(numpkg)d %(pkgstring)s"
    # important summary template - same as above if "important" pkgs are found
    isummaryTemplate = summaryTemplate + " (%(inumpkg)d important %(isize).2f MB)"
    # pkg right column template - individual pkg right column
    # valid keywords - same as pkgTemplate
    pkgrightcolTemplate = "%(size).2f MB"
    # important pkg right column template - same as above but for important pkgs
    ipkgrightcolTemplate = pkgrightcolTemplate
    # summary right column template - summay line right column
    # valid keywords - same as summaryTemplate
    summaryrightcolTemplate = "%(size).2f MB"
    # important summary right column template - same as above if "important" pkgs are found
    isummaryrightcolTemplate = summaryrightcolTemplate
    # seperator before summary ('' = disabled)
    block = '-' * 12
    # up to date msg
    u2d = ' Your system is up-to-date'
    import subprocess
    import re
    from time import sleep
    from glob import glob
    from fnmatch import fnmatch
    program = []
    pkgs = []
    url = None
    def runpacman():
    """runs pacman returning the popen object"""
    p = subprocess.Popen(['pacman','-Qu'],
    stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
    return p
    def cmpPkgs(x, y):
    """Compares packages for sorting"""
    if x['rate']==y['rate']:
    return cmp(x['size'], y['size'])
    else:
    return x['rate']-y['rate']
    if onlyImportant:
    pkgTemplate, pkgrightcolTemplate = '',''
    p = runpacman()
    #parse pacmans output
    for line in p.stdout:
    if re.match('(Cíle|Pakete|Targets|Se procesará|Cibles|Pacchetti|'
    'Celuje|Pacotes|Цели):', line):
    program = line.split()[1:]
    for line in p.stdout:
    if not line.strip():
    break
    program += line.split()
    for item in program:
    pkg = {}
    desc_path = False
    desc_paths = glob('/var/lib/pacman/sync/*/%s'%item)
    if not desc_path:
    desc_path = desc_paths[0] + '/desc'
    pkg['repo'] = desc_path.split('/')[-3]
    desc = open(desc_path).readlines()
    checkName = 0
    checkSize = 0
    checkVersion = 0
    for index, line in enumerate(desc):
    if line=='%NAME%\n' and checkName == 0:
    pkgName = desc[index+1].strip()
    pkg['name'] = pkgName
    checkName = 1
    if line=='%CSIZE%\n' and checkSize == 0:
    pkgSize = int(desc[index+1].strip())
    pkg['size'] = pkgSize / 1024.0 / 1024
    checkSize = 1
    if line=='%VERSION%\n' and checkVersion == 0:
    pkgVersion = desc[index+1].strip()
    pkg['ver'] = pkgVersion
    checkVersion = 1
    pkgRate = [v for x, v in ratePkg.iteritems()
    if fnmatch(pkg['name'], x)]
    repoRate = [v for x, v in rateRepo.iteritems()
    if fnmatch(pkg['repo'], x)]
    pkg['rate'] = sum(pkgRate + repoRate)
    pkgs.append(pkg)
    # echo list of pkgs
    if pkgs:
    summary = {}
    summary['numpkg'] = len(pkgs)
    summary['size'] = sum([x['size'] for x in pkgs])
    if summary['numpkg'] == 1:
    summary['pkgstring'] = 'package'
    else:
    summary['pkgstring'] = 'packages'
    summary['inumpkg'] = 0
    summary['isize'] = 0
    lines = []
    pkgs.sort(cmpPkgs, reverse=True)
    for pkg in pkgs:
    important = False
    if pkg['rate'] >= iThresh:
    summary['isize'] += pkg['size']
    summary['inumpkg'] += 1
    pkgString = ipkgTemplate % pkg
    sizeValueString = ipkgrightcolTemplate % pkg
    else:
    pkgString = pkgTemplate % pkg
    sizeValueString = pkgrightcolTemplate % pkg
    if len(pkgString)+len(sizeValueString)>width-1:
    pkgString = pkgString[:width-len(sizeValueString)-4]+'...'
    line = pkgString.ljust(width - len(sizeValueString)) + sizeValueString
    if line.strip():
    lines.append(line)
    if not brief:
    if num_of_pkgs:
    print '\n'.join(lines[:num_of_pkgs])
    else:
    print '\n'.join(lines)
    if block:
    print block.rjust(width)
    if summary['inumpkg']:
    overallString = isummaryTemplate % summary
    overallMBString = summaryrightcolTemplate % summary
    else:
    overallString = summaryTemplate % summary
    overallMBString = isummaryrightcolTemplate % summary
    summaryline = overallString.ljust(width - len(overallMBString)) \
    + overallMBString
    if summaryline:
    print summaryline
    else:
    print u2d
    Last edited by sabooky (2008-01-16 16:41:25)

  • "Web Premium 5.5" and Upgrading

    Hello,
    I have a pre-upgrade purchase question.
    I currently have Adobe Web Premium 5.5 and am researching what my upgrade price to 6 would be. My suite version only contains Ps, Dw,  Ai, Fw, and Fl. I don't see a comparable package to upgrade to other than "Design AND Web Premium 6," which adds InDesign. That upgrade price is $375.
    Is that correct? My upgrade would provide InDesign as well?
    Thanks!

    Yes, but you might want to consider Creative Cloud as well:
    http://www.adobe.com/products/creativecloud.html
    Bob

  • Thinking of changing to BT

    Hi, we are currently with sky for everything but are looking to change. Looking for any advice that can sway our decision. Something to take into consideration is that we have a 9yr old who watches kids programmes. I have 'chatted' to BT but am confused over the various packages.
    Thanks.

    This link is probably the clearest 
    http://www.productsandservices.bt.com/products/tv/compare-packages
    You can see that with Infinity there are a lot more options and addons available than for those without.
    So yes you can get a Youview package with  that estimated broadband  but you would not get the BT internet channels so it may not be as complete a package as you want for your family.
    That means for example you would not  be able to get the live Kids channels added to your basiic (Essential) package. The Kids on demand content that would be available is a much more limited set of on demand programmes.

  • It seems that the installer on the Mac App Store is still OS X 10.9.3

    I downloaded the full installer app from the Mac App Store today.
    The version written on the Information Column is 10.9.4.
    However, I checked the md5 of the InstallESD.dmg only to find that it is the same as OS X 10.9.3's InstallESD.dmg.
    Hence, it seems that the full installer app on the MAS now is still OS X 10.9.3.
    Is there anyone who encountered the same problem?
    Here is the screenshot of the md5.

    Does the InstallESD.dmg contain everything that gets installed? I thought there were other packages that were external to the installESD?
    Do you need to compare every file?
    FileMerge in the developer tools does this visually.
    Or use find with md5…
    find "/Applications/Install OS X Mavericks.app" -type f -exec md5 {} \;
    # big list of md5's...
    You could just compare packages.
    find "/Applications/Install OS X Mavericks.app" -type f -name *.mpkg -exec md5 {} \;
    I suspect the installer also downloads updates, but it's not clear if this is automated or if it is only done in software update after the install, it seems like the latter.
    Also bear in mind lots of caching goes on with massive distribution systems like the App Store updates, you may want to give it a few hours (or days) to allow caches to be fully renewed, or try another network connection if possible, some ISP's can try to be aggressive about DNS or other caching.

  • Sorting a vector

    hi
    all i am having problem with sorting a vector.I have a vector which contain Objects and each object has string values
    Vector->Objects->String 1 string 2 string 3;
    now i want to sort by string 2 but i also want to sort it by string 3 i means vector should be able to sort by string 2 and second preriority to string 3 and then string1.
    How can i do this i am over loading the comparator class.
    Collection.sort(vector, new vecComparetor());
    public int compare(Object obj1, Object obj2) {
    retrun obj1.compareTo(obj2);
    }

    If I guessed correctly your class is something like the following:
    package mydomain;
    public class MyClass{
         private String str1, str2, str3;
         public MyClass( String str1, String str2, String str3){
              this.str1 = str1;
              this.str2 = str2;
              this.str3 = str3;
         public String getStr1(){ return str1;}
         public String getStr2(){ return str2;}
         public String getStr3(){ return str3;}
         public String toString(){ return "(" + str1 + ", " + str2 + ", " + str3 + ")";}
    }Now, your problem is: Order Vector of MyClass objects by str2, then by str1, then by str3.
    So here it is your Comparator:
    package utils;
    import mydomain.MyClass;
    import java.util.Comparator;
    public class MyComparator implements Comparator{
         public int compare( Object o1, Object o2){
              int i = 0;
              return (i = ((MyClass)o1).getStr2().compareTo( ((MyClass)o2).getStr2())) != 0? i:
                    ((i = ((MyClass)o1).getStr1().compareTo( ((MyClass)o2).getStr1())) != 0? i:
                    ((i = ((MyClass)o1).getStr3().compareTo( ((MyClass)o2).getStr3())) != 0? i: 0));
    }Try it out with this tester (cut and paste these three classes. They compile and run.):
    package utils;
    import mydomain.MyClass;
    import java.util.Vector;
    import java.util.Collections;
    public class MyComparatorTest{
         public static void main( String[] args){
              Vector v = new Vector();
              for( char x = 'a'; x <= 'c'; x++){
                   for( char y = 'a'; y <= 'c'; y++){
                        for( char z = 'a'; z <= 'c'; z++){
                             v.add( new MyClass( new Character( x).toString(), new Character( y).toString(), new Character( z).toString()));
              System.out.println( v);
              Collections.sort( v, new MyComparator());
              System.out.println( v);
    }

  • Paying For 20mb Getting 2mb

     BT sold my son 20mb Unlimited Broadband about Nov 2010, he told me the other week that his BB was very poor as every test he did came back with 2mb d/ld speed. So I tried the BT location site and put in his phone number - and the fastest connection speed there equipment can deliver in his area is 8mb.
     I told him he should call them and get it fixed out as they were charging for a service that BT's equipment could NOT provide. 
     Tonight he called me, he said he was in contact with BT but there line was that it didn't matter that he was only getting 2mb, the £29 odds they were charging was because he was getting Unlimited Download, surely that can't be right.
     The service they sold him and he signed up for was 20mb Unlimited, now while there can be dips in d/ld speed and you can't always get 20mb, but that should not fall below 10mb. The thing is BT's EQUIPMENT CAN NOT EVEN DELIVER 20MB IN HIS AREA!
    The fastest they CAN provide in his area is 8mb, I can see now why his speed is down at 2mb. BT would have to Upgrade there junction boxes to handle/put through 20mb. 
    Surely he has been paying to much and should be due a refund, as BTs equipment can not provide 20mb.
    BT Phone Number Checker ..........
     Your broadband checker results
    Broadband option Estimated connection speed When you can get it Action 
    BT Total Broadband BT Total BroadbandYou can get fast and reliable broadband with speeds of up to 8Mb. 

     Distance from the nearest BT exchange, its in the village where he lives, I would say he's less than half a mile from it. 
     Tried another site and got this ..
    Congratulations, you are in a broadband enabled area.
    Click here to compare packages available to you.
    However, there is another service on your phone line (e.g. ADSL, LLU, DACS, etc) that would prevent you from ordering a new ADSL connection.
    The following services are available in your location:
    BT Wholesale ADSL
    BT Wholesale ADSL Max
    Virgin Media (Cable)
    And from another site what these can provide ..
    BT Wholesale provides wholesale ADSL broadband products to most of the UK’s ISPs. ADSL MAX lines are enhanced versions of the standard IPStream / Datastream ADSL products and use Rate-Adaptive (RA) technology to dynamically find the best ‘stable’ speed for your line. It is capable of offering speeds up to 8Mbps download and 448Kbps (800Kbps business) upload, though most will receive far less.
     I think that says, that BT can not deliver to his home (no matter if the exchange was in his hall cupboard) anything higher than 8mb d/ld speed.

  • My experiences signing up with the Three network (UK)

    I ordered a Three Sim card from Apple on 21st April. It arrived on 5th May and was the wrong one. So I went into the local Three shop and bought one there. I asked when the month would start and was told it would be when I connected. (This was wrong; it began when I registered.) I took the card home, registered online and put the card in my iPad. The iPad recognised the presence of the Sim card, but I had no 3G connection.
    The instructions with the Sim card were minimal and there was no help on Three's website. In the end I phoned up Three's helpline. The documentation with the Sim card says that this helpline costs 5p per minute. In fact, it costs 5p per minute plus VAT. I was almost 15 minutes on hold (at 5p + VAT per minute) before getting a representative, who quickly solved my problem. All I had to do was Reset Network Settings and I was connected.
    I had some complaints about the whole process, mainly about lack of information. For example, my first month began on 5th May, though I only connected on the 6th, but then it restarted on the 10th and I received a bill for £1.24 for the 5 days. it took me some time to work out what this was for. Mostly I put the problems down to lack of thought and care on the part of the company and shrugged my shoulders - Three doesn't have a good reputation for customer care - but the charge for the helpline I really resented. I felt I was being held to ransom.
    I'll stay with Three for now, because the service they offer is a good one. they have the best coverage and the package I bought (1GB per 30 days is £7.50) is the best priced. But as soon as one of the other providers produces a comparable package, I'll move. I don't have warm feelings towards Three.
    Michael

    Ok, then do the same thing as before, EXCEPT do not click accounts, but click preferences under "messages".  Then click accounts and disable the one you don't want.
    Here is what I mean.
       Not sure if this pic shows up.

  • HT4970 It seems that the Calendar app and the Reminders app overlap.

    Why are these 2 apps separate, do they not overlap in function?  If they are separate when do I use one vs. the other?
    Please help me out here.  Are they really separate functions?

    Does the InstallESD.dmg contain everything that gets installed? I thought there were other packages that were external to the installESD?
    Do you need to compare every file?
    FileMerge in the developer tools does this visually.
    Or use find with md5…
    find "/Applications/Install OS X Mavericks.app" -type f -exec md5 {} \;
    # big list of md5's...
    You could just compare packages.
    find "/Applications/Install OS X Mavericks.app" -type f -name *.mpkg -exec md5 {} \;
    I suspect the installer also downloads updates, but it's not clear if this is automated or if it is only done in software update after the install, it seems like the latter.
    Also bear in mind lots of caching goes on with massive distribution systems like the App Store updates, you may want to give it a few hours (or days) to allow caches to be fully renewed, or try another network connection if possible, some ISP's can try to be aggressive about DNS or other caching.

Maybe you are looking for