10g Signal Handlers and Dynamic Binding Problems on Mac OS X

I have the following env vars set up, and it seems the client libs show a deadl\
ock behavior post installation. SqlPlus exhibits a similar problem with 10g cli\
ent libs on the Mac, since it simply hangs for 20 secs before returning the pro\
mpt. I have G4 10.3.4 Mac, and 3.3 (1640) gcc, and still haunted by this probl\
em...
ORACLE_HOME=/Users/Oracle/10g/orahome
ORACLE=ORACLE_HOME/bin
ORACLE_BASE=/Users/Oracle/10g
DYLD_LIBRARY_PATH=/Users/Oracle/10g/orahome/lib
a) ktrace sqlplus user/pass@db
b) kdump -R | grep sigaction gives:
885 sqlplus 5.877734 CALL sigaction(0x2,0xbffff500,0xbffff570)
885 sqlplus 0.001252 RET sigaction 0
885 sqlplus 0.002032 CALL sigaction(0xd,0xbfff90f0,0xbfff9160)
885 sqlplus 0.001831 RET sigaction 0
885 sqlplus 0.001293 CALL sigaction(0x12,0xbfffb6e0,0xbfffb750)
885 sqlplus 0.001234 RET sigaction 0
885 sqlplus 0.001551 CALL sigaction(0x12,0xbfffbda0,0xbfffbe10)
885 sqlplus 0.001401 RET sigaction 0
885 sqlplus 0.001331 CALL sigaction(0x2,0xbfffd090,0xbfffd100)
885 sqlplus 0.001333 RET sigaction 0
This shows a 5.9 sec delay for the first sigaction, and a full response is received some long 20 secs later on the prompt.
Some feedback from engineering regarding this issue since the 9i release has been:
"This is a known problem with signal handlers and the lazy binding we have on Mac OS X. A small change to how Oracle library's signal
handler is installed using _signal_nobind(3) and
_dyld_lookup_and_bind_fully(3) could help to solve this problem.
The problem that we are trying to avoid is a possible dead lock from
code that could be called in a signal handler when the thread that
gets the signal is in the middle of lazy binding a symbol. So when a
signal handlers installed the default action is to cause it to be
bound fully. This is made very expensive by the mismatch of the
interfaces to signal(3) and segvec(2) like routines which are passed
an address and the dynamic linker that wants a global symbol name. So the end result is to call the routine _dyld_bind_fully_image_containing_address(3) with the address of the signal handler to be bound. Which binds everything in the image (in this case the Oracle shared library).
We have had problems like this before. For example: [This is what is
done in usleep(3)]
usleep()
/* code removed for this example */
setvec(vec, sleepx);
#ifdef __DYNAMIC__
_dyld_lookup_and_bind_fully("_usleep", NULL, NULL);
(void) _sigvec_nobind(SIGALRM, &vec, &ovec);
#else
(void) sigvec(SIGALRM, &vec, &ovec);
#endif
static void sleepx(int unused)
ringring = 1;
The use of _sigvec_nobind(2) (or _signal_nobind(3) ) and the use of
_dyld_lookup_and_bind_fully(3) will cause just the needed symbols used by the signal handler. "
It seems this issue hasn't been resolved in the most recent 10g client release.Can anyone shed some light one this issue?
For better demonstration, here is a series of steps we took here:
sigaction.c - C file produced by "proc sigaction.pc"
sigaction.pc - ProC source file
gcc_sig* - Shell script to compile sigaction.c
ktrace.sigtest - raw ktrace output from running sigtest
ktrace.sqlplus - raw ktrace output from running sqlplus
kdump.sqlplus - output of kdump -R on ktrace.sqlplus
kdump.sigtest - output of kdump -R on ktrace.sigtest
sigaction.lis - auxiliary file produced by proc
1. sigaction.pc:
#include <stdio.h>
#include <stdlib.h>
#include "/Users/oracle/10g/orahome/precomp/public/sqlca.h"
int main(int argc, char **argv) {
char user[30], passwd[30], db[40];
char con_str[100], date[10], *icp;
strcpy(user, "XXXXXXXX");
strcpy(passwd, "XXXXXXXX");
strcpy(db, "db_name");
sprintf(con_str,"%s/%s@%s",user,passwd,db);
EXEC SQL CONNECT :con_str;
EXEC SQL SELECT SYSDATE INTO :date FROM DUAL;
printf("SYSTEM DATE = %s\n",date);
EXEC SQL COMMIT RELEASE;
2. gcc_sig:
#!/bin/sh
CFLAGS="-I$ORACLE_HOME/precomp/public -I/usr/include"
CFLAGS="$CFLAGS -I$ORACLE_HOME/lib -L$ORACLE_HOME/lib"
ORALIBS="-L$ORACLE_HOME/lib -lclntsh $ORACLE_HOME/lib/nautab.o $ORACLE_HOME/lib/naeet.o"
CC="gcc -g"
PROG=$1
OUTPUT=$2
$CC $CFLAGS $PROG -o $OUTPUT $ORALIBS
3. Generate the rest of the output files for your viewing of the results based on the commands provided above.
Thanks!

It's a delay, not a deadlock, that originatesfrom the way Oracle
libraries handle dymaic bindings.to "dynamic" bindings. Maybe prebinding could help ?
export DYLD_PREBIND_DEBUG=1ronr@[email protected]:/Users/ronr
sqlplus "/ as sysdba"dyld: sqlplus: prebinding disabled because library: /Users/oracle/product/server/10.1/lib/libsqlplus.dylib got slid
dyld: in map_image() determined the system shared regions ARE used
dyld: 2 two-level prebound libraries used out of 5
Ronald
http://homepage.mac.com/ik_zelf/oracle/

Similar Messages

  • Dynamic binding problem

    I have a problem, i want to use a extend to arraylist to implement different validation to objects. So i added a method add(Person person), dynamic binding, but it has a incorrect behavior, i think
    import java.util.ArrayList;
    import java.util.Collection;
    public class Test {
         class MyList extends ArrayList {
              public boolean add(Object arg0) {
                   System.out.println("add norm");
                   return super.add(arg0);
              public boolean add(Person arg0) {
                   System.out.println("add person");
                   return super.add(arg0);
         class Person{
         public static void main(String[] args) {
              new Test().test();
         private void test() {
              Collection col1 = new MyList();
              col1.add(new Person());
              ArrayList col2 = new MyList();
              col2.add(new Person());
              MyList col3 = new MyList();
              col3.add(new Person());
    }My output=
    add norm
    add norm
    add person
    My wanted output
    add person
    add person
    add person
    Why?

    in case you don't understand why you're getting "addning norm"
    you are using polymorphism. You declared your objects to be of type Collection and ArrayList. This means you can only use methods of those type, eventhough the underlying object is a MyList instance. Now, Collections and ArrayList class only have the add(Object obj) method signature....so, when you say add(new Person()), it will only see add(Object obj)
    When you declared your object as MyList, then it see add(Person p), so it use the add(Person p) method.

  • Emsg/signal 11 and REP-3000 problems after tweaking a PDF/XML report

    Hello everyone,
    Just wanted to check if anyone has encountered similar issues?
    We have a custom rdf report installed by our Consultant/VAR, and is called / run from Oracle EBS using the Request Manager. This is an XML report that outputs a PDF file from a template. This report runs without problems.
    We made a very slight tweak to the report's query, but now when we run the report, it reports an error, with the following message in the log file:
    EMSG:was terminated by signal 11
    REP3000 internal error starting oracle toolkit
    When we revert back to the earlier report, it runs without problems, but this new report reports this.
    I am pretty sure the changes made to the report weren't the cause of this issue because the tweaks are very minor AND I remember our Consultant/VAR encountering this issue when they first developed the report. However, they kind of forgot how they solved the issue before.
    Any ideas how to fix this?
    Thanks!
    Derrick

    This is just to close off a post I submitted years ago...in case it might help someone else in the future ...
    Everyone keeps saying to change the display configuration. And actually, they were correct!! We just had to change the s_display.
    In our case, we just set the s_display to :
    :0.0instead of
    hostname:0.0Then, we ran autoconfig for the Apps Tier.
    For some reason or another, this worked.
    This was on Oracle Linux 4, on EBS 11i.

  • Airport signal blinking and others WIFI problems

    I have a serious problem with my MacBook Pro. The WIFI signal is pretty weak compared to my old iBook or PowerMac G5, and sometimes, the Airport signal is lost and the Airport signal goes from 5 bars to 0, like a blinking.
    I have this message in the Console " Feb 2 21:57:27 ordinateur-de- /System/Library/PrivateFrameworks/Apple80211.framework/Resources/airport: Error: WirelessAssociate2() = 88001006 for network Airport. The operation timed out. "
    I have no problem with the iBook or the PM G5 on the same WIFI network.
    What can I do ?

    if you are having a reception issue, you may be having some sort of environmental interference.
    http://docs.info.apple.com/article.html?artnum=58543
    also, you can organize your network ports to have airport as your primary. this may help
    open system preferences > network
    - change the Show: to network port configuration
    - drag airport to the top of the list
    - click apply now , in bottom right
    - restart
    hope this helps

  • Pagination and dynamic objects problem

    I'm designing the form below in LC. Sections of the form are set to hidden depending on checkboxes in the form. What I would like to happen is an object to appear in the center of every page footer that:
    has a field that needs approval (any field)
    doesn't already have an approval signature on it
    Does this need to be done with multiple master pages since the footer is part of the master?
    The form should be obvious when you open it. Essentially, there needs to be approval on all form pages with data on them. The exceptions being a page that already has the approver's signature on it or a page with no form data on it.
    Thanks,
    Kevin

    Is the following pseudo-code possible? It would likely go into the prePrint method for the form.
    for (int i = 0; i < numPages; i++) {
        if (page[i] contains signatureSubform || page[i] contains-only textSubform) {
            page[i].intialsSubform.presence = "visible";
        } else {
            page[i].intialsSubform.presence = "visible";
    This form also presents the problem more clearly. It has a dynamic table instead of checkboxes.

  • ADFPhaseListener prepareRender and component binding problem

    I´m Using ADF Faces and using the ADFPhaseListener. My BackingBean extends from the PageController class
    and so can use prepareModel(LifecycleContext context) or prepareRender(LifecycleContext context). This works fine so far. The
    event handler methods are called as expected (in my example prepareRender). But I have one question.
    I´m using Component binding in my JSF-Page:
    <af:inputText binding="#{backing_untitled1.inputText1}" id="inputText1">
    Code snippet from my ControllerClass
    public class Untitled1 extends PageController{
    CoreInputText inputText1;
    public void setInputText1(CoreInputText inputText1) {   
    System.out.println("setInputText1");
    this.inputText1 = inputText1;
    public void prepareRender(LifecycleContext context) {
    super.prepareRender(context);
    System.out.println("inside prepareRender");
    I´ve written a second PhaseListener that just print´s out the JSF lifecycle phase numbers for better tracing.
    The first time I call my JSF-Page the following output is generated:
    07/01/03 08:32:38 Before Phase: 1 Source:com.sun.faces.lifecycle.LifecycleImpl@163
    07/01/03 08:32:38 After Phase: 1
    07/01/03 08:32:38 inside prepareRender
    07/01/03 08:32:38 Before Phase: 6 Source:com.sun.faces.lifecycle.LifecycleImpl@163
    07/01/03 08:32:39 setInputText1
    07/01/03 08:32:40 After Phase: 6
    I can see that the prepareRender is called before phase 6. The component binding is done in phase 6. What I would like to
    do is access the component binding in my prepareRender method. But this is not possible as it is null before phase 6.
    Is there a way to create event handling code after the component binding has taken place?
    When I do a postback (second call to the same JSF page) this thing changes
    07/01/03 08:37:23 Before Phase: 1 Source:com.sun.faces.lifecycle.LifecycleImpl@163
    07/01/03 08:37:24 setInputText1
    07/01/03 08:37:24 After Phase: 1
    07/01/03 08:37:24 Before Phase: 2 Source:com.sun.faces.lifecycle.LifecycleImpl@163
    07/01/03 08:37:24 After Phase: 2
    07/01/03 08:37:24 Before Phase: 3 Source:com.sun.faces.lifecycle.LifecycleImpl@163
    07/01/03 08:37:24 After Phase: 3
    07/01/03 08:37:24 Before Phase: 4 Source:com.sun.faces.lifecycle.LifecycleImpl@163
    07/01/03 08:37:24 After Phase: 4
    07/01/03 08:37:24 Before Phase: 5 Source:com.sun.faces.lifecycle.LifecycleImpl@163
    07/01/03 08:37:24 After Phase: 5
    07/01/03 08:37:24 inside prepareRender
    07/01/03 08:37:24 Before Phase: 6 Source:com.sun.faces.lifecycle.LifecycleImpl@163
    07/01/03 08:37:24 After Phase: 6
    Here in my prepareRender method I could access the component binding as it has been initialized in phase 1.
    Thanks in advance
    Rainer

    hi, you can use this way to initially a value:
    public void setInputText1(CoreInputText inputText1) {
    this.inputText1 = inputText1;
    if( !AdfFacesContext.getCurrentInstance().isPostback() ){
    this.inputText1.setValue("somevalue");
    in the RenderModel phase is not possible set value to a component because this one is null, as you have said.. by this way you can do this too:
    public void setInputText1(CoreInputText inputText1) {
    this.inputText1 = inputText1;
    if( !AdfFacesContext.getCurrentInstance().isPostback() ){
    DCIteratorBinding ib = (DCIteratorBinding)Utilidades.resolveExpression("#{bindings.BanksView1Iterator}");
    RowIterator iter = ib.getRowSetIterator();
    Row row = iter.first();
    if (row != null){
    this.inputText1.setValue(row.getAttribute(BanksViewRowImpl.COD));}
    }

  • ODBC and DB2 bind problems

    <p>I am working my way through  the EIS 7.1.24 installationguide [AIX] and have hit a road block with ODBC. </p><p> </p><p>I have set up the odbc.ini file for DB2 and have confirmed thati can conect to the DB2 database through otherapplications.</p><p> </p><p>RECAP</p><p>When I run the follwing command:</p><p><span style=" font-family: CourierNew;">    /essapp/hyperion/common/ODBC/Merant/4.2/lib> ./bind19 db2data</span></p><p> </p><p>I get this reposnse: <span style=" font-family: CourierNew;">    Specified driver could not beloaded./essapp/hyperion/common/ODBC/Merant/4.2/lib ></span></p><p> </p><p>To make sure the driver is good [per Merant site],  I thenran:</p><p><span style=" font-family: CourierNew;">    /essapp/hyperion/common/ODBC/Merant/4.2/bin> ./ivtestlib ARdb219.so</span></p><p> </p><p>Which return this:</p><p><span style=" font-family: CourierNew;">    Load of ARdb219.so successful,qehandle is 0x200C89DC</span></p><p> </p><p><span style=" font-family: Arial;">Here's a view of the odbc.inifile {i had to hide some connection infor per security)</span></p><p> </p><p><span style=" font-family: Courier New;">[ODBC Data Sources]db2data=DB2 Source Data on AIX</span></p><p> </p><p><span style=" font-family: Courier New;">[db2data]Driver=/essapp/hyperion/common/ODBC/Merant/4.2/lib/ARdb219.soIpAddress=IPADDRESS</span></p><p><span style=" font-family: CourierNew;">Database=DATABASE</span></p><p><span style=" font-family: Courier New;">TcpPort=PORT</span></p><p><span style=" font-family: Courier New;">LogonID=USERNAME</span></p><p><span style=" font-family: CourierNew;">Password=PASSWORD</span></p><p><span style=" font-family: Courier New;">Package=</span></p><p><span style=" font-family: CourierNew;">Action=REPLACE</span></p><p><span style=" font-family: CourierNew;">QueryBlockSize=8</span></p><p><span style=" font-family: CourierNew;">CharSubTypeType=SYSTEM_DEFAULT</span></p><p><span style=" font-family: CourierNew;">ConversationType=SINGLE_BYTE</span></p><p><span style=" font-family: CourierNew;">CloseConversation=DEALLOC</span></p><p><span style=" font-family: CourierNew;">UserBufferSize=32</span></p><p><span style=" font-family: CourierNew;">MaximumClients=35</span></p><p><span style=" font-family: CourierNew;">GrantExecute=1</span></p><p><span style=" font-family: CourierNew;">GrantAuthid=PUBLIC</span></p><p><span style=" font-family: Courier New;">OEMANSI=1</span></p><p><span style=" font-family: CourierNew;">DecimalDelimiter=PERIOD</span></p><p><span style=" font-family: CourierNew;">DecimalPrecision=15</span></p><p><span style=" font-family: CourierNew;">StringDelimiter=SINGLE_QUOTE</span></p><p><span style=" font-family: CourierNew;">IsolationLevel=CURSOR_STABILITY</span></p><p><span style=" font-family: CourierNew;">ResourceRelease=DEALLOCATION</span></p><p><span style=" font-family: CourierNew;">DynamicSections=32</span></p><p><span style=" font-family: Courier New;">Trace=0</span></p><p><span style=" font-family: Courier New;">WithHold=0</span></p><p> </p><p>Any help would be much appreciated</p>

    Good Day,Does anyone have any steps for Data Integration from external systems to Hyperion System 9.ThanksAzmat Bhatti

  • Photosmart C3180 and C4680 Scanning Problem with Mac OS X 10.9.5

    I upgraded to OS X 10.9.5 and now can't scan using either Photosmart C3180 or C4680.  I've repaired permissions and uninstalled and reinstalled printers in Printers and Scanners preferences.  Scan no longer appears as an option in Printers and Scanners preferences, just print.  Using Preview, "Import from scanner" in File menu is grayed out.  Printing works fine on both printers.  I can't find any updates to printer drivers on Apple Software Update.
    This question was solved.
    View Solution.

    Hi,
    Reboot your Mac, then click the Apple icon and select Software Update.
    Click the top Store Menu and select Reload Page, then install any listed Apple or HP Update if a such available.
    If the sa,e persists, manually download and install the following package, then check for any difference:
    http://support.apple.com/kb/dl907
    Please let me know of any difference,
    Shlomi
    Say thanks by clicking the Kudos thumb up in the post.
    If my post resolve your problem please mark it as an Accepted Solution

  • Safari 5 don't print jpg images in Windows and prints with problems in Mac

    Hi All,
    When I try to print images in Safari (Windows) it will print blank page.
    This is sample source:
    <html lang="en-US">
    <body>
    <im g src="http://img185.imageshack.us/img185/4651/wefwefwe.jpg">
    </body>
    </html>
    This is ok in Mac.
    Also in Mac When I'm printing image in Landscape it print image in 2 pages.
    Image really fits in landscape mode and there is no need for second page.
    I thought that the problem is margins..., but changing them do smaller values doesn't help.
    Can someone help out?

    Hi, I also have the same problem that cannot print preview on .jpg image.
    When I try to change image to .png , it work.
    It's this safari5 bug?

  • 10.4.10 update and very strange problem with Mac Mini

    Dear All,
    I have just updated my Mac Mini Intel and I am having a strange problem.
    My Mac Mini has problems booting up. Sometimes I get through the login screen as normal but my wallpaper shows and there are no desktop icons, no dock, no top of screen finder menu bar. Some other times I get stuck in the progress bar of the booting up.
    I tried to run utilities from install disk and there were no problems detected.
    The VERY STRANGE thing is that several times now as I put my fingertip onto the power button laying it on the button but not pressing it yet (because I would like to shut down the system), the system kicks in and becomes unfrozen!!!
    Someone in the 123macmini.com forum says that this problem is related to the airport receiver which is near the power button.
    What do you think about it???
    MacBook and MacMini   Mac OS X (10.4.10)  

    ok, I have found a kind of fix for the problem, although may run a hardware test to check something!.
    I unplugged all USB and Firewire devices, I turned off Bluetooth and Airport, reinstalled the 10.4.10 combo update, when it restarted the starting mac osx screen took barely a second or 2 to load (my comment above is becuase from when I first got it on Sunday I noticed it was slow to boot up, also noticed that the screen resoulution I have set does not kick in until I log on, although this may be becuase this mac mini is an intel one). The computer booted up very quickly and I tuend on bluetooth and airport with no issues and plugged all the usb and fireware devices back in. I again turned the airport off and restarted and again it booted up very quickly logged on and swithced the airport back on. I decided to reboot with the sirport on and it got stuck at the end of the os x starting up screen, I waited a few mins switched it off and on again and it booted up fine although slower. I dont mind turning the airport off when I power down as the mac usually stays on anyway. I assume Apple will release a fix for this as a lot of people seem to have the problem so think I will stay put with this for the time being. It was taking a several goes to get to the login screen before but usually got there every few boots.

  • Buffalo LinkStation Live and NasNavigator 2 problems with Mac

    I am using a Buffalo LinkStation Live (LS-CH1.0TL) with my MacBook. With the Firewell turned off on my Mac it works really well. Unfortunately, with the Firewall on, a perpetual dialogue box appears asking to give permission to allow incoming connections from NasNavigator 2. Whether you click Allow or Deny, the message appears again after about 10 seconds. This process continues indefinitely. It works fine with Windows 7 (either run via Mac or on my previous PC). I have updated all software/firmware and reformatted and restored factory settings on the LinkStation.
    Buffalo are stating that this is an Apple issue so can anyone help or is this going to be technical-support-tennis where each are blaming the other?! Your help would be greatly appreciated!
    Thanks in advance for your help!

    Somewhere at either Macworld or here I learned that DVDSP 2, DVDSP 3 and now DVDSP 4 "internally" are major re-writes.
    Support for HD among a few other items along with QT 7 which comes with Tiger means sincerely that one set of applications/OS is not going to be stable.
    Personally I think of all the issues possible its DVDSP vs QT.
    Unless you move to DVDSP v4 the alternative is to wipe the disk and go back to Jaguar (10.2) or perhaps Panther but avoid upgrading QT beyond 6. I advocate wiping the disk because I'n not sure an archive and install to down shift to an earlier version of the OS is possible. If it is I'd still worry about mis-matched files in all sorts of locations.

  • Dynamic SQL and Bulk Bind... Interesting Problem !!!

    Hi Forum !!
    I've got a very interesting problem involving Dynamic SQL and Bulk Bind. I really Hope you guys have some suggestions for me...
    Table A contains a column named TX_FORMULA. There are many strings holding expressions like '.3 * 2 + 1.5' or '(3.4 + 2) / .3', all well formed numeric formulas. I want to calculate each formula, finding the number obtained as a result of each calculation.
    I wrote something like this:
    DECLARE
    TYPE T_FormulasNum IS TABLE OF A.TX_FORMULA%TYPE
    INDEX BY BINARY_INTEGER;
    TYPE T_MontoIndicador IS TABLE OF A.MT_NUMBER%TYPE
    INDEX BY BINARY_INTEGER;
    V_FormulasNum T_FormulasNum;
    V_MontoIndicador T_MontoIndicador;
    BEGIN
    SELECT DISTINCT CD_INDICADOR,
    TX_FORMULA_NUMERICA
    BULK COLLECT INTO V_CodIndicador, V_FormulasNum
    FROM A;
    FORALL i IN V_FormulasNum.FIRST..V_FormulasNum.LAST
    EXECUTE IMMEDIATE
    'BEGIN
    :1 := TO_NUMBER(:2);
    END;'
    USING V_FormulasNum(i) RETURNING INTO V_MontoIndicador;
    END;
    But I'm getting the following messages:
    ORA-06550: line 22, column 43:
    PLS-00597: expression 'V_MONTOINDICADOR' in the INTO list is of wrong type
    ORA-06550: line 18, column 5:
    PL/SQL: Statement ignored
    ORA-06550: line 18, column 5:
    PLS-00435: DML statement without BULK In-BIND cannot be used inside FORALL
    Any Idea to solve this problem ?
    Thanks in Advance !!

    Hallo,
    many many errors...
    1. You can use FORALL only in DML operators, in your case you must use simple FOR LOOP.
    2. You can use bind variables only in DML- Statements. In other statements you have to use literals (hard parsing).
    3. RETURNING INTO - Clause in appropriate , use instead of OUT variable.
    4. Remark: FOR I IN FIRST..LAST is not fully correct: if you haven't results, you get EXCEPTION NO_DATA_FOUND. Use Instead of 1..tab.count
    This code works.
    DECLARE
    TYPE T_FormulasNum IS TABLE OF VARCHAR2(255)
    INDEX BY BINARY_INTEGER;
    TYPE T_MontoIndicador IS TABLE OF NUMBER
    INDEX BY BINARY_INTEGER;
    V_FormulasNum T_FormulasNum;
    V_MontoIndicador T_MontoIndicador;
    BEGIN
    SELECT DISTINCT CD_INDICATOR,
    TX_FORMULA_NUMERICA
    BULK COLLECT INTO V_MontoIndicador, V_FormulasNum
    FROM A;
    FOR i IN 1..V_FormulasNum.count
    LOOP
    EXECUTE IMMEDIATE
    'BEGIN
    :v_motto := TO_NUMBER('||v_formulasnum(i)||');
    END;'
    USING OUT V_MontoIndicador(i);
    dbms_output.put_line(v_montoindicador(i));
    END LOOP;
    END;You have to read more about bulk- binding and dynamic sql.
    HTH
    Regards
    Dmytro
    Test table
    a
    (cd_indicator number,
    tx_formula_numerica VARCHAR2(255))
    CD_INDICATOR TX_FORMULA_NUMERICA
    2 (5+5)*2
    1 2*3*4
    Message was edited by:
    Dmytro Dekhtyaryuk

  • Polymorphism , Dynamic Binding, Widening and I'm totally confused

    class Fruit
         private String name;
         public String getName()
              return this.name;
    class Apple extends Fruit
         private String typeOfApple;
         public void setTypeOfApple(String type)
              this.typeOfApple=type;
         public String getTypeOfApple()
              return this.typeOfApple;
    class Banana extends Fruit
         private String typeOfBanana;
         public void setTypeOfBanana(String type)
              this.typeOfBanana=type;
         public String getTypeOfBanana()
              return this.typeOfBanana;
    public class ExceptionTesting
         public static void main(String args[])
              Fruit obj=new Apple();
              obj.setTypeOfApple();  // ??? Why can't I do this ???
    }how can I achieve something like underneath by modifying above code ???
    Fruit whateverFruit=new Apple();
    whateverFruit.setTypeOfApple();
    whateverFruit=new Banana();
    whateverFruit.setTypeOfBanana();
    whateverFruit=new Orange();
    whateverFruit.setTypeOfOrange();
    ...

    Harry_lynn_17 wrote:
    I do apologize if it's become sound like stupid or something . I know somehow it's not very suitable to think in that way but I was just thinking of the object reference variable as a pointer becauseA reference is like a "filtered" pointer to an object: it will only show that part of the object that corresponds with the type of the reference. So after "Fruit whatever = new Banana();", the "whatever" reference only shows the "Fruit" part of the "Banana" object. This means you can only call methods that are defined in Fruit, not those defined in Banana.
    Dynamic binding means the JVM will decide at runtime which method implementation to invoke based on the class of the object. So, I thought
    Fruit whateverFruit=new Banana(); and then if i tried to invoke whateverFruit.yellowBanana(); then the compiler will try to find the method out and executed automatically.That's not what it means. It means when you have "Fruit whatever = new Banana()" and you call "whatever.getName()", it will call the getName() method from Banana, if Banana overrides the implementation of Fruit. You can still only use methods that are defined in Fruit through a reference of type Fruit. In this case, it doesn't seem that the behaviour of setTypeOfApple() is different from setTypeOfBanana(), so ejp's recommendation to just create a setType() method in Fruit is correct.
    Polymorphism means a variable of a superclass type to hold a reference to an object whose class is the superclass or any of its subclasses. So, I thought Fruit whateverFruit is somehow capable to hold the reference of its subclasses and can be used to reference of its subclasses. That's basically correct. However, the variable will only expose the superclass part of the subclass object.
    I got confused with all those stuff and kinda lost. There's one more thing. What's the point of doing something like this Fruit apple=new Apple() if I can't reference to an instance of apple object ?? I mean I could just simply write like this Fruit aFruit=new Fruit(). Sorry, if i've become sound like a fool but i'm really confused. Please help me out of this and thanks in advance.The point of having any superclass/subclass combo is that your problem domain demands that you make the distinction: sometimes you need to be able to treat an object as Fruit, sometimes you need to be specific and treat it like an Apple. For example, if you sell fruit and need to calculate the total price of a fruit basket, all you need to know is that each piece of Fruit has a getPrice(), you don't need to know that one piece is an Apple and another piece is a Banana. However, if a customer demands a kilogram of apples, you need to make sure you give him only Apples and not Banana's.List<Fruit> fruitBasket = new ArrayList<Fruit>();
    fruitBasket.add(new Apple("Granny Smith"));
    fruitBasket.add(new Banana("Chiquita"));
    fruitBasket.add(new Apple("Golden Delicious"));
    int priceOfBasket = 0;
    for(Fruit pieceOfFruit:fruitBasket) {
      priceOfBasket += pieceOfFruit.getPrice();
    Set<Apple> appleScale = new HashSet<Apple>();
    appleScale.add(new Apple("Granny Smith"));
    appleScale.add(new Apple("Golden Delicious"));
    appleScale.add(new Banana("Chiquita")); // ERROR

  • How to solve problem - " Safari cannot open page because it isn't connected to the internet" but the airport is ok. signal full and i have n IP address.

    How to solve problem - " Safari cannot open page because it isn't connected to the internet" but the airport is ok. signal full and i have n IP address. and i m using Macbook pro.
    OS snow leopard and above...

    Do you have this problem with all websites, or only some? If only some, which ones?

  • How to synchronize the signal sending and data acquiring process dynamically with one DAQ_Urgent

    Dear Sir,
    I am using one DAQ card to send a modulation signal (which is a signal summed by a low frequency saw tooth and high frequency sin signal) to the laser controller, and acquire voltage signal from another instrument  (It is in a same measurement system with the laser controller)?
    I would like these two process happening at the same time.
    In the attachment, there are two parts, one of them is signal generating program, the other one is data acquiring program, how to do like this: when I press"run", first the modulation will be sent to the laser controller immediately, and at the same time, the acquiring program starts as well...
    In addition, I think my program is not complete, could you please help me check if there are any other problems with it? 
    Thank you very much.. and appreciate your quick reply in advance.
    Best regards,
    Memorysun
    Attachments:
    Signals generation and lockin recording.vi ‏1227 KB

    Jamie S. wrote:
    Hi Memorysun,
    Thank you for your post and welcome to the forums.
    From your description what you want to achieve is:
     Write data to a Analog Output channel that is then recieved by the Laser
     Acquire (read) data from using an Analog Input channel (output from Laser/Instrument)
    This can be achieved using a single VI with 2 seperate DAQ tasks, one the "Continuously Writes" to the Laser and the other that "Continuously Reads" from the Laser/Instrument. Can I recommend the following examples that can be found in the NI Example Finder (Help>>Find Examples>>Hardware Input and Output>>DAQmx):
     "Cont Gen Voltage Wfm-Int Clk.vi" (for continuous writing)
     "Cont Acq&Graph Voltage-Int Clk.vi" (for continuous acquisition)
    The code from within both these VI's can be placed in a single VI therefore achieving the desired functionality.
    Many Thanks
    Jamie,
    They would be better served with an example that routes the AO hardware sample clock to the source of an externally clocked AI.
    Using the examples you posted will still leave them with the challenge of trying to alligh stimulus with response.
    Ben 
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

Maybe you are looking for

  • Video output dimension troubles in CS4

    This is my first project in PPCS4 and I'm having trouble getting an appropriate video output size.  The dimensions of the source clips are 640x480p, and originally only filled a small portion of the frame, with large empty margins around the outside.

  • GL Automatic Clearing

    Dear All I want to clear open items of a particular GL by Document Header Text. In customizing of automatic clearing I need to  insert criterion BKPF-BKTXT(Document Header Text). But system is giving following message. How can I clear the open items

  • Problem syncing Nokia 6301 with Outlook Express

    I'm using bluetooth. The connection is fine - everythink works EXCEPT when I try to sync contacts between outlook express and the phone, zero contacts are synced. There are no error messages. All other functions work -- able to back up and transfer p

  • Identification of old material number at plant level

    Dear All, We are implementing SAP for  two hospitals. In legacy system each hospital as its own material master and material number. Now in SAP each hospital we are treating as a plant. These two plants are assigned to one company code. So it means t

  • Cancel/reverse service entry sheet

    Hi Experts, Please let me know how to cancel/reverse one accepted service entry document. After revoking acceptance also system is asking for reason for movement. But nowhere I found to enter that against the movement type 102, through the transactio