List Sorting By LIFO

All installation and configuration problems and questions

Moderators: gerski, enjay, williamconley, Op3r, Staydog, gardo, mflorell, MJCoate, mcargile, Kumba, Michael_N

List Sorting By LIFO

Postby ajax1515 » Thu Dec 10, 2015 12:31 pm

As the subject states, I'd like to be able to sort a list by timestamp of when the leads were actually added to the list. Regardless of Dial Count, Last Call Time, etc. I want the lead most recently added to the list to be the first one called.
ViciBox v.7.0.2-160325
VICIDIAL-VERSION: 2.12-550a BUILD: 160414-1013
Asterisk 11.22.0-vici
1 Database Server
MariaDB 10.1.6
2 Web Servers
Multiple Dial Servers
ajax1515
 
Posts: 70
Joined: Wed Sep 23, 2015 11:23 am

Re: List Sorting By LIFO

Postby mflorell » Thu Dec 10, 2015 12:52 pm

That's just using the Campaign Lead Order of DOWN. Because the leads are added with an auto-incrementing lead_id, the leads loaded first will have lower lead_ids.
mflorell
Site Admin
 
Posts: 18387
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Re: List Sorting By LIFO

Postby ajax1515 » Fri Dec 11, 2015 3:48 pm

I'm having trouble believing that it's that simple... but I'm having even more trouble thinking of an example where that wouldn't work for my situation... now I just feel dumb.

I guess the only follow up question would be to clarify that....is it a) constantly pulling records from the db in that order, or does it b) Sort the list once in that order, but you have to make it resort to preserve always dialing the newest leads

BTW, I wanted to thank you for all the work you've done with this software and how helpful you and other admins have been on these forums, you guys are great!
ViciBox v.7.0.2-160325
VICIDIAL-VERSION: 2.12-550a BUILD: 160414-1013
Asterisk 11.22.0-vici
1 Database Server
MariaDB 10.1.6
2 Web Servers
Multiple Dial Servers
ajax1515
 
Posts: 70
Joined: Wed Sep 23, 2015 11:23 am

Re: List Sorting By LIFO

Postby mflorell » Fri Dec 11, 2015 4:04 pm

The hopper script always sorts leads as they are pulled to go into the hopper, and the campaign Lead Order field will determine how it sorts them. By default, the database will sort them by the order in which they were inserted, but it's not difficult to change that.

If you don't sort by DOWN or UP lead order, you can use the LEAD_ID(which is insertion order) as a Secondary Order for the campaign.

Glad we could be of some help :)
mflorell
Site Admin
 
Posts: 18387
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida


Return to Support

Who is online

Users browsing this forum: Google [Bot] and 61 guests