The same code behaving different in two files.

The same code behaving different in two files.
in pro*c file it is returning rows
in sql file it is not returning any rows.
please suggest me.
regards,
prasad.

please find the code.
sql_stmt := 'SELECT rNum, dpcCode, sID, hDate, fBlock, '||
'lBlock, recQty, fID, fName, ' ||
'tSeqNo, sType, tDate, fStatCode, pDate, recCount, r ' ||
'FROM (SELECT rownum rNum, DPC_CODE_ORIG dpcCode, ' ||
'SENSOR_ID sID, ' ||
'to_char(HEADER_DATE, ''YYYYMMDDHH24MISS'') hDate, ' ||
'FIRST_BLOCK_NUMBER fBlock, ' ||
'LAST_BLOCK_NUMBER lBlock, ' ||
'RECORD_QUANTITY recQty, ' ||
'FILE_ID fID, ' ||
'substr(FILE_NAME,1,30) fName, ' ||
'TRACE_SEQUENCE_NO tSeqNo, ' ||
'SENSOR_TYPE sType, ' ||
'to_char(TRAILER_DATE, ''YYYYMMDDHH24MISS'') tdate, ' ||
'NVL(FILE_STATUS_CODE, ''NL'') fStatCode, ' ||
'to_char(PROCESSED_DATE, ''YYYYMMDDHH24MISS'') pDate, '||
'NVL(RECIRCULATE_COUNT,0) recCount, ' ||
'ROW_NUMBER() ' ||
'OVER(ORDER BY TRAILER_DATE DESC, LAST_BLOCK_NUMBER DESC) r ' ||
'FROM logfc10t ' ||
'WHERE DPC_CODE_ORIG = :IN_DPC_CODE ' ||
'AND SENSOR_ID = :IN_SENSOR_ID ' ||
'AND (((TRAILER_DATE <= TO_DATE(:IN_TRAILER_DATE, ''YYYYMMDDHH24MISS''))' ||
' AND (LAST_BLOCK_NUMBER < :IN_BLOCK_NUMBER)) ' ||
' OR (TRAILER_DATE < TO_DATE(:IN_TRAILER_DATE, ''YYYYMMDDHH24MISS'')))) ' ||
'WHERE r = 1 ';

