Scan listeners number and balancing result

Hello,
inside the docs 3 scan listeners are usually referred.
But is it correct to say that with this setup and only 2 RAC nodes, you will normally have an unbalanced cluster, and one node with two times the connections of the other one?
Because if you use round robin DNS you will get 2/3 of resolutions to one node (the one that has got two of the 3 associated IPs bound) and 1/3 to the other one.
So in case of 2 nodes, would it be better to have only 2 scan listeners, or set a 4th one eventually?
Thanks,
Gianluca

It is not an unbalanced cluster , scan listeners will only direct the incoming request to the node listener of the instance with lesser  load.
All scan listeners will have all instances in cluster registered with it and so each listener know to which node the connection request should be sent to balance the load.
Even in case of a 10 node cluster, 3 scan listeners would be sufficient,  it is not necessary to have scan listener running on each node to send the connections to that node.
http://www.oracle.com/technetwork/products/clustering/overview/scan-129069.pdf

Similar Messages

  • Scanning .txt file and outputting results?

    Greetings Everyone. My employer has charged me with a rather
    confusing task. Basically I need to scan a .txt file and retrieve
    some information from it. Here is a little background on the file
    itself.
    This is a feed file containing the information for employees
    such as name, department, employement status etc...Zeros are used
    in place of spaces in this file. What I am charged with is
    retrieving the employment status and name for every single person
    in the file (60,000+).
    I need to write a coldfusion script that can do the
    following.
    1. Scan a .txt file that is sent to me every night and look
    for the 99th character on each line of the .txt file
    2. If the 99th character is a 'T' I need to pull characters
    '10-50' (which contain the name for that person).
    3. Output the results of the scan to a coldfusion page
    displaying the individuals' names.
    If anyone out there can point me in the right direction I
    would be very grateful. I've been looking for websites on this
    topic but I have been unsucessful so far. Should I post this in the
    advanced section of the cf forums? Once again, thank you for any
    help you can give me.

    I guarantee you can do this! And it shouldnt be to hard so
    you can breath a sigh of relief... :)
    I would use <cffile action="read" file="filepath/name.txt"
    variable="fileContents">
    Then you should be able to do something like <cfset
    fileArray = ListToArray(fileContents, "#CHR(13)##CHR(10)#")>
    Now you have an array so you can loop through and try
    something like the following...
    <cfloop index="i" from="1" to="#ArrayLen(fileArray)#"
    step="1">
    <cfif fileArray
    NEQ "">
    <!--- Find 99th Char --->
    <cfset 99thchar = Mid(fileArray, 99, 1)>
    <cfif 99thchar EQ "T">
    <!--- Get Name --->
    <cfset empName = Mid(fileArray
    , 10, 40)>
    <!--- Change 0's to Spaces--->
    <cfset empName = Replace(empName, "0", "#CHR(32)#")>
    <cfoutput>#empName#</cfoutput><br />
    </cfif>
    </cfif>
    </cfloop>
    That should be close to what you could use... You may have to
    tweak it a bit... now if it is going though 60000+ records this may
    take a while...lol You might have to use the cfsetting tag to
    extend the normal request timeout..
    Hope this helps!

  • Scan Listeners

    Hi,
    Wanted to know more about scan listeners.
    Q1) Are there always 3 scan lsiteners? cant there be more or less than 3?
    Q2) On what factor are the scan listeners number dependent on ? Is it on number of scan ips which are three?
    Q3) What is the actaul role of scan listener ? Does is talk with normal listener?
    Regards
    ID

    Hi,
    1007033 wrote:
    Hi,
    Wanted to know more about scan listeners.
    Q1) Are there always 3 scan lsiteners? cant there be more or less than 3?
    Q2) On what factor are the scan listeners number dependent on ? Is it on number of scan ips which are three?
    Q3) What is the actaul role of scan listener ? Does is talk with normal listener?
    Regards
    IDScan listeners number depend scan IP addresses. You can use 1 IP address for scan IP.
    Oracle recommend 3 scan IP address for scalability. Actual role of scan listeners,
    when you add or remove instance from cluster, then not need changes on clients.
    SCAN listeners talk with local listeners, and there have load balancing on scan.
    Check interesting article : http://www.oracle.com/technetwork/products/clustering/overview/scan-129069.pdf
    Regards
    Mahir M. Quluzade

  • SAP- AR Report by customer, account number and bucket

    Hello SAP Guru's,
    I am looking for a report that has Customer name, Account number and balance by bucket(30 day, 60, 90, 120).  I have seen this several times but cannot find it anywhere.  Can anyone tell me/ help me with this?
    Will award points.
    THANKS!!!

    To clarify-
    it would look something like this:
    Customer Account #  Customer Name  30 day  60 day  90 day  120+
    123456789                ABC Company    100.00      0.00  50.00    5,0972.00
    222222222                Another Co.         0.00     125.00  150.00   0.00
    Thanks!
    POINTS Awarded

  • Retreiving number and characters from string

    Hello fellow developers,
    Lets say i have the following string ER686 and want to split the string into a number and characterpart resulting in a String "ER" and an int "686". What is the best approach to accomplish this?
    Thank you for any help offered.

    The format is that there's a sequence of strings 2 or
    3 and a squence of numbers 3 or 4You might use a Pattern matcher, using a regular expression like the following :"(\\D{2,3})(\\d{3,4})"This expressions represents "two or three non-digit characters followed by 3 or 4 digits". The parenthesis are here to allow getting the two elements (groups) separately.
    Use the find() method of the matcher, then retrieve the two groups with group(1) and group(2).
    Eventually, parse the latter if required.

  • I have used Image Capture to scan images/documents and then saved them as either PDFs or PNG files.  For some reason, just this past week Image Capture will no longer save the file.  It scans, and the Scan Results window pops up, but it won't save file.

    I have used Image Capture to scan images/documents and then saved them as either PDFs or PNG files.  For some reason, just this past week, Image Capture will no longer save the file.  It scans, and the Scan Results window pops up, but it won't save file.
    The file name has no special character in it, just letters and no spaces.
    I have done this in the past and it has worked, but now it will not.
    I have not upgraded any software, that I am aware of.
    After scanning, the Image Capture pops up the Scan Results with the file name in the window, but neither the Scan Results nor the Image Capture window responds to inputs.  The Image Capture window is frozen, with only the "Overview" and "Cancel" buttons active (but non-responsive).
    Is this a software issue or a scanner hardware issue?  I am using a HP Photosmart C6200 series printer/scanner on a network using a Time Capsule airport.
    Thanks.

    I had the same problem.
    Got a 90% fix.  Apparently the Mavericks preferences won't work with Yosemite, so I just deleted the Image Capture preferences.
    Unfortunately, the "Scan to" folder seems to be permanently set to the Pictures folder.
    1.  Quit Image Capture
    2.  Go to Finder > Go > Home, which opens up your home folder (named after your user name)
    3.  Open Library > Preferences > com.apple.ImageCapture.plist - Drag this file to the Trash
    4.  Start "Image Capture", click "Details" and change all your settings as you prefer
    5.  Quit and restart "Image Capture".   Notice it remembers all your settings except "Scan to" folder.  It insists on saving to "Pictures".
    That's as far as I was successful.  I tried changing the "Scan to" folder to "Desktop", but on launch, Image Capture always sets it back to "Pictures".
    This is what I tried:
    6.  Download and install "Pref Setter" from http://www.nightproductions.net/prefsetter.html
    7.  Quit "Image Capture".  Right-click on "com.apple.ImageCapture.plist" and open with Pref Setter.
    8.  Search for "Pictures", which finds "~/Pictures" (the tilde character at the start means your home directory).
    9.  Double-click on "~/Pictures" and change it to the folder you prefer.  I like "~/Desktop"
    10. Choose File > Save then Quit from Pref Setter.  Note that re-opening the plist file still shows "~/Desktop"
    11. Start up "Image Capture" -- on startup, "Image Capture" sets "Scan to" folder to "Pictures"
    I consider this a bug.

  • How to create URL link for telephone number ,open to account search page and account result page ?

    Hi Experts,
    Bussines role - ZCC_ICAGENT 
    If user open this bussiness role and open Account page ,user enter telephone number and enter search account ,then result will be displayed.Instead of 3 clicks ,user click direct URL link ,telephone number is parameter,account Search and account result  page will be opened direct link.
    So how to do it..could you please provide me step by step...what are the steps wee need to follow for creating URL ..how to do it..Please help..
    Thanks
    Kalpana

    Hi kalpana,
    You dont need to do any setting for this.
    Following URL will be used as per your requirement.
    http://rrnewcrm.ril.com:8000/sap(bD1lbiZjPTI0MiZkPW1pbg==)/bc/bsp/sap/crm_ui_start/default.htm
    ?sap-system-login-basic_auth=X&sap-system-login=onSessionQuery&saprole=ZCC_ICAGENT&
    sap-phoneno=9999999999
    Here parameter sap-phoneno will contain the number you want to search for.
    In component ICCMP_BP_SEARCH, go to view BuPaSearchB2B. write below code in its inbound plug IP_INBOUNDPLUG-
    DATA: lt_ivr_url_param TYPE tihttpnvp,
             ls_ivr_url_param TYPE ihttpnvp,
             lr_searchcustomer TYPE REF TO if_bol_bo_property_access,
             ls_searchcustomer TYPE crmt_bupa_il_header_search.
    CALL METHOD cl_crm_ui_session_manager=>get_initial_form_fields
           CHANGING
             cv_fields = lt_ivr_url_param.
    lr_searchcustomer ?= me->typed_context->searchcustomer->collection_wrapper->get_current( ).
         CHECK lr_searchcustomer IS BOUND.
    READ TABLE lt_ivr_url_param INTO ls_ivr_url_param WITH KEY name = 'sap-phoneno'.
    IF ls_ivr_url_param-value IS NOT INITIAL.
             ls_searchcustomer-telephone = ls_ivr_url_param-value.
       CALL METHOD lr_searchcustomer->set_properties( EXPORTING is_attributes = ls_searchcustomer ).
             eh_onsearch( ).
        ENDIF.
    Thanks & Regards
    Richa

  • SCAN listeners and default listener all goes to 2nd node

    I installed GRID/Oracle yesterday and I saw on the first node, there are scan-listener1,2 and on second node, it has scan-listner3.
    This morning,I try to create db by dbca, and it give me a warning that there is no default listener on local node.
    Then I checked, there is none any listener at all on local node:
    ps -ef|grep tns
    grid 31295 30685 0 13:47 pts/1 00:00:00 grep tns
    but all on second node:
    ps -ef|grep tns
    grid 13518 1 0 00:14 ? 00:00:00 /u01/app/11.2.0/grid/bin/tnslsnr LISTENER_SCAN1 -inherit
    grid 13536 1 0 00:14 ? 00:00:00 /u01/app/11.2.0/grid/bin/tnslsnr LISTENER -inherit
    grid 15878 15566 0 13:48 pts/0 00:00:00 grep tns
    grid 16945 1 0 06:22 ? 00:00:00 /u01/app/11.2.0/grid/bin/tnslsnr LISTENER_SCAN3 -inherit
    grid 16959 1 0 06:22 ? 00:00:00 /u01/app/11.2.0/grid/bin/tnslsnr LISTENER_SCAN2 -inherit
    How to explain this situation? How all the listener failed to second node?
    WHere is the log I can check?
    Thanks

    Thanks for your help.
    Here are results from commands you recommended:
    [grid@oracle01. bin]$ ./crsctl check crs
    CRS-4638: Oracle High Availability Services is online
    CRS-4537: Cluster Ready Services is online
    CRS-4529: Cluster Synchronization Services is online
    CRS-4533: Event Manager is online
    [grid@oracle01. bin]$ ./crsctl check cluster -all
    oracle01:
    CRS-4537: Cluster Ready Services is online
    CRS-4529: Cluster Synchronization Services is online
    CRS-4533: Event Manager is online
    oracle02:
    CRS-4537: Cluster Ready Services is online
    CRS-4529: Cluster Synchronization Services is online
    CRS-4533: Event Manager is online
    [grid@oracle01. bin]$ ./crsctl stat res -t
    NAME TARGET STATE SERVER STATE_DETAILS
    Local Resources
    ora.LISTENER.lsnr
    OFFLINE OFFLINE oracle01
    ONLINE ONLINE oracle02
    ora.OCR_VOTE.dg
    ONLINE ONLINE oracle01
    ONLINE ONLINE oracle02
    ora.REME_DAT.dg
    ONLINE ONLINE oracle01
    ONLINE ONLINE oracle02
    ora.REME_FRA.dg
    ONLINE ONLINE oracle01
    ONLINE ONLINE oracle02
    ora.asm
    ONLINE ONLINE oracle01
    ONLINE ONLINE oracle02
    ora.gsd
    OFFLINE OFFLINE oracle01
    OFFLINE OFFLINE oracle02
    ora.net1.network
    ONLINE ONLINE oracle01
    ONLINE ONLINE oracle02
    ora.ons
    ONLINE ONLINE oracle01
    ONLINE ONLINE oracle02
    ora.registry.acfs
    ONLINE ONLINE oracle01
    ONLINE ONLINE oracle02
    Cluster Resources
    ora.LISTENER_SCAN1.lsnr
    1 ONLINE ONLINE oracle02
    ora.LISTENER_SCAN2.lsnr
    1 ONLINE ONLINE oracle02
    ora.LISTENER_SCAN3.lsnr
    1 ONLINE ONLINE oracle02
    ora.cvu
    1 OFFLINE OFFLINE
    ora.oc4j
    1 ONLINE ONLINE oracle01
    ora.oracle01.vip
    1 ONLINE INTERMEDIATE oracle02 FAILED OVER
    ora.oracle02.vip
    1 ONLINE ONLINE oracle02
    ora.scan1.vip
    1 ONLINE ONLINE oracle02
    ora.scan2.vip
    1 ONLINE ONLINE oracle02
    ora.scan3.vip
    1 ONLINE ONLINE oracle02
    [grid@oracle01. bin]$
    You can see here ora.oracle01.vip has failed over to second node. what is the cause of this issue?
    Thanks.

  • Agent reports SCAN listeners incorrectly

    I an running Enterprise Manager 12.1.0.3 and the agents in question have been upgraded to 12.1.0.3 agents.
    On a two node cluster, node names are Aporia & Lepisma the OEM console is not reporting the scan listeners correctly. There are three scan listeners -
    SCAN VIP scan1 is enabled
    SCAN VIP scan1 is running on node lepisma
    SCAN VIP scan2 is enabled
    SCAN VIP scan2 is running on node aporia
    SCAN VIP scan3 is enabled
    SCAN VIP scan3 is running on node aporia
    however emctl config agent listtargets on host Aporia shows all three scan listeners whereas on Lepisma only scan1 is reported currently. Relocating the listeners using the srvctl command will cause a listener to run on the other node but the agent does not see the change, listtargets still reports them the same way (I hope I am explaining this clearly).
    On node Aporia I ran the command -
    emctl control agent runCollection agent12c2_5_aporia:oracle_home oracle_home_config
    hoping that would cause the agent to report correctly but to no avail. I may not be using the correct syntax for the runCollection command.
    As a result when looking at the scan listeners in the OEM console all three are reported on Aporia with scan2 always reported as down and Lepisma only reports scan1, regardless of where it is running. For some reason the agent is not reporting the status of the listeners correctly and I need help resolving that problem. The results of the srvctl and emctl config agent on each node show the following -
    Information from Aporia -
    maxprod:product/agent12g->srvctl status scan
    SCAN VIP scan1 is enabled
    SCAN VIP scan1 is running on node lepisma
    SCAN VIP scan2 is enabled
    SCAN VIP scan2 is running on node aporia
    SCAN VIP scan3 is enabled
    SCAN VIP scan3 is running on node aporia
    maxprod:product/agent12g->./agent_inst/bin/emctl config agent listtargets
    Oracle Enterprise Manager Cloud Control 12c Release 3
    Copyright (c) 1996, 2013 Oracle Corporation.  All rights reserved.
    [aporia.ucdavis.edu, host]
    [aporia.ucdavis.edu:3872, oracle_emd]
    [Ora11g_gridinfrahome1_1_aporia, oracle_home]
    [OraDb11g_home4_2_aporia, oracle_home]
    [sbin12c1_6_aporia, oracle_home]
    [+ASM_PPSSCAN, osm_cluster]
    [OraDB11g_Gateway_Home_11203_4_aporia, oracle_home]
    [LISTENER_SCAN2_PPSSCAN, oracle_listener]
    [LISTENER_SCAN3_PPSSCAN, oracle_listener]
    [has_aporia.ucdavis.edu, has]
    [maxdss.ucdavis.edu, oracle_database]
    [maxprod.ucdavis.edu, oracle_database]
    [fleetpro.ucdavis.edu, oracle_database]
    [gsprod.ucdavis.edu, oracle_database]
    [pbop.ucdavis.edu, oracle_database]
    [maxarch.ucdavis.edu, oracle_database]
    [olap.ucdavis.edu, oracle_database]
    [ppsprod.ucdavis.edu, oracle_database]
    [isodprod.ucdavis.edu, oracle_database]
    [LISTENER_aporia.ucdavis.edu, oracle_listener]
    [+ASM1_aporia.ucdavis.edu, osm_instance]
    [agent12c2_5_aporia, oracle_home]
    [ucopp_aporia.ucdavis.edu, oracle_database]
    [LISTENER_SCAN1_PPSSCAN, oracle_listener]
    Information from Lepisma -
    isoddev:product/agent12g->srvctl status scan
    SCAN VIP scan1 is enabled
    SCAN VIP scan1 is running on node lepisma
    SCAN VIP scan2 is enabled
    SCAN VIP scan2 is running on node aporia
    SCAN VIP scan3 is enabled
    SCAN VIP scan3 is running on node aporia
    isoddev:product/agent12g->./agent_inst/bin/emctl config agent listtargets
    Oracle Enterprise Manager Cloud Control 12c Release 3
    Copyright (c) 1996, 2013 Oracle Corporation.  All rights reserved.
    [lepisma.ucdavis.edu, host]
    [lepisma.ucdavis.edu:3872, oracle_emd]
    [Ora11g_gridinfrahome1_8_lepisma, oracle_home]
    [OraDb11g_home4_10_lepisma, oracle_home]
    [sbin12c1_12_lepisma, oracle_home]
    [has_lepisma.ucdavis.edu, has]
    [LISTENER_SCAN1_PPSSCAN_1, oracle_listener]
    [+ASM_PPSSCAN, osm_cluster]
    [FLEETDEV.ucdavis.edu, oracle_database]
    [ppsdev.ucdavis.edu, oracle_database]
    [isoddev.ucdavis.edu, oracle_database]
    [gsdev8.ucdavis.edu, oracle_database]
    [isodtest.ucdavis.edu, oracle_database]
    [gstest.ucdavis.edu, oracle_database]
    [maxdev.ucdavis.edu, oracle_database]
    [pbod.ucdavis.edu, oracle_database]
    [olad.ucdavis.edu, oracle_database]
    [ppstest.ucdavis.edu, oracle_database]
    [MAXTEST.ucdavis.edu, oracle_database]
    [stemdev.ucdavis.edu, oracle_database]
    [stemtest.ucdavis.edu, oracle_database]
    [LISTENER_lepisma.ucdavis.edu, oracle_listener]
    [+ASM2_lepisma.ucdavis.edu, osm_instance]
    [agent12c2_11_lepisma, oracle_home]
    Any suggestions are appreciated. Thank you.
    Bill Wagman

    Hi Bill,
    1. Go to Targets > All Targets > Cluster > select the cluster name, then select Target setup from the cluster menu > Monitoring Configuration.
    2. Fill in all the properties (for instance, the SCAN Name, SCAN Port, etc.) and select Update to save the configuration.
    3. Go back to the cluster target home page, select View All Properties, verify that the SCAN name, SCAN port are shown.
    4. Execute the command:   emctl control agent runCollection <cluster target name>:cluster crs_event
    For example: emctl control agent runCollection dreamq1-cluster:cluster crs_event12g
    5. Give the process a little time for the data to be uploaded to the repository before checking the status of the listeners.
    Regards,
    Rahul

  • Initial Faces scan skips lots and lots of photos

    I have over 5000 photos. My initial scan took about 30 minutes. I thought it was fast, now I realize it was TOO fast - lots and lots, I'd guess over 50%, of photos were skipped.
    When I look at the photos, some have boxes around the faces but most do not. It skipped even extremely clear, front view, unobstructed faces.
    I took the advice of others here and deleted the "faces" files within the iPhoto package and restarted. Again the scan was really fast but flawed - I saw the same result with lots of photos seemingly skipped.
    I verified by taking some photos that had NO face recognized (high quality - closeup, unobstructed front view of a child). I exported them, then re-imported into iPhoto. On importing, it did find all the faces.
    This proves to me that the initial scan is FLAWED and skipping photos. If it found a face on re-importing, it should have found a face initially.
    I see other people here are seeing the same behavior. Comforting to know that I'm not alone, but VERY frustrating. I don't want to take days and days to draw my own boxes around faces if there's a chance that Apple will release a fix for this.

    My initial scan failed (as in not one single face box inserted). I deleted the files and started it over, and it seemed to work okay. No, it didn't get every face, but it did quite a few.
    But then I imported a large number of new photos, thinking I should finally consolidate my numerous photo libraries on separate computers... and iPhoto didn't find faces in those either.
    It seems like if I import a small number of photos (<200 as an estimate) it does scan them, but any more than that and it screws up.

  • Serial number and hangling unit

    question is : the same number can be assigned into diffrent  HU at same time.
    our case is allocate Serial Number into the finished products through RF device which was managed by HU.
    1 operator will add the barcode on the finished product which from production line,  6 articles will be created into one pallet (HU)
    2 RF scan the barcode and create HU
    3 RF changed the HU so set up reltionship between Serial Number and HU
       just in this process, if there are 12 piece articles, it's also mean 12 serial numbers and 2 HU will be created.
       suppose 12 serial numbers are: 1a  2b  3c  4d  5e  6f 
                                                           7g  8h  9i  10j  11k  12L
       correct result are 1a  2b  3c  4d  5e  6f   ==>HU1
                                     7g  8h  9i  10j  11k  12L  ==>HU2
      but if scanner do it wrongly the result are permmited like below:
                                      1a  2b  3c  4d  5e  6f   ==>HU1
                                     7g  8h  9i  10j  11k  6f  ==>HU2
    so my question is why SAP allowed this happened. is there configration missed or this is standard?
    thanks in advance
    Leo.Mao china

    Hi,
    Handling units have one identification number that uniquely identifies the handling unit across processes. Using a handling unit in a cross-system logistics chain usually requires an identification number that is unique worldwide
    You therefore have the option of assigning a .Serial Shipping Container Code. (SSCC) number to each handling unit.
    Have you done any setting to have serial numbers  1a 2b 3c 4d 5e 6f ==>HU1
                                                                       7g 8h 9i 10j 11k 12L ==>HU2
    If no, system is taking the serial numbers under HU1 as given by the user. I hiope this will help you. Thanking you.

  • Not able to convert string attribute to number and date please help me out

    not able to convert string attribute to number and date attribute. While using string to date conversion it shows result as failure.As I am reading from a text file. please help me out

    Hi,
    You need to provide an example value that's failing and the date formats in the reference data you're using. It's more than likely you don't have the correct format in your ref data.
    regards,
    Nick

  • Problem with store ResultSet and show result in table

    Hi, I'm kind of new in ADF, I need to store ResultSet and show result in table-component. I have two problems:
    1) I get my ResultSet by calling callStoredProcedure(...) and this returns actually ref_cursor as ResultSet.
    When I try to println() contains of this result set in this method - it works OK (commented part),
    but when I want to println() somewhere else (eg. in retrieveRefCursor() method) it doesn't work.
    The problem is that the scrollability of the ResultSet is lost - it becomes a TYPE_FORWARD_ONLY ResultSet.
    Is there any way to store data from ref_cursor for a long time?
    2) My second problem is "store any result set and show this data in table". I have tried use method storeNewResultSet() but
    without result (table contains only "No rows yet" and everything seems to be OK - no exception, no warning, no error...).
    I have tried to call this method with ResultSet from select on dbs (without resultSet as ref_cursor ) - no result with createRowFromResultSet(),
    storeNewResultSet(), setUserDataForCollection()...
    I've tried a lot of ways to do this, but it doesn't work. I really don't know how to make it so it can work.
    Thanks for your help.
    ADF BC, JDev 11.1.1.0
    This is my code from ViewObjectImpl
    package tp.model ;
    import com.sun.jmx.mbeanserver.MetaData ;
    import java.sql.CallableStatement ;
    import java.sql.Connection ;
    import java.sql.PreparedStatement ;
    import java.sql.ResultSet ;
    import java.sql.ResultSetMetaData ;
    import java.sql.SQLException ;
    import java.sql.Statement ;
    import java.sql.Types ;
    import oracle.jbo.JboException ;
    import oracle.jbo.server.SQLBuilder ;
    import oracle.jbo.server.ViewObjectImpl ;
    import oracle.jbo.server.ViewRowImpl ;
    import oracle.jbo.server.ViewRowSetImpl ;
    import oracle.jdbc.OracleCallableStatement ;
    import oracle.jdbc.OracleConnection ;
    import oracle.jdbc.OracleTypes ;
    public class Profiles1ViewImpl extends ViewObjectImpl {
        private static final String SQL_STM = "begin Pkg_profile.get_profile_list(?,?,?,?);end;" ;
        public Profiles1ViewImpl () {
        /* 0. */
        protected void create () {
            getViewDef ().setQuery ( null ) ;
            getViewDef ().setSelectClause ( null ) ;
            setQuery ( null ) ;
        public Connection getCurrentConnection () throws SQLException {
            // Note that we never execute this statement, so no commit really happens
            Connection conn = null ;
            PreparedStatement st = getDBTransaction ().createPreparedStatement ( "commit" , 1 ) ;
            conn = st.getConnection () ;
            st.close () ;
            return conn ;
        /* 1. */
        protected void executeQueryForCollection ( Object qc , Object[] params , int numUserParams ) {
            storeNewResultSet ( qc , retrieveRefCursor ( qc , params ) ) ;
            // callStoredProcedure ( qc , SQL_STM ) ;
            super.executeQueryForCollection ( qc , params , numUserParams ) ;
        /* 2. */
        private ResultSet retrieveRefCursor ( Object qc , Object[] params ) {
            ResultSet rs = null ;
            rs = callStoredProcedure ( qc , SQL_STM ) ;
            return rs ;
        /* 3. */
        public ResultSet callStoredProcedure ( Object qc , String stmt ) {
            CallableStatement st = null ;
            ResultSet refCurResultSet = null ;
            try {
                st = getDBTransaction ().createCallableStatement ( stmt , 0 ) ; // call 
                st.setObject ( 1 , 571 ) ; //set id of my record to 571
                st.registerOutParameter ( 2 , OracleTypes.CURSOR ) ; // my ref_cursor
                st.registerOutParameter ( 3 , Types.NUMERIC ) ;
                st.registerOutParameter ( 4 , Types.VARCHAR ) ;
                st.execute () ; //executeUpdate
                System.out.println ( "Numeric " + st.getObject ( 3 ) ) ;
                System.out.println ( "Varchar " + st.getObject ( 4 ) ) ;
                refCurResultSet = ( ResultSet ) st.getObject ( 2 ) ; //set Cursoru to ResultSet
                //   setUserDataForCollection(qc, refCurResultSet); //don't work
                //   createRowFromResultSet ( qc , refCurResultSet ) ; //don't work
                /* this works but only one-time call - so my resultSet(cursor) really have a data
                while ( refCurResultSet.next () ) {
                    String nameProfile = refCurResultSet.getString ( 2 ) ;
                    System.out.println ( "Name profile: " + nameProfile ) ;
                return refCurResultSet ;
            } catch ( SQLException e ) {
                System.out.println ( "sql ex " + e ) ;
                throw new JboException ( e ) ;
            } finally {
                if ( st != null ) {
                    try {
                        st.close () ; // 7. Close the statement
                    } catch ( SQLException e ) {
                        System.out.println ( "sql exx2 " + e ) ;
        /* 4. Store a new result set in the query-collection-private user-data context */
        private void storeNewResultSet ( Object qc , ResultSet rs ) {
            ResultSet existingRs = getResultSet ( qc ) ;
            // If this query collection is getting reused, close out any previous rowset
            if ( existingRs != null ) {
                try {
                   existingRs.close () ;
                } catch ( SQLException s ) {
                    System.out.println ( "sql err " + s ) ;
            setUserDataForCollection ( qc , rs ) ; //should store my result set
            hasNextForCollection ( qc ) ; // Prime the pump with the first row.
        /*  5. Retrieve the result set wrapper from the query-collection user-data      */
        private ResultSet getResultSet ( Object qc ) {
            return ( ResultSet ) getUserDataForCollection ( qc ) ;
        // createRowFromResultSet - overridden for custom java data source support - also doesn't work
       protected ViewRowImpl createRowFromResultSet ( Object qc , ResultSet resultSet ) {
            ViewRowImpl value = super.createRowFromResultSet ( qc , resultSet ) ;
            return value ;
    }

    Hi I have the same problem like you ...
    My SQL Definition:
    CREATE OR REPLACE TYPE RMSPRD.NB_TAB_STOREDATA is table of NB_STOREDATA_REC
    CREATE OR REPLACE TYPE RMSPRD.NB_STOREDATA_REC AS OBJECT (
       v_title            VARCHAR2(100),
       v_store            VARCHAR2(50),
       v_sales            NUMBER(20,4),
       v_cost             NUMBER(20,4),
       v_units            NUMBER(12,4),
       v_margin           NUMBER(6,2),
       v_ly_sales         NUMBER(20,4),
       v_ly_cost          NUMBER(20,4),
       v_ly_units         NUMBER(12,4),
       v_ly_margin        NUMBER(6,2),
       v_sales_variance   NUMBER(6,2)
    CREATE OR REPLACE PACKAGE RMSPRD.NB_SALES_DATA
    AS
    v_sales_format_tab   nb_tab_storedata;
    FUNCTION sales_data_by_format_gen (
          key_value         IN       VARCHAR2,
          l_to_date         IN       DATE DEFAULT SYSDATE-1,
          l_from_date       IN       DATE DEFAULT TRUNC (SYSDATE, 'YYYY')
          RETURN nb_tab_storedata;
    I have a PLSQL function .. that will return table ..
    when i use this in sql developer it is working fine....
    select * from table (NB_SALES_DATA.sales_data_by_format_gen('TSC',
                                        '05-Aug-2012',
                                        '01-Aug-2012') )
    it returning table format record.
    I am not able to call from VO object. ...
    Hope you can help me .. please tell me step by step process...
    protected Object callStoredFunction(int sqlReturnType, String stmt,
    Object[] bindVars) {
    System.out.println("--> 1");
    CallableStatement st = null;
    try {
    st = getDBTransaction().createCallableStatement("begin ? := " +"NB_SALES_DATA.sales_data_by_format_gen('TSC','05-Aug-2012','01-Aug-2012') ; end;", 0);
    System.out.println("--> 2");
    st.executeUpdate();
    System.out.println("--> 3");
    return st.getObject(1);
    catch (SQLException e) {
    e.printStackTrace();
    throw new JboException(e);

  • My iMessage is stuck on the wrong phone number and I keep getting coded text messages from SMS Info.

    I recently switched the sim card in my iPhone when I moved from one country to another. When I put my local sim card in iMessage would not activate (just staying on 'waiting for activation' forever). This has not been a problem before. When I went to send/receive I saw the phone number there is still on the old one from the country I left. This is not the case in phone settings when I look for 'my phone number' or in facetime, which recognise the new number.
    Plus I keep getting text messages from 'SMS Info'. They are just code, except that in there my new phone number is included among the code. The only other discernible characters are the letters 'REG-RESP?'. Perhaps this is something to do with an error in registering my new number.
    I have tried-
    1. Turning it off and on again.
    2. Turning iMessage off and on again. This results in the usual 'it may cost you to reactivate with an SMS' popup on my phone screen, then a popup saying there has been a mistake, then one of these coded SMS messages.
    3. Doing the above in combination with logging in and out of my apple id (as suggested on another forum post here)
    4. Removing the new sim card and replacing the old one. Then turning off iMessage, replacing the new sim card and turning iMessage back on (of course powering the phone down and up)
    None of these remedies have worked. The iMessage problem is affecting all sorts of my messages. Windows keep popping up saying that I may have to pay for an SMS to activate iMessage, except that it doesn't activate. The SMS messages from 'SMS Info' keep coming and I can't seem to get any of it to stop an just work normally.
    I have looked in these forums already and can't see the same problem elsewhere. If someone could figure this out I would be most grateful.

    Hi,
    When a Mac is "registered" for iMessages account with an Apple ID the Serial Number of the Mac is used to create an Auth Token as it is called for the Messages app that allows that Mac to work.
    I would guess a similar process of linking the Number of the iPhone to a Hardware fact about the device is also in place.
    I would contact Apple Support and check with them.  (you might need to speak to a Level 2 person as Level 1 people are script led and try to fit everything into Software or Hardware categories where as sorting and Apple ID (which the Number is in this case) is normally Free).
    I did find this iOS: Troubleshooting Messages - Apple Support
    It starts off about sorting SMS that is not working.
    This one has a bit on Unlinking an iPhone Number (with or without the iPhone) iOS and OS X: Link your phone number and Apple ID for use with FaceTime and iMessage - Apple Support
    7:55 pm      Tuesday; January 6, 2015
    ​  iMac 2.5Ghz i5 2011 (Mavericks 10.9)
     G4/1GhzDual MDD (Leopard 10.5.8)
     MacBookPro 2Gb (Snow Leopard 10.6.8)
     Mac OS X (10.6.8),
     Couple of iPhones and an iPad

  • Scanning with iMac and C310a photosmart premium all in one

    I am trying to Scan a document and It scans just fine but fails when I try to save, print or email the document.  It works fine if I only scan one page, I can save, print or email the file.  However when I try to do this with a document of more than one page, when I go to save/print/email I get the following error box:   "ERROR:  An error occurred when saving the file because it couldn to be written to.  check the properties for the file to make sure it is not read only."  If I hit OK at this point my software hangs up and the only solution is to "Force Quit" the software to get out of the loop.
    Yes, I have checked all files and none are read only, and it works fine with single page scans.  
    I am using the HP Scan utility.  When I try to scan using the controls on my printer it works fine but I can only scan single page documents.
    I am running Imac with version 10.9.4 software.  I have run all software update scans and no updates show.  I have tried rebooting the mac and the printer, no change?
    Any help is appreciated.
    James

    Hello James, and welcome to the HP Forums, I hope you enjoy your experience!
    I see you are experiencing print and scan issues.  I would like to try and help. 
    I would suggest deleting the printer from your print system, using this document: Uninstalling the Printer Software.
    Once you have deleted it, I would suggest verifying and repairing the disk permissions: About Disk Utility's Repair Disk Permissions feature.
    I would also suggest running your Apple updates:  OS X: Updating OS X and Mac App Store apps
    After the updates, I would recommend readding the driver to your system, using this document on OS X v10.9 Mavericks: Installing and Using the Printer on a Mac.
    Good luck and please let me know the results of your troubleshooting steps. Thank you for posting on the HP Forums!
    Please click “Accept as Solution " if you feel my post solved your issue, it will help others find the solution.
    Click the “Kudos, Thumbs Up" on the right to say “Thanks" for helping!
    Jamieson
    I work on behalf of HP
    "Remember, I'm pulling for you, we're all in this together!" - Red Green.

Maybe you are looking for