Table updated with the list

I have a form with a list of table row id numbers in the order that I want the lines to be displayed. I need day field of 'dispalyOrder' of the table based on this list.

Currently, I am looping through the list and set the "Form.displayOrder" variable with the number of loops and setting the "Form.catID" variable with the element in the County using ListGetAt list. I then do a cfupdate to update the line.

It's fine for the short list, but when there are 100 or more items in the list there are a lot of hits to the database and usually stops at one point.

Is there a way to make a to the database to update all the lines?

I'm a programmer turned designer so that I can't seem to find online help I don't understand yet.
Thanks for any help provided.

I use 7 MX with a SQL 2000 database.


My current code is attached below.

Now all the code in your first post is replaced by this one cfquery (which should be 100 times faster.)

Please note that I used my best guess on the form and the column names.

Tags: ColdFusion

Similar Questions

  • update of the list of imap folders

    How do you quickly update the list of imap folders?

    I was hoping F5 or so would just, but retains the Thunderbird download (how can this be prevented?-stop button does not work) messages received, but the update of the lists of file seems to need a reboot.

    The fastest way is to close and reopen the ThunderBird, which is a bit awkward. A simple F5 on the folder main mbx should update the files in a folder should update this file, always appealed to a low level (can be configured to do more/less with SHIFT f5 etc.).

  • Update with the Lead feature and several lines

    I have a table such as:

    Table1:

    OrderNumber EFFECTIVE_DATE EFFECTIVE_END_DATE FileName

    123 11/5/2015-12/31/2099 File5.txt

    123, 7/11/2015-12/31/2099 File7.txt

    or it can look like:

    Table2

    OrderNumber EFFECTIVE_DATE EFFECTIVE_END_DATE FileName

    123 11/5/2015-11/7/2015 File5.txt

    123, 7/11/2015-11/9/2015 File7.txt

    123 11/9/2015-12/31/2099 File9.txt

    123 11/15/2015-12/31/2099 File15.txt

    I want to take the 2nd to the last EndDate and update with the previous value.

    So in fact, it would look like this.

    Table1:

    OrderNumber EFFECTIVE_DATE EFFECTIVE_END_DATE FileName

    123 11/5/2015-11/7/2015 File5.txt

    123, 7/11/2015-12/31/2099 File7.txt

    or

    Table2

    OrderNumber EFFECTIVE_DATE EndDate FileName

    123 11/5/2015-11/7/2015 File5.txt

    123, 7/11/2015-11/9/2015 File7.txt

    123-11/9/11/15 to 2015/2015 File9.txt

    123 11/15/2015-12/31/2099 File15.txt

    I got it work in a select statement to a single value. now I just need help it enter an UPDATE statement and update all records.

    SELECT W.EFFECTIVE_DATE, W.EFFECTIVE_END_DATE,

    NVL (LEAD (W.EFFECTIVE_DATE, 1) (ORDER implementation W.EFFECTIVE_DATE), December 31, 99 ') AS 'EFFECTIVE_DATE_NEW '.

    OF WH_ORDERS_REPORT W

    WHERE ORDERNUMBER = '10460992';

    It did not work:

    UPDATE WH_ORDERS_REPORT WH

    SET EFFECTIVE_END_DATE = (SELECT NVL (LEAD (WH2. EFFECTIVE_DATE, 1) (ORDER of WH2. (EFFECTIVE_DATE), DECEMBER 31, 99 ')

    OF WH_ORDERS_REPORT WH2

    WHERE WH. ORDERNUMBER = WH2. ORDERNUMBER)

    I appreciate your help in the creation of an update statement to do this.

    Rap, but it's working now.  I'll confirm with a few other records before I mark as correct, but what I see so far, it is beautiful, thank you!

    merge into WH_LIFELINE_ORDERS_REPORT D

    a_l'_aide_de)

    Select

    DISTINCT ORDERNUMBER,

    CURRENTSTATUSDATETIME,

    NVL (LEAD(EFFECTIVE_DATE, 1) ON (ORDERNUMBER partition

    (EFFECTIVE_DATE order), December 31, 99 ') as EFFECTIVE_END_DATE

    of WH_LIFELINE_ORDERS_REPORT

    ) S

    WE (D.ORDERNUMBER = S.ORDERNUMBER

    AND D.CURRENTSTATUSDATETIME = S.CURRENTSTATUSDATETIME

    )

    When matched then

    setting a day of set D.EFFECTIVE_END_DATE = S.EFFECTIVE_END_DATE;

  • Restrictions does not not after ISO put 10.0.1 update with the new iPhone 7

    Restrictions does not after ISO put 10.0.1 update with the new iPhone 7 any which option of ranking app I don't choose no changes are made.  All the patches?

    Thank you

    Hello Launcher,

    Thank you for bringing your question about Restrictions here in Apple Support communities. My understanding of your question is that you change the Restrictions, but no change is noticed. I tried the same on my iPhone 6 Plus running iOS 10 and noticed a similar situation. Please allow me the opportunity to explain how the Restrictions is designed to work. First, I put my limitations for applications, do not allow Apps and together 4 +, which basically means everything beyond 4 + will be blocked from buying. Then I went to the App Store and the first app that caught my attention was NCIS: hidden crimes. This app is rated 12 + and is definitely an application I would not want my toddler to help. It is that Restrictions come into play. When I type on NCIS: hidden Crimes, the Get option is grayed out. Restrictions does remove all apps, songs, books, etc. from view, but it will prevent the purchase, download, and install all applications rated above the setting you choose when you set up restrictions. It's the help article that discusses the Restrictions and prevent purchases: Use Restrictions in order to avoid buying on iPhone, iPad, or iPod touch.

    I checked on the restrictions help articles, and I understand where it can be a bit confusing. In the help article Use Restrictions on iPhone, iPad and iPod touch, it says "You can use Restrictions, also known as parental control, to block or limit specific applications and features on your iPhone, iPad or iPod touch." This means in fact that apps, features or services (rated above that helped you, or if you have turned off completely) can he no longer appears on the device if the restriction is activated and starts blocking them. I also tested this by activating Restrictions and turned the cursor for Safari to off. When I went back to the home screen, Safari doesn't show any more and I could no longer use it.

    I hope this helps to clarify how the Restrictions. If my understanding of the issue was not accurate to the issue that you are experiencing, I will be happy to pursue this issue with you. Please indicate exactly what you took measures, and what expectations you had or the some restrictions, applications, features, or services you are restricted. Thanks again and have a great rest of your day!

  • I bought an iphone used several years ago... hen his recently updated with the new iOS 7.1.2 it was locked with the previous owners account.how can I use my iphone is back with my apple and pass

    I bought an iphone used several years ago... When updating with the new iOS 7.1.2 recently, he was locked with previous apple owners account.

    its now useless. I didn't know all these crappy activation locks and all.now I have no idea

    How can I find my iphone is off and use my phone back

    iphone 4 32 gb

  • Bug in reporter Panel updated with the property Value Chart

    Hi guys,.

    Defer to what the Panel update property is set to true and chart is updated with the help of node "Property value", data are not updated graphics. Capture of the block diagram and VI (2014) screen gasket.

    Is this a known bug, and is there any fix for it?

    Thank you

    Knockaert

    I have not tried running your code, but here are some possible solutions:

    1. There is a primitive to write the value of a control by index (added in ~ 2013). This is designed to be used others live too and should work like a local.
    2. You can send data using another way (like a queue, etc.).
    3. Use the Ctl Val.Set method.
    4. Do not use a chart. Use a chart and manage the buffer yourself. You can find some examples if you're looking for graph XY.
  • Please help me understand how to install updates with the following error updated Message__The following have not been installed: __Security update for Microsoft XP KB 2289162

    Please help me understand how to install updates with the following error Message

    The following updates were not installed:

    Security for Microsoft XP KB 2289162 update

    See the section "How to get help" of http://support.microsoft.com/kb/2289162

    For individuals, please visit the Microsoft Solution Center and antivirus security for resources and tools to keep your PC safe and healthy.  If you have problems with the installation of the update itself, visit the Microsoft Update Support for resources and tools to keep your PC updated with the latest updates.

    Buying to meet problems installing Microsoft security updates also can visit the following page for assistance: https://consumersecuritysupport.microsoft.com/

    ~ Robear Dyer (PA Bear) ~ MS MVP (that is to say, mail, security, Windows & Update Services) since 2002 ~ WARNING: MS MVPs represent or work for Microsoft

  • I am also having the same problem with the same updates. I have Windows XP SP3 and it's updates with the problem.

    I am also having the same problem with the same updates. I have Windows XP SP3 and it's updates with the problem.

    Security Update for Microsoft .NET Framework 2.0 SP2 on Windows Server 2003 and Windows XP x 86 (KB2572073)
    A security update for .NET Framework 2.0 SP2 and 3.5 SP1 on Windows Server 2003 and Windows XP x 86 (KB2518864)
    Security Update for Microsoft .NET Framework 2.0 SP2 on Windows Server 2003 and Windows XP x 86 (KB2633880)

    They all install properly but switches back to windows update to install. It's some kind of loop.

    Hi billy73,

    In addition, if you still have questions, please take a look at the thread similar here with a solution as possible.

    I hope this helps!

  • kb2633171 a security update wont install windows vista and keeps on saying failed in the history of updates with the error code 80070020

    Original title: kb2633171 security update will not install windows vista

    Hello

    as noted above, the kb2633171 of security update will not install on my computer used windows vista laptop. I had mcafee installed since the first day (it came with the pc). He continues saying failed in the history of updates with the error code 80070020. When I restart the pc, it says that it cannot configure the update and it is up to the old settings.

    I ran the fix it and aggressive to solve this problem, no luck :-(

    any help muchly appreciated.
    Thank you!

    Chiara

    Hi Chiara,

    Try following the steps in the following article.

    You receive error 0 x 80070020 when you use the Windows Update Web site or the Microsoft Update Web site to install the updates

    http://support.Microsoft.com/kb/883825

     

    Let us know if it helps.

  • Does not receive the table name in the list of schema objects creating EO

    Hello

    IAM does not have my name of the table custom in the list of schema objects during the creation of EO.

    I created a custom table and I need to use this table looks for creation EO,

    But while creating the EO, I'm not able to find the table in the schema object list.

    in the connection database, these tables are present, but only in this window (window of creation of Eo) these tables do not come

    can someone please help how to solve this problem.

    Hello

    I found the solution

    in business components that there is another database link that I've changed now, it works fine now

  • In our Web page we have pages with lists of the pdf reports that we want to make available. I tried a search engine, but it only directs you to the page with the list. How can we lead the researcher to a specific report?

    In our Web page we have pages with lists of the pdf reports that we want to make available. I tried a search engine, but it only directs you to the page with the list. How can we lead the researcher to a specific report?

    Exactly, it would depend on how you have set the referencing of your site, please check the suggestions made in this tutorial:

    https://helpx.Adobe.com/Muse/how-to/sitemap-XML-file-explained.html

    In addition, you can check these:

    http://musewidgets.com/collections/all/SEO

    Thank you

    Sanjit

  • [JS] [CS4] - populating a drop down with the list of printers?

    Hello

    I am filling a drop down field with the list of available printers. Here's what I have:

    var app.printerList = printerList;

    var w = new Window ("dialog");
    w.orientation = 'row';
    var dropDown = w.add("statictext", undefined, "Please select the printer");
    var dropDown = w.add ("dropdownlist", undefined, printerList);
    dropDown.selection = 0;
    var buttonGroup = w.add ("group");
    buttonGroup.add ("button", undefined, "OK");
    w.center();
    w.show();
    

    This will fill a drop down with "Printer, printer, printer, printer" for each printer instead of the printer name (which is what I want).

    When I try:

    var printerList = app.printerList.name;
    

    I get a drop of water to the bottom of the empty entries.

    Any ideas on what I am doing wrong?  Exactly how does the printerList?

    Thank you

    Lindsay

    It also takes to still in my system, so I would add the following line

    var pL = app.printerList;
    

    and pL to avoid multiple calls to the system. for example

    var arrayPrinterNames = [];
    for (var i = 0; i < iCount; ++i) {
              arrayPrinterNames.push(pL[i].name);
    
  • Problem with the list item

    Hi all
    I am facing a problem with the list item in my form. In my form, I have a list item (tmd_stat) with 3 list of values as the item complete, incomplete and null.this lies in the control block.

    I have a block (Detail) which is the database block.status_disp [point List] is one of the .an article on the value of list tmd_stat is filling with different values.

    an alert message (you want to change the status? Yes/No) will appear when we change the list item. If I click YES then the list works and retail block point status_disp is filled with a different list of values. If I click on 'No' the list value will be set to changed value.i.e suppose that I'm changing the Complete incomplete list item, alert message will be displayed. If I click on 'No' the cursor is placed on incomplete but incomplete. How can I place the cursor on the full value.

    Can you please give me the solution.

    Thank you

    Hello

    Save the old value in a variable and then if the user clicks on No. then reassign this value to the list item.

    Kind regards

    Manu.

  • Updated with the values in the same table, for other records corresponding to conditions

    Hi Experts,

    Sorry do not provide the structure of the table (it is a simple structure)

    I have a requirement where I need to update the columns of a table based on the same table with some match empid and date values. If the date and empid match so I have these values to any other folder and update of one who is not having details of Office . I need the Update query

    Before the update my array of values is as below

    Sort_num Emp_id Bureau start_date

    1 101 AUS 01/01/2013
    2 101 01/01/2013
    3 101 15/01/2013
    4 103 USA 01/05/2013
    5 103 01/01/2013
    6 103 05/01/2013
    7 104 FRA 01/10/2013
    8 104 10/01/2013
    9 104 01/01/2013

    After update my table should be as below

    Sort_num Emp_id Bureau start_date

    1 101 AUS 01/01/2013
    2 101 AUS 01/01/2013
    3 101 15/01/2013
    4 103 USA 01/05/2013
    5 103 01/01/2013
    6 103 USA 01/05/2013
    7 104 FRA 01/10/2013
    8 104 FRA 01/10/2013
    9 104 01/01/2013

    Thanks in advance

    I don't have the time to create the table with the data, but basically, you should be able to code the following text

    update one table

    Office set = (select desktop in table b where b.emp_id = a.emp_id)

    and b.start_date = a.start_date

    and b.office is not null

    )

    where is ([as well as overall query])

    and a.office is null

    In my opinion, who will do the trick.

    HTH - Mark D Powell.

  • The city map can be updated with directory list

    Here's the scenario. A city has a business district that is in need of a printable card Vista aerea (posters) with numbers indicating each company. These numbers match a key/directory that lists the number and the name of the company. The plan is updated frequently as businesses come and go. I want the plan to renumber itself during changes. For example, if the company has marked as "4." should be removed from the map, the rest of the indicators would renumber themselves and the directory would itself be renumbered then as well (so that the list is not a missing number). Is - this feesible in InDesign?

    You can do it easily

    (1) add the map to the page (THE LABELS SHOULD NOT BE PART OF THE map)

    (2) create a paragraph of card label style 'map labels' and include a numbered list 'map Lables List'

    (3) the installation program, an object style he call card labels set the paragraph style to the map labels.

    Set the filling, corner options etc as you like.

    (4) make a text frame and put in it the name of the place, and apply the object labels card style.

    (5) use him copy / paste to add a label to all the places you need.

    5 (b) Important! and a bit hard don't copy and paste it in the ideal order of the list

    In the example below, Europe was coppied last, so he go numbered 3, most desired order (from left to right, from top to bottom) could be, USA, Europe, Africa

    (6) set up a new style of the object and all the colours None call Invisible

    (7) after completing the labelling of all place names select all elements on the page (Ctrl / Comand A) and run this small excerpt

    var selection = app.selection,
          l = selection.length;
    while (l--) if (selection[l].hasOwnProperty ('contents')   && selection[l].appliedObjectStyle = "Map Labels") {
        selection[l].name = selection[l].contents;
        selection[l].insertLabel("Map Labels", "1");
    }
    app.activeWindow.activePage.insertLabel("Map", "1"); // Label Page for future reference
    

    You have now nominated all your linked text frames, and they can be referenced asfor example myDoc.textFrames.itemByName ("USA")

    And you can identify them as map labels using textFrame [x] .extractLabel ("card labels") == 1;

    (8) in case you're wrong in the future, save a copy of the doc.

    (9) make one style of character "Names" and apply in your document only on the names you want marked on your map.

    either you have to have a certain text (s) somewhere in the document

    The USA is really...

    Africa is...

    10 now, every time you have different references run the following script and update the map labels

    // Labeling script
    // by Trevor (www.creative-scripts.com coming soonish custom and readymade scripts for adobe indesign and other products)
    app.doScript("labelMap()", ScriptLanguage.javascript, undefined, UndoModes.ENTIRE_SCRIPT, "Lable Map");
    function labelMap() {
        var doc = app.activeDocument;
                    app.findTextPreferences = app.changeTextPreferences = null;
                    app.findTextPreferences.appliedCharacterStyle = "Place Names";
        var myPageId = checkForObjectByLabel(doc.pages, "Map");
        if (myPageId === false) {alert("No Map\rBye"); exit();};
        myPageId = myPageId[0];
        var mapPage = doc.pages.itemByID(myPageId),
              mapLabels = checkForObjectByLabel (mapPage.textFrames, "Map Labels"),
              l = mapLabels.length, label, lableFrame;
        while  (l--) {
            lableFrame = mapPage.textFrames.itemByID(mapLabels[l]);
            if (!lableFrame.isValid) continue;
            lableFrame.applyObjectStyle (doc.objectStyles.itemByName("Invisible"), true);
            lableFrame.contents = "";
        }
    
        // Find names
        var myFinds = doc.findText();
        l = myFinds.length;
        while (l--) {
            label = myFinds[l].contents;
            lableFrame = mapPage.textFrames.itemByName(label);
            if (!lableFrame.isValid) continue;
            lableFrame.contents = label;
            lableFrame.applyObjectStyle (doc.objectStyles.itemByName("Map Labels"), true);
        }
    }    
    
    function checkForObjectByLabel (obj, label, from, to) {
        from = from || 0;
        if (obj .hasOwnProperty('length')) obj = obj[0];
        var parent = obj.parent;
        var co = obj.constructor.name;
        co = co[0].toLowerCase() + co.substr (1, co.length) + "s";
        var objects = (from != undefined && to != undefined) ? parent[co].itemByRange (from, to) : parent[co].everyItem();
        var objectsLabels = objects.extractLabel(label);
        var reg = /1/g;
        objectsLabels = ("," + objectsLabels.join()).replace (/,1/g, "1");
        reg.lastIndex = 0;
        var n = 0;
        var ids = [];
        var found = true;
        while (found = reg.exec (objectsLabels)) ids[n++] = parent[co] [(reg.lastIndex = found.index + 1) - 1 + from].id;
        return (ids.length > 0) && ids;
    }
    

Maybe you are looking for

  • Unable to reset iPod Touch/iCloud disabled on iPod Touch

    I want to remove the restrictions on my iPod Touch (iOS version 9.3.2), but for this I need to factory reset the unit. For this I need to disable find my iPod, but the "iCloud" in the application settings tab has been grayed out and disabled due to c

  • Black screen suddenly on Equium A210-17i

    The screen on my Equium A210-17i will sometimes just completely black, although always backlit. This happens usually when the computer is left on during a fairly long period of time (tonight after 3 hours) when using it. When it happened tonight I ju

  • Unable to connect to wireless internet

    I just put a new HD in my Satellite L35-S2161. I haven't used the Toshiba restore disk, instead I used my XP Pro / SP3 disk. I have two problems. First of all, I can't my wireless to work. I installed the Driver PCI Atheros and the Atheros customer U

  • Wireless does not. model wndr3700v2

    We have this router and this is the kind of old... 2011 model wndr3700v2. We have never had any problems with it until tonight. It says 'unavailable internet for netgear' my phone connects to the internet, but a few seconds later, it says not availab

  • Tips to remember when using the state machine in queue

    I was able to work through the convert my architecture of State Machine for a BAU, thus eliminating the use of nodes of property/local variables to send data values to my machine of the State, but rather to send through queues. I would like some advi