Similar Messages

  • Best Practice: Executing the same code from different triggers

    Swing supports the idea of Actions, which seems to be an implementation of the "Command" pattern. One can create an instance of an Action implementation and set it to several JComponents, like JButton and JMenuItem. Whenever the button or the menu item is triggered, the action gets executed. So far, so good.
    But there are more triggers in Swing that cannot get configured to trigger an action, namely Drops and pressing the window's [X] Close icon. Certainly these fire events, but they do not automatically trigger actions.
    Certainly one can react to importData(TransferSupport) and windowClosing() by manually calling the action's actionPerformed(ActionEvent) method, but as there is no setAction(Action) method at neither the TransferHandler class nor the WindowAdapter class, the question is: Where to take that Action instance from, and what command name to pass to it's constructor, and what to provide as the event source?
    It just seems like the Action framework has a gap here, as it nicely covers these questions for JComponents, but not for JFrame and JDialog.
    So unless there are JFrame.setDropAction(Action) and JFrame.setCloseAction(Action) methods added to the Swing framework (and I doubt they will get added any time near), my question is whether there have been establed some widely accepted best practices (i. e. something that 75% of the programmers will do, not something ONE programmer always does but just he does). Any Swing expert here answering this?

    The window decorations are handled by the OS. That [X] close button isn't a JButton at all.
    JFrame's and JDialog's, however, do have a root panes. And you can ask the root pane to take over window decorations via JFrame#setDefaultLookAndFeelDecorated(true). JDialog has a similar method. When the root pane takes over window decorations, then the [X] icon is a JButton and you could, in theory, set its action to an Action object.
    The the metal LAF window decorations, however, are ugly (I think at least) and I'm not sure how many programs actually use it.

  • Two different vendor supplier for the same code

    Hi,
    We have the two different suppliers supply the material with same code with different values,
    since they are customized products as per customer requirement,we are stuck up with how could it map into the BOM,
    PPC persons always try it with change BOM or change in order,
    How could be simplified?
    With Regards,
    Devendra

    Hello Devendra
    On the standard ERP, there is no way to map this scenario, however, using the DIMP industry solution there is a functionality called Parts Interchangeability.
    Take a look on the following links where this functionality is described:
    A&amp;amp;D Manufacturer Part Number - Discrete Industries and Mill Products - SAP Library
    Interchangeable Manufacturer Parts in MRP - Parts Interchangeability - SAP Library
    BR
    Caetano

  • Drawing images gives 2 different results with the same code.

    Im adding my code on here, and its sort of long but ill try to explain it. Most of it you can ignore.
    Anyway i'm making a tree menu with only 1 level of expansion. So you have a TreeMenu object, and this object has some Branch classes. These Branch classes have Leaf classes. That is all. On the menu there is also a little box where you can click to expand and collapse each branch. if a branch is expanded, all of its leaves are shown. if it is collapsed only the branch name is shown.
    So far what I've described above works, there is a small scale compilable working program, that is alright. Theres just a few bugs to fix.
    A little feature of the tree is if a branch or a leaf is selected (has been clicked on in the past) it has a blue background. This sort of works. The branch names seem to work alright, and some of the leaves. However other if you run the example i provided you can click on Leaf 1, and it will be ok, but if you click on Leaf 2 then there blue background is twice as big as it should be. But for the rest, it works ok.
    This is weird to me because the same code handles any of these same situations. So it seems that i get 2 diferent results with the same code. If anyone would like to help heres some stuff you should know:
    You can ignore Leaf class, i dont think theres any errors in there.
    You can ignore just about all of Branch class except the update() method.
    You can ignore all of TreeMenu class except the inner MouseListener class might be useful.
    You can ignore TreeTester. Just the JFrame tester class.
    to run the code:
    javac TreeMenu.java
    java TreeMenu
    http://cs.ucsb.edu/~jsterling/treemenu.zip
    thanks.

    You make a good point Stefan but unfortunately I already checked that.  I have even copied the mapping (right click copy) and pasted it from the working Mapping to the bad Map (Paste) to make sure the context values were all the same.
    I also opened all the queues and compared the values in each.  All values match exactly except for the result(out) queue.
    In both tests I am using the same IDOC XML file. 
    These are the only differences I see.
    1.  The IDOC is exactly the same as far as I can tell but they come from two different source SWCV.  SAP APPL 4.7 and Steelcase_Procurement (ECC 6.0). 
    2.  The working map uses a local UDF.  The bad map calls the UDF from a Function Group.  Is there a Java version difference between the two?
    A better sample of the result queues look like this:
    Correct Result:
    Thickness of Glass: 20
    Height: 10
    Width: 5
    Length: 18
    Thickness of Glass: 10
    Height: 15
    Width: 8
    Length: 14
    Bad Result:
    Thickness of Glass: 20
    <null>
    <null>
    <null>
    Width: 5
    <null>
    <null>
    <null>
    I took this chance to redesign my Variant Config output to separate the characteristics/values, but I'm still bothered that I was unable to determine what would cause the differing values.
    Any ideas?
    Thanks,
    Matt

  • Why differences in the way different machines handle the same code??

    OK, I've posted some other threads re some difficulties in getting the same code to function identically on, not only different platforms, but even on different machines running Windows!
    Here's another, and I would really appreciate an explanation:
    I have a tree control. Per the user's request, I made the right button function the same way it does on MS File Explorer: When they right click, the currently selected nodes are compared to the node they clicked over. If they clicked over a selected node, then the context menu for the nodes selected is displayed. If they clicked over a different node, then the selection is changed to the new node and the context menu displayed. If they right click over the tree control, but not a node in the tree, then the selection is cleared and no context menu is displayed.
    Works great on my machine.
    However, on some machines, no context menu is displayed, nor is the node selected... UNLESS THEY ALREADY HAVE A NODE SELECTED. I.e., if they have no nodes in the tree selected, they cannot display the context menu by right clicking on a node, nor does the selection change to the node they right click over. It only works if they already have something selected.
    My app is distributed as an executable jar file and I am distributing the JRE with it, so there are no class path issues or differences in the JDK. Basically, my problem can be paraphrased as: Why doesnt' Swing behave the same way on different machines...? At least why not the same on the eame machine.
    It's driving me nuts to think that I've resolved some UI glitch only to find out that, no, it's only fixed on some machines, not others.
    Thanks.

    Well, I normally develop on OSX and then deploy to Windows. But, this last build I have switched to Windows XP. The kinds of differences I am seeing are subtle: what triggers a repaint of the UI and now, it seems, what events are getting triggered by mouse clicks.
    My deployment is an executable jar file, therefore it uses the manifest in the jar, not any classpath variables. I deploy an entire JRE along with the app, and the bat file that launches the app ensures that is the JAVA_HOME I'm using.
    I can only guess that it's some underlying difference in versions of the platform and OS that causes this.
    Here's the entire code for this latest issue re the popups:
            private void maybeShowPopup(NodeInfoTree tree, MouseEvent e) {
                if (e.isPopupTrigger()) {
                    //  They clicked the platform dependent popup trigger...
                    int x = e.getX();
                    int y = e.getY();
                    TreePath[] selectedPaths = tree.getSelectionPaths();
                    if (selectedPaths == null) {
                        selectedPaths = new TreePath[0];
                    TreePath clickedPath = tree.getPathForLocation(x,y);
                    if (clickedPath == null) {
                        //  they right clicked, but not on a node, so clear the selection and return
                        tree.clearSelection();
                        return;
                    } else {
                        // They clicked on a path, so let's see if it is a selected
                        // node.  Search the selected array of paths, short circuiting
                        // out if it is found...
                        boolean foundInSelection = false;
                        for (int i=0; (!foundInSelection && (i < selectedPaths.length)); i++) {
                            foundInSelection = clickedPath.equals(selectedPaths);
    if (!foundInSelection) {
    // They right clicked elsewhere than the selection, so
    // reset the selection to the new path...
    tree.setSelectionPath(clickedPath);
    final TreePath menuPath;
    selectedPaths = tree.getSelectionPaths();
    if (selectedPaths == null) {
    return;
    } else {
    menuPath = selectedPaths[selectedPaths.length-1];
    // Since they did click on a node, now we need to determine
    // what popup menu should be displayed...
    tree.scrollPathToVisible(menuPath);
    NodeInfo ni = (NodeInfo) menuPath.getLastPathComponent();
    // If the last path component is null, then they don't have
    // anything selected, so we do nothing
    if (ni == null) return;
    // See if the Node is overriding our default popup menu...
    com.harcourt.applications.tgen.browser.nodes.NodeMenu nodeMenu = ni.getMenu();
    nodeMenu.activate(tree.getView(),ni);
    JPopupMenu popup = (JPopupMenu) nodeMenu;
    if (popup != null) {
    popup.show(e.getComponent(),
    e.getX(), e.getY());
    The nodeMenu.activate call is just used to check whether or not certain menu options need to be enabled or disabled before displaying the menu. My theory right now is that, on some of these machines (all windows), a right click of the mouse is not generating a mouse event unless they have already something selected. I don't think it's a focus issue, because if they left click to select a node, and then ctrl-left click to de-select it, the right button then no longer generates a popup menu. They must select a node, then right click. Maybe there's no mouse event generated, or maybe this line is failing on some machines?:
    TreePath clickedPath = tree.getPathForLocation(x,y);

  • How to use the same element in different photoshop files?

    It occurs to me often that I use the same element in different photoshop files, a header or footer shown in the example below. So when the footer changes in one document, I need to change this footer in every other single document.
    Is there a possibility to use some kind of template, one single document,  that can be placed in different files , which is still editable afterwards?
    Thanks in advance.
    I'm using Photoshop CS6

    In a single document you can have several pages and these pages may have headers and footers that share smart objects.  If you replace the contents of the an embedded smart object on one page page that is shared on an other page the pages you will see both pages contents are changed. For they share the common object.   It is also possibly to have independent smart object layers. It depends how you create the layers in the single document.
    Example one sharing a smart object hi-light a smart object layer and use menu layer>Duplicate Layer... This will create a second smart object layer that share a common smart object. Each layer has is own associated transform. Do it again and you will have three layers the share a common smart object. So you can use each layer associated transform to position and size the layers contents. Make a picture package for example. When you hi-light any of the three smart layers and you use menu Layer>Smart Objects>Replace Contents... all three layers contents will be replace with the new smart object.  Care must be taken to replace the smart object with an identical size object for only the object is replaced the three associated transform for the three layers are not replaced or changed.
    Example two independent smart objects  hi-light a smart object layer and use menu layer>Smart Objects>New Smart Object via Copy.  This will  create a second smart object layer that has it own embedded smart object copy.  Do it again and you will have three all have independent embedded smart object that are identical.  However they do not have to remain identical.  For example if the first smart object layer was created by using ACR to open a RAW file as a smart object layer the embedded object is a copy of the raw file and its associated RAW conversion settings.  Double clicking on one of the smart object layers and you will see ACR open on its embedded RAW file with the embedded RAW conversion setting.  Changing these settings will update the layer smart object content with new ACR setting and pixel when you click OK in ACR. Repeat for the third and you will find you have three different raw conversions in Photoshop you can mask and blend together to bring out detail.
    I think what your missing is that a smart object contains a copy of the original object.  Changing the original after creating a smart object layer in document will not effect the smart object layer at all. Its independant from the original having a copy of the original. Only changes to the smart object layer and its embedded smart object effect smart object layers.

  • Hi,  I backed up my ipad and iphone on the same computer, will it be shown on the same folder or different? Mine is window 7, try to find the back up file follow the step that apple provided, it shown only iphone instead of ipad. Pls help.

    I backed up my ipad and iphone on the same computer, will it be shown on the same folder or different? Mine is window 7, try to find the back up file follow the step that apple provided, it shown only iphone instead of ipad. Pls help.

    What do you see under Edit > Preferences > Devices?
    tt2

  • Why can't two different users use Itunes on the same computer with different log ins

    Why can't two different users use Itunes on the same computer with different log ins

    Pmorgan5672 wrote:
    Why can't two different users use Itunes on the same computer with different log ins
    They can, but not at the same time.
    If one user left iTunes running, and another user tries to use iTunes from a different Windows user ID, that second user will get an error message.  If they really want to use iTunes, they either have to beg the first user to log in and close iTunes, or else they have to restart the computer.
    If you are asking the technical reason why, it is something about context switching.

  • How do I create a graph with two different y-axis variables with the same x-axis (therefor having two curves)?, How do I create a graph with two different y-axis variables with the same x-axis (therefor having two curves)?

    How do I create a graph with two different y-axis variables with the same x-axis (therefor having two curves)?, How do I create a graph with two different y-axis variables with the same x-axis (therefor having two curves)?

    Hi Libby,
    Select all three columns of data. All three must be 'regular' columns, not Header columns, and the X values must be in the leftmost column.
    Click the Charts button and choose the Scatter chart.
    The resulting chart will initially show only the first and second columns of data, and the selection will have been reduced to show this.
    Click the gear icon at the top left of the selection and choose Share X Values.
    You should see a result similar to this:
    Notes:
    The values on my sample table contain a random element, so they have changed from thhe first image to the second.
    The chart is as created by Numbers, with two edits:
    Data points have been connected with curves, using the Chart nspector.
    The curves were selected and their stroke increased to 2pts, using the stroke formating button in the format bar.
    Regards,
    Barry

  • I dw file.dwt files may insert server side code supposed all pages depended are in the same code eg

    I dw file.dwt (exact like this ext) files may insert server side code supposed all pages depended are in the same code eg cfml?

    I'm sorry, but your English is pretty difficult for me to figure.  I'm assuming your asking how to have a Dreameraver template support ColdFusion. It hat is what you are asking, the template file extension should be:  YourTemplateName.dwt.cfm  - this tells Dreamweaver is a ColdFusion template.
    I hope I understood you and that this helps.
    Lawrence Cramer - *Adobe Community Professional*
    http://www.Cartweaver.com
    Shopping Cart for Adobe Dreamweaver
    available in PHP, ColdFusion, and ASP
    Stay updated - http://blog.cartweaver.com

  • HT4262 I have two networks one each in two cities.  Both are named the same but require different passwords. I am at my second location but cannot connect to his wifi network. How do I delet one network so I can connect to my second network?

    I have two networks one each in two cities.  Both are named the same but require different passwords. I am at my second location and cannot connect to this wifi network. How do I delet one network so I can connect to my second network?

    Just go to the wireless network preferences and empty out all the stored wireless networks.. then scan and connect to the local wireless.
    Select them and tap the - button below it.
    Once they are emptied out.. it might be good to reboot the computer with the remember networks unchecked.
    Start with a clean slate.

  • Running the same code multiple times with different paramters automatica​lly

    Hi guys,
    I want to run the same code multiple times with different paramters automatically. Actually, I am doing some sample scans which takes around 2 hours n then I have to be there to change the paramters and run it again. Mostly I do use folowing paramters only
    X_Intial, X_Final, X-StepSize
    Y_Intial, Y_Final, Y-StepSize
       Thanks,
    Dushyant

    All you have to di is put all of the parameters for each run into a cluster array. Surround your main program with a for loop and wire the cluster array through the for loop. A for loop will autoindex an input array so inside the for loop you just have to unbundle the cluster to get the parameters for each run.
    Message Edited by Dennis Knutson on 07-13-2006 07:50 AM
    Attachments:
    Cluster Array.JPG ‏9 KB

  • What happens when two computers call the same code stored in network storage?

    We have our code on network storage and have only been running code on one computer.  We have now duplicated our setup and would like to use the same code to run the new setup from a different computer.  We would like to run both setups simultaneously (both using same code from network storage).  Will there be conflicts here or do both computers load their own copy of the vi to run from?  I should say that we have no global variables.
    I'm interested in the answer to this question anyway but I would also be happy to hear any suggestions (or even criticisms) on how to do what we are doing.
    Solved!
    Go to Solution.

    You should seriously consider a source control system, which is the best solution here. That gives you one master copy of the code on the network. Each computer retrieves the latest revision from source control, making a copy on the local disk. Source control helps maintain a known good backup, and allows you to track changes and compare versions or revert to older code when something breaks.
    I'm fairly certain you can open the same VIs stored on a network drive on multiple computers concurrently. Global variables are irrelevant here. Each computer will independently load the VIs into memory. The problem is if you edit and save the VI on one computer while it's open on another, and if you make edits on both simultaneously, you'll definitely lose some of the edits and could possibly corrupt your VI and lose all of them, which is why you should be using a source control system instead.
    If you have the application builder, I recommend building your code into an application. You can store the application the network if you want, and run it on multiple computers.

  • Two database with the same sid but different ORACLE_HOME on one host

    two database with the same sid but different
    ORACLE_HOME on one host,and if configure them with
    two differnt lisnter staticaclly,this abosultely work
    because in the lisnter.ora we must provice
    ORACLE_HOME variable,with this ORACLE_HOME the client
    can differentiate which database to connect,but if
    use dynamically register feature,how can the client
    tell which database to connect?

    Also note that this type of configurtion may not be supported.
    Just because a given configuration works in certain given conditions does not mean that it would be supported.
    If this setup is for a configuration that has any value, please also Contact Oracle Support to get their inputs on what you are trying to accomplish.

  • Use the same code module for several steps in the sequence

    Hello All,
      I have been trying to set up a sequence that uses the same code module for all of the steps in the sequence, but am having trouble referring back to it when I need to send it commands.  I have gotten as far as calling the VI in a new thread so that it can be run asynchronously.  I can run the simple sequence and it will indeed open the VI, and move on to the next step.  When I close the VI manually from the front panel, the sequence in TestStand completes, as expected.  So it appears that I have that much working. 
      My question is how to call the separate thread from the main sequence or other sub sequences when I need to edit the parameters.  If I insert an Action step, I am required to select a VI file, but from what I can tell, it opens a different instance of the file, and does not provide an interface with the other instance running asycronously.  My next guess was to use a Statement step, but I was not able to figure out how to configure the lookup string to call the VI parameters.  Beyond that, I'm not sure how to proceed.  Please advise.   
      My intention is to start the code module VI (asynchronously), run several different subsequences within the main sequence that call that same VI and edit it's parameters, close everything and report on the results.  If I am misunderstanding how TestStand is supposed to work, please let me know. 
    Thanks,
    GSinMN    
    Solved!
    Go to Solution.

    What I do is use a Queue to send data to the asynchronous VI.  So it can run and do whatever, but also recieve the commands from the queue.  I use an Action Engine that holds the queue reference and sends the commands.  So you really just have to call the Action Engine from your sequences.
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines

Maybe you are looking for

  • How to use an accented character in a mnemonic ?

    Hi all, I'd like to set the mnemonic of a component (no matter what kind of component) to an accented character such as � / � / � / � / � / �. but with setMnemonic(char c) it doesn't work. with setMnemonic(int code), I can't find a virtual key for an

  • Centering an image in a frame

    Anyone know how to center an image in a frame -centered vertically and horizontally- such that the tags are recognized by at least Internet Explorer and Firefox?

  • HRESS Pay Statement - Add new Column in Overview and Selection table

    Hello, I want to add a column in the "Overview and selection" table for a pay statement service. I want to add field called "off-cycle reason" (OCCAT field from pay result). Is there any work around to do the same? I feel we may need to implement a B

  • 2011 iMac takes to long to cut on

    As soon as I turn on my iMac (which is the 2011 version Quad Core/3.4GHz/16G Ram/2TB HD/2G Graphic card it takes forever to get to the security code screen.  This wasn't a problem when I first got it, but soon after it started to do it every now and

  • TOTAL Play Count... possible?

    This might be a strange question, but I am just curious. I know that when I plug my iPod into my computer and open iTunes, the play count comes up for each song. I was wondering if it is possible to get the total play count from my iPod... just a sin