Sort by birthday?

I created a smart group which includes all cards with a birthdate field.
I want to print the group showing just the birthdates (I know how to do this).
Anyway I can sort the list by birthdate??? Actually I would like it sorted by month and day.
Thanks,
silvlia
dual 2.5 G5   Mac OS X (10.4.7)  

select pt.phone_no, p.preferred_name_upper, se.grade,
decode(:p_order1,'A',p.preferred_name_upper,'B',p.birth_date,'C',p.birth_date) order1asc,
decode(:p_order1,'A',pt.phone_no,'B',pt.phone_no,'C',pt.phone_no) order2asc
from student_program_class_tracks spct,
persons p,
school_classes sc,
student_enrolments se,
person_telecom pt
where p.person_id = spct.person_id
and p.person_id = pt.person_id
and se.person_id = p.person_id
and se.school_year = sc.school_year
and se.school_code = sc.school_code
and sc.school_code = spct.school_code
and sc.class_code = spct.class_code
and sc.school_year = spct.school_year
and sc.school_code = 'BRE'
and sc.school_year = '20052006'
and se.school_code = 'BRE'
and se.school_year = '20052006'
and se.grade is not null
and se.active_flag = 'x';

Similar Messages

  • Comparable interface selection sort

    Hi,
    I've created a Person Class with a comparable interface. And i've created an ArrayList People with varaibles from the person class in - First_name, Surname, Month(Birthday), Day(Birthday).
    Now i need to use selection sort to sort my arraylist into birthday order. In the Person Class i have a method which gives each person a different number for every possible birthday there is.
    I have created a selction sort but dont know how to call the birthday from my array list and then to sort it.
    This is my code for the selection sort so far:
    import java.util.ArrayList.*;
    public class Main
    public static void selectionSort(Comparable[] people)
    for (int k = people.length-1; k>0; k --)
    Comparable tmp;
    int Large = 0;
    for (int j=1; j<= k; j++)
    if (people[j].compareTo(people[k]) <0)
    Large = j;
    tmp = people[Large];
    people[Large] = people[k];
    people[k] = tmp;
    this method compiles but i need to sort the birthday and dont know how. Also i need to output the whole array in birthday order.
    Any help would be very greatful.
    Thanks
    Dave

    Hi,
    If my understanding is right..
    You are trying to sort with birthday as the primary sort criterria.
    For doing that, you have to write the comparison logic inside the compareTo() method implemented in the Person class (Inherited from Comparable Interface).
    i.e. The compareTo() method should use the the primary_sort_variable(here it is birthday or something derived from it) to return a boolean value for your need.

  • Year view colours

    when in year view is there any way the colours of events match my calenders i.e everything is all yellow can't events corresponce with calender colours
    i.e blue for birthdays red for work green for home

    Ok forgive me. Just sorted the birthday thing. You add birthday field in contacts right. Will keep playing but any help with sync would be great.
    I set my iCloud account up with an existing BT email address and wished I had set up an iCloud address as syncing may work better. How do I set up a new iCloud email and assign it to my apple ID without loosing any apps etc.
    Also will the iCloud email account work on windows and sync contacts and mail with outlook without having to install that awful iTunes thing.
    Please bare in mind my iPhone is a work phone on exchange account and am trying to sync personal Callander items with personal iPad so I can stay organised.

  • Birthday calendar on iCloud sort by last name first name like my contacts

    birthday calendar on iCloud sort by last name first name like my contacts

    Curiously, the most recently inputted entries do sort properly, as do all company entries.
    Does that mean "most recently inputted" AFTER you upgraded to Snow Leopard?
    If that is true, it would mean that something about your existing records before the upgrade, for the records that are people contacts (with first and last names) instead of business contacts, do not agree with Snow Leopard and/or Snow Leopard's version of Address Book.
    This may not be feasible, but if you exported the records with this problems and then imported them, maybe they will be re-inputted so that are properly sorted.
    If you use Time Machine, maybe you can use the +flying through space+ interface to restore one of the records with this problem to see if the restore process makes the record sort properly.

  • How to sort a Vector that stores a particular object type, by an attribute?

    Hi guys,
    i need help on this problem that i'm having. i have a vector that stores a particular object type, and i would like to sort the elements in that vector alphabetically, by comparing the attribute contained in that element. here's the code:
    Class that creates the object
    public class Patient {
    private String patientName, nameOfParent, phoneNumber;
    private GregorianCalendar dateOfBirth;
    private char sex;
    private MedicalHistory medHistory;
    public Patient (String patientName, String nameOfParent, String phoneNumber, GregorianCalendar dateOfBirth, char sex) {
    this.patientName = patientName;
    this.nameOfParent = nameOfParent;
    this.phoneNumber = phoneNumber;
    this.dateOfBirth = dateOfBirth;
    this.sex = sex;
    this.medHistory = new MedicalHistory();
    Class that creates the Vector.
    public class PatientDatabase {
    private Vector <Patient> patientDB = new Vector <Patient> ();
    private DateFunction date = new DateFunction();
    public PatientDatabase () throws IOException{
    String textLine;
    BufferedReader console = new BufferedReader(new FileReader("patient.txt"));
    while ((textLine = console.readLine()) != null) {
    StringTokenizer inReader = new StringTokenizer(textLine,"\t");
    if(inReader.countTokens() != 7)
    throw new IOException("Invalid Input Format");
    else {
    String patientName = inReader.nextToken();
    String nameOfParent = inReader.nextToken();
    String phoneNum = inReader.nextToken();
    int birthYear = Integer.parseInt(inReader.nextToken());
    int birthMonth = Integer.parseInt(inReader.nextToken());
    int birthDay = Integer.parseInt(inReader.nextToken());
    char sex = inReader.nextToken().charAt(0);
    GregorianCalendar dateOfBirth = new GregorianCalendar(birthYear, birthMonth, birthDay);
    Patient newPatient = new Patient(patientName, nameOfParent, phoneNum, dateOfBirth, sex);
    patientDB.addElement(newPatient);
    console.close();
    *note that the constructor actually reads a file and tokenizes each element to an attribute, and each attribute is passed through the constructor of the Patient class to instantiate the object.  it then stores the object into the vector as an element.
    based on this, i would like to sort the vector according to the object's patientName attribute, alphabetically. can anyone out there help me on this?
    i have read most of the threads posted on this forum regarding similar issues, but i don't really understand on how the concept works and how would the Comparable be used to compare the patientName attributes.
    Thanks for your help, guys!

    Are you sure that you will always sort for the patient's name throughout the application? If not, you should consider using Comparators rather than implement Comparable. For the latter, one usually should ensure that the compare() method is consistent with equals(). As for health applications it is likely that there are patients having the same name, reducing compare to the patient's name is hazardous.
    Both, Comparator and Comparable are explained in Sun's Tutorial.

  • How do I get Iphoto to preserve the sort order when I transfer an album?

    Here's my problem. I carefully sorted my album of 230 photos manually. Each photo was then numbered from 1 to 230.   Then I used IPhoto Library Manager to transfer this album someplace else -- to my desktop, to a thumb drive, to Dropbox---   In every case, when I did that, the photos themselves transfered just fine,  but the sort order I had so carefully constructed has fallen apart and cannot by retrieved. Even  when I  close and then reopen an Album I have transferred to my Desktop, it loses its sort order.  This is driving my crazy  because I need to transfer this album so that it preserves the slideshow I have designed for it. A slideshow, of course, demands preserving the order of the slides.
    In short, how can I preserve the sort order of an album when I transfer it out of one library to another?

    If you're transferring to another library, why are you exporting to the Finder (which is what Desktop, thumbdrive and DropBox are). This doesn’t understand manual sorting from iPhoto.
    Here's one (of several) way(s) to do what you want:
    Make an Album of the photos, then drag the pics into your preferred order.
    Then Photos Menu: Batch Change -> Set Title to Text "John's Birthday", for instance, and tick the box to append a number to each Photo. Now your photos are titled 'John's Birthday 001, John's Birthday 002 ... etc'
    Then File -> Export and in the Export dialogue set the Filename to "Use Title"
    Sort on Filename in the FInder and you end up with a folder full of images in the same order as the Album in iPhoto.

  • Reading and Sorting from a CSV file

    I have an assignment to read a shopping list from a CSV file, sort the items and print or write the items to a text file. I have an idea though. I intend to use vectors to collect the items from the CSV file and then sort the list and write to a txt file. Someone tell me whether this is a right approach or suggest simpler approach. thank you.
    Derry

    Sounds reasonable.
    Rather than Vector, though, I'd use ArrayList (a very near replacement for Vector) or possibly LinkedList or even Set or Map. (Vector is a legacy class, kept around for backward compatibility.)
    http://java.sun.com/docs/books/tutorial/collections/
    Make sure each element in the List corresponds to one row in the file. Those elements should be a class you define whose member variables correspond to the columns in the file. (So if the file has Last, First, Bday columns, your class would have lastName, firstName, and birthday fields.)
    Make your class Comparable, or implement a Comparator, to make sorting straightforward.
    http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Comparable.html
    http://java.sun.com/j2se/1.4.2/docs/api/java/util/Comparator.html

  • How to Delete Duplicate Birthdays in iCloud?

    While the birthdays are shown properly on my iPhone, there are duplicate records in iCloud.  I guess this might be due to revisions to the contact information, or synchronization of two (or even more) sets of contact information with iCloud by mistake.  For the latter, I have already removed the duplicate set of contact information from both my iPhone and iCloud.  However, there are still duplicate birthday records in iCloud as shown in the attached picture.  When I attempted to delete the duplicate birthdays, a message saying that this is a read-only information and can't be edited would display.
    I should be grateful for other users' advice on how to resolve the problem.  Advice on how to distinguish which of the duplicate records is associated with the existing contact and hence should be retained, and which is/are associated with old records and can be deleted would also be highly appreciated.  Thank you very much.

    Hey fchengwy,
    Thanks for the question. I understand you are having issues with your Birthday calendar in iCloud, specifically duplicate events. The following article addresses Birthday calendar troubleshooting, and steps to resolve any duplicate entries:
    iCloud: Advanced Calendar and iCal troubleshooting
    http://support.apple.com/kb/TS4337
    To clean up issues related to manually adding birthdays to a calendar in Calendar (or iCal):
    1. If you already have the Birthdays Calendar enabled, deselect it in the Calendars list in Calendar (or iCal).
    2. Search Calendar (or iCal) by entering "birthday" (without the quotes) in the Search dialog in the top-right corner of the Calendar (or iCal) window.
    3. Sort the Search results by title, so they are easier to analyze.
    4. Locate any birthdays that are returned in the Search results that are not contained in a Holidays Calendar (such as John F. Kennedy's Birthday, Lincoln's Birthday, and so on).
    5. For each non-Holidays birthday returned, decide if you want to keep it. If so, open Contacts (or Address Book) and verify that you have a Contact for the individual. Enter the birthday information for that person in Contacts (or Address Book). For more information about updating Contacts (or Address Book) fields, see this article.
    6. After verifying that the birthday is entered in Contacts (or Address Book), remove any birthday events not stored in the Birthdays or Holidays calendars by selecting them and choosing Delete from the Edit menu.
              Note: You can select consecutive items by holding down the Shift key while selecting them. You can select non-consecutive items by holding down the Command key while selecting them.
    After cleaning up any manually added birthdays, you can enable or re-enable the Birthdays Calendar. To enable the Birthdays Calendar for the first time, open Calendar (or iCal) > Preferences and select the checkbox next to Show Birthday's Calendar. If you temporarily hid the Birthdays Calendar as per the instructions above, you can re-enable it by selecting the checkbox for it in the Calendar List.
    Thanks,
    Matt M.

  • Incorrect birthdays in ical and contacts

    I have two birthday fields showing in my contacts, one for the correct day and one for the day before. The incorrect field is the one that shows in my iCal calendar. I can't remember how or when I entered birthdays - it could have been way back when I was using Entourage for contacts. Can anyone help me to delete the incorrect field in my Contact Cards and get the correct field to show in my calendar? (Other than going through each individual contact) I am about to migrate everything over to a new Mac and would like to sort this out before I go ahead. It also shows on my calendar as 'little red gift with name and 9th birthday' Where could the 9th birthday bit have come from?? Many thanks.

    Good question. I've just added birthdays to a number of my contacts specifically to see them in iCal except I'm often not sure of the birth year. If I put in the year 0001 iCal consistently shows the date two days early. What's up with that?

  • How do you sort your Photostream Events in iPhoto?

    I have my photostream photos automatically imported to  iPhoto on my iMac - so I have lots of "events" with names like March 2013 photostream or July 2014 photostream. In each of these events, there are often a whole group of photos that belong together - like a birthday party. There are also some "one off" photos that just one or two shots of something I wanted to photograph (like a couple of pictures of a rainbow, or a picture of a recipe that I like to have on hand so that I can shop for ingredients). I am not sure how these are supposed to be handled. I can leave them all in photostream and add key words to the photos so that I can search for them perhaps (but then I have to manage a lot of key words. I cannot just add a key word "Birthday Party" since I attend many birthday parties. I would have to use a key work like "Bob's 30th birthday party" unless I wasted my search to turn up every picture ever taken at any birthday party!) i can create an event and call it "Bob's 30th birthday party. That seems to work ok - although I'm not sure if I should be doing this. As for the other photos, like the two of the rainbow and the one of the recipe, I don't know what to do with them. I can leave them in photostream with keywords. I can create an entire event called "Recipes" although the range of dates on such a folder might be quite wide since I am always saving recipes, which  means that when my events are sorted by date, my new recipes will appear in an early event along with the very first recipe I ever took a photo of!
    I would love to know how others arrange their events . Do you ever create an event based upon a subject (My Cat Missy) even if the photos span a good deal of time? Or do you leave Missy's photos spread over many events depending upon what date you snapped the photo??? Have you ever completely emptied out a monthly photostream event (for example, let's say all your photostream photos for the month were taken at one wedding, so you moved them all into a single event called "Kate's Wedding."
    See what I mean? Back in the windows days, when admittedly, I took fewer photos, I would create a folder for each big photo taking event (christmas, weddings, birthdays, a lovely walk in the park) and I would create just one folder with the year "Photos from 2008" to put in all the ones and twos photos that don't really belong with anything else. I also had a single folder with pictures of my cats and one that had photos of recipes. I added to these photos anytime I had a picture of my cat or a recipe to upload.
    What does everyone recommend? Sorry for being so long winded. I cannot find any info on "how to sort or manage monthly photostream event photos" so perhaps I am the only one with this issue.

    1. There is no right answer. There is no "should". There is the way that makes sense to you.
    2. You can keyword photos with Birthday party, but also Title them with Bob's 30th, that gives you two ways to search for them
    This might give you some ideas:
    I use Events simply as big buckets of Photos: Spring 08, July - Nov 06 are typical Events in my Library. I use keywords and Smart Albums extensively. I title the pics broadly.
    I keyword on a
    Who
    What
    Where basis (The When is in the photos's Exif metadata). I also rate the pics on a 1 - 5 star basis.
    Using this system I can find pretty much find any pic in my 50k library in a couple of seconds.
    So, for example, I have a batch of pics titled 'Seattle 08' and a  typical keywording might include: John, Anne, Landscape, mountain, trees, snow. With a rating included it's so very easy to find the best pics we took at Mount Rainier.
    File -> New Smart Album
    set it to 'All"
    title contains Seattle
    keyword is mountain
    keyword is snow
    rating is 5 stars
    Or, want a chronological album of John from birth to today?
    New Smart Album
    Keyword is John
    Set the View options to Sort By Date Ascending
    Want only the best pics?
    add Rating is greater than 4 stars
    The best thing about this system is that it's dynamic. If I add 50 more pics of John  to the Library tomorrow, as I keyword and rate them they are added to the Smart Album.
    In the end, organisation is about finding the pics. The point is to make locating that pic or batch of pics findable fast. This system works for me.

  • Birthdays + Outlook + Calendar = Macro Needed!

    Would some wonderful soul out there write a quick little macro to get this job done? Outlook comes with a simple VB macro compiler, so all the macro would have to do would be to sort the calendar by annual events, then edit each of the listed contacts so that their recurrence is changed to Yearly. Thats it. I can do it manually on a keyboard, using the ALT+ commands, so writing a macro should be stupid easy, but its been years since I took a VB class, and forget how to write something as simple as keystrokes and loops properly. Sad, I know, but at least I'm calling for someone more skilled to help out, and giving them the bare bones outline of whats needed!
    I'll post my manual-fix response that I posted on alot of the threads if any of you readers feel up to the challenge, so you can know the keystroke by keystroke sequence (almost).
    (Copied from previous posts)
    Follow these steps:
    1. Go into outlook and open your calendar
    2. Select View -> Arrange By -> Current View -> Annual Events
    NOTE: All of your contacts that have birthday listed SHOULD show up on this page now. No they are not events yet; Yes its dumb that outlook 'knows' they're annual events but doesn't put them on the Calendar; Yes be patient.
    3. With a contact highlighted, hit CTRL+A, which is the command to select all the items that populate that list. Alternatively, you could hit HOME then SHIFT + END to select the entire list as well. Whatever.
    4. Right click any one of the contacts that are all highlighted, and select "Open Items"
    NOTE: Outlook will warn you that opening alot of items may take a long time and doesn't recommend it. I opened 280 contacts almost instantly, no lock up or slowing, on a craptop, so don't fret and just agree to it.
    5. With all those windows open (stop crying, I know its alot), get your fingers ready. No we're not going to have to click around everywhere and take a million years. Just some fast finger work is all.
    6. Push ALT + U, ALT + Y, ENTER, ALT + S
    NOTE: What you're doing here is manually selecting the recurrence button, then selecting yearly for the recurrence, then closing that window, then saving and closing that contact. You can click all that with your mouse, but getting into a rhythm on your keyboard makes it so you don't have to look at the screen and can go as fast as you can type perfectly.
    7. Once you get the rotation down, it will start to be like this, ALTS,+U,Y, ENTER, ALTS,+U,Y, ENTER, etc etc etc.

    To be honest, this is such a minor thing to do that solves a pretty common problem, that I think IT WOULD BE GREAT if someone on the Apple support team whipped this up real fast. Yes, I know there are multiple versions of Outlook, and not all problems are exactly the same, but this would be so fast to write, why not?

  • Hierarchical Query Sort help needed in 9i (9.2.0.6)

    Hello all, hope you guys are far away from IKE (it hit us pretty bad last weekend), anyway come to point
    My requirement is data sorted by name is such a way after parent show its childs (if exists) i.e first sort parents and then by childs within parants
    I am expecting this
    1     BBQU-1
    2     BBQU-1 Sub event 1
    3     BBQU-1 Sub event 2
    10     BBQU-1 Sub event 3
    6     BBQU-1 Birthday
    5     BBQU-1 Advance
    7     BBQU-2
    4     BBQU-2 Sub event
    from
    1     BBQU-1     
    5     BBQU-1 Advance     
    2     BBQU-1 Sub event 1     1
    3     BBQU-1 Sub event 2     1
    10     BBQU-1 Sub event 3     1
    6     BBQU-1 Birthday     
    7     BBQU-2     
    4     BBQU-2 Sub event     7
    Here is the script for table and data.
    create table no_more_ike (event_id number, event_name varchar2(30), subevent_id number);
    insert into no_more_ike values (1, 'BBQU-1', null);
    insert into no_more_ike values (5, 'BBQU-1 Advance', null);
    insert into no_more_ike values (2, 'BBQU-1 Sub event 1', 1);
    insert into no_more_ike values (3, 'BBQU-1 Sub event 2', 1);
    insert into no_more_ike values (10, 'BBQU-1 Sub event 3', 1);
    insert into no_more_ike values (6, 'BBQU-1 Birthday', null);
    insert into no_more_ike values (7, 'BBQU-2', null);
    insert into no_more_ike values (4, 'BBQU-2 Sub event', 7);
    commit;
    Thanks a lot

    Is this OK?
    select
       event_id,
       event_name,
       subevent_id
    from no_more_ike
    start with SUBEVENT_ID is null
    connect by prior EVENT_ID = SUBEVENT_ID
    order by decode(subevent_id, null, event_id, subevent_id) asc;

  • My apple ID was hacked.  Trying to reset password but the email never reached my account.  Trying to answer security questions, the birthday was changed.  I am really miserable.  Can anyone shed some light, please?

    My gmail email is my apple ID.  I found I lost access of gmail last night and I reset the password before bed.  But this morning the password was changed again.  My ipad also requested a password that didn't match to the one I used.  I have reset my gmail once more.  In addition, I added 2-step verification.  But I have not received any new mail up to now.  I tried to reset my apple ID.  When I selected sending an email for resetting, the mail was sent but never reached my mailbox;  When I selected answering security questions: the birthday was wrong.  It's been changed.  I am SO SO UPSET.  Can any genius take pity on me and show me some guidance, please?

    You should get Apple involved in sorting this out. Start at this site:
    https://getsupport.apple.com/Issues.action
    Your Apple ID can be handled through iTunes.

  • Sorting albums in photo

    I do not see the option of sorting albums by date in the new photo

    I do not see the option of sorting albums by date in the new photo
    There isn't such an option. You can sort the albums manually or by title.  As a workaround, make the date a part of the name of the album, for example "2015-04-Birthday album".

  • Sort images in slideshow

    I spent the weekend scanning about 120 photos to make a DVD to run during my wife's 50th birthday part, naming them all by year and number within the year so they would be nicely sorted for the slideshow. Much to my disgust when I dragged them into the slideshow window, they did not appear sorted by name. Does anybody know of a way to easily perform such a basic task apparently unthought of by the program's developers? I was using iDVD 4, though I have 5 a work and it seems to have the same limitation.

    I have only used the slide show feature of iDVD a few times and also noticed the rather random way that iDVD chooses to display a set of photos when dragged into a slide show. I have not figured out a way or heard of a way to reorder them in a specific sequence. If you want more control you might consider building your slide show in iMovie instead and sending to iDVD as a movie. Although the iDVD slide show builder is a very quick and easy way to do slide shows, but apparently has its draw backs.
    Patrick

Maybe you are looking for

  • MacBook Pro suddenly running slow - need it fixed by tonight

    I've had my Pro for over a year now, and usually don't have any problems. However, about a week ago it started running slowly out of nowhere - I can't run one simple task without the colour wheel appearing for several minutes before the command final

  • Multilevel Categorization in the normal Appointment View

    Dear experts, We're using CRM 7.0 SP3. We're well aware that Multilevel Categorization as per Standard is supported in IC Webclient in Interaction Record View and not in the normal Appointment View (i.e. UI Component BT126H_CALL). However we want to

  • How to compile DNG SDK with GCC?

    I tried to compile DNG SDK with GCC, but I got stuck to the following error message: ... dng_flags.h:33:28: error: RawEnvironment.h: No such file or directory ... In other words, it seems that file 'RawEnvironment.h' is missing. I cannot find this fi

  • Variable selection screen- text in ascending order

    Hi All, Is there a way to display the medium/long text description in ascending order in selection screen?  rather than displaying the key in ascending order.  is it possible? thanks

  • No rounding decimals

    Hi, i am using currency(ZCURR) field. which is upto 2 decimals. after calculation in currency(ZCURR) field data is comming wotih rounding. also i tried with PACKED decimals upto 2 still it rounding off as i wnat actual value upto 2 decimals Ex: ZCURR