Avoid procedure or function calls between a SQL operation and an implicit cursor test
when i analyse this code with code expert
atpidgeon wrote:
when i analyse this code with code expert
UPDATE P_PM_CONTROL_COUNT
SET AVAIL_SEG = AVAIL_SEG -1,
ALLOCATION = ALLOCATION -1
WHERE PM_UNIT_TYPE_ID = vrectab(1)
AND USAGE_DATE = vrectab(2)
AND SEGMENT_CODE = vrectab(5)
AND ALLOCATION - UNITS_RESERVED > 0;
IF sql%rowcount = 0 then --Added block and exception to prevent invetory going negative when placing multi units in same unit type out of service.
vErrMsg := 'Could not process your out of service request because your selection for unit '|| vrectab(3) || ' at ' || pvPropertyId || ' for ' || vrectab(2) || ' would cause segment ' || vrectab(5) || ' to be over allocated.';
RAISE SegOverAllocated;
END IF;
i get "Avoid procedure or function calls between a SQL operation and an implicit cursor test.",as far has i know
iff you're doing a sql%rowcount after an update.. trying to see how many rows were updated... you dont want procedure or function calls between the update and the sql% line
correct me if im wrong and how would i fix it?or maybe i shouldnt
You correct it by NOT executing function calls as part of the UPDATE statement.
1. Issue the function calls BEFORE the update statement
2. save the function results into variables
3. use those variables in the UPDATE statement.
v_rectab1 := vrectab(1);
v_rectab2 := vrectab(21);
v_rectab5 := vrectab(5);
UPDATE P_PM_CONTROL_COUNT
SET AVAIL_SEG = AVAIL_SEG -1,
ALLOCATION = ALLOCATION -1
WHERE PM_UNIT_TYPE_ID = v_rectab1
AND USAGE_DATE = v_rectab2
AND SEGMENT_CODE = v_rectab5
AND ALLOCATION - UNITS_RESERVED > 0;
Similar Messages
-
Can we call the Human Task operations and the Rule Designer, etc. from outs
Hi,
I just had one of my customers ask me -
Can we call the Human Task operations and the Rule Designer, etc. from outside the SOA Suite ??
Since these are independent applications, and that they are based on Service Oriented Architecture, I should be able to call these services from outside Oracle SOA Suite (SCA) for reuse.
In case you have any idea about the possibilities, could you share some real world examples / URLs please ?
Thanks & RegardsHi Vaibhav,
Yes, you are right. We are using Oracle SOA suite 11g.
My question is, can these Web Services be directly accessed from, say a .NET application without using BPEL PM, or is using BPEL a must to invoke these services in Human Task operations, Rule Designer, etc ?
Regards -
1. Defining dependencies between Work order operations and Isolation Operation Steps
Hi All
Will you please let me know how i can define dependencies between Work order operations and
Isolation Operation Steps? Suppoose I want to have WAP--->WCA-->WCD at operation level, is it possible? Can we have the Switching of Status & allowing that perticular operation for releads. e.g. I have operation 1 in Maintenance WO Which needs machine where only operational control panel to be Locked & tagged. No Need to Tag total machine. So once i complete complete the taging for it & once give permits for it, system should permits only that much operation. Not all operation which may have some other permits which needs to be issued.
Regards
MakarandHi All
Will you please let me know how i can define dependencies between Work order operations and
Isolation Operation Steps? Suppoose I want to have WAP--->WCA-->WCD at operation level, is it possible? Can we have the Switching of Status & allowing that perticular operation for releads. e.g. I have operation 1 in Maintenance WO Which needs machine where only operational control panel to be Locked & tagged. No Need to Tag total machine. So once i complete complete the taging for it & once give permits for it, system should permits only that much operation. Not all operation which may have some other permits which needs to be issued.
Regards
Makarand -
plz tel me ....
what is the Difference between ? new Operator and Class.forName() ??? ........Class.forName(), takes the class name as parameter,
and loads that class in memory. But it doesn't create
any instance of that class.
That means static methods/variables are available for
use.
new keyword, checks if the class is loaded, if not
then loads that class, and then creates an instance
of that class.Class.forName actually returns the class object for that name (class - for -name). it might load it, if the class hasn't already been loaded, but it's misleading to say that's what that method does
your definition of 'new' is wrong, too. give the dukes back -
Function Call returning old SQL Query
Hello All,
I have a Pipeline Function which creates a SQL within (Dynamic SQL that gets stored in a LONG variable) based on the parameter STRING passed to the function. Inside this function, once the SQL is built, I am inserting this SQL into a log table, for logging purpose.
Note: my function has only one parameter which is a string. This string accepts a name:value pairs with a delimiter which I breakdown inside the function. But this functionality is working fine.
Issue:
When I run the function with parameter with a STRING say (Age = 20, Gender = M) for the first time, it works.
<code>SELECT * FROM TABLE (
PIPE_FUN_SEARCH_PKG.get_search_records ('EMP_AGE:20|EMP_GENDER:M'));
</code>
When I change the parameters to (Age = 20, Gender = F), it gives me the results of the earlier function call.
<code>SELECT * FROM TABLE (
PIPE_FUN_SEARCH_PKG.get_search_records ('EMP_AGE:20|EMP_GENDER:F'));
</code>
When I open the logs, I see the SQL being built is the earlier one.
As a test I closed the session and ran (Age = 20, Gender = F) first. It works fine. When I run a different parameter string, it always mimics the earlier function call.
Is CACHING in play here. I tried both the following:
<code> dbms_result_cache.bypass(FALSE);
dbms_result_cache.flush;
</code>
I tried multiple tests, with different parameters and only the first one runs fine and second one copied the earlier. However, when I open two sessions on two different windows it doesn't happen.
Also, in the Logging table I am capturing the input string as a confirmation, which is coming correctly. But the SQL being build mimics the earlier call.
I tried to set the variable which hold the SQL Statement to empty (v_sql := '';) at the beginning and also at the end. Still no use.
Kindly help if I am over looking anything.
Regards,
AjAj09 wrote:
I have a Pipeline Function which creates a SQL within (Dynamic SQL that gets stored in a LONG variable) based on the parameter STRING passed to the function. The LONG data type has been replaced by the LOB data type. Oracle specifically recommends not using the old LONG data type.
Issue:
When I run the function with parameter with a STRING say (Age = 20, Gender = M) for the first time, it works.
<code>SELECT * FROM TABLE (
PIPE_FUN_SEARCH_PKG.get_search_records ('EMP_AGE:20|EMP_GENDER:M'));
</code>
When I change the parameters to (Age = 20, Gender = F), it gives me the results of the earlier function call.
<code>SELECT * FROM TABLE (
PIPE_FUN_SEARCH_PKG.get_search_records ('EMP_AGE:20|EMP_GENDER:F'));
</code>The tag is ** - not *<code>*.
Why a pipeline function? Why dynamic SQL? Are you using +DBMS_SQL+ to create the dynamic cursor? If not, why not? Only +DBMS_SQL+ allows dynamic binding in PL/SQL. Without that, your code will burn a lot of additional CPU on hard parsing and trash and fragment Shared Pool memory.
When I open the logs, I see the SQL being built is the earlier one.
How do you record the current SQL? Are you using a static variable to capture the SQL statement generated?
From what you have described - this is yet another horribly flawed approach in all respects. To data modelling. To relational databases. To Oracle. To SQL.
Reinventing the SQL language for data retrieval as a pipeline function using a funky parameter interface - sorry, I just don't get that. It is an insane approach. -
Difference in VI call between "recently used" mode and "open" mode
Hi,
we encountered a "problem/difference" in VI calling modes in LabVIEW 8.5.1. Our test VI uses the "call library function node" in order to use a DLL. First we open this test VI with the "Select a File to Open" selection:
The test VI is able to open the selected DLL and the program works fine.
Secondly, we use the "recently used file" selection:
In that case the "call library function node" used in our test VI is not able to work with the selected DLL (in principle we get a problem which was already solved in the following thread: have to manually point to DLL each time LV Runs using Call Library Function Node).
Our question now: Is there a known difference how LabVIEW calls VIs (between different possible ways like open file, use the resently used file list, directly from the windows explorer directory, ...)? At least in this example, there is a difference regarding the "call library function node".
Thanks for your input.
Best regards,
Helmut KöckHi Helmut.
One thing you can do is to look in the LabVIEW.ini file and find the
section that gives the paths for the recent history display on the LV
getting started screen to make sure that they are correct and exactly
the same as the path that you are browsing to.
The LabVIEW.ini file should be located at C:\Program Files\National Instruments\LabVIEW x.x
The section that contains the recent files history should look something like the following:
RecentFiles.projectPathList=...
If that still doesn't work, maybe the following helps you. I found an old support case, where the the customer had a very similar problem.
The solution at the and was as followed:
1. Have the people who wrote the dll put in a debug statement so they could
figure out what directory thinks it is in.
2. Distilled the problem down to a single dll call in a vi. This call
initializes the device and creates a folder. However, it never creates the
data folder when it is opened via the shortcuts menu on the splash screen.
Solution:
The problem was that when they called a VI from the Labview Splash
Screen using the short-cuts, the DLL they called in the VI (which was
programmed to control some hardware) did not talk to the hardware
properly. However, if they used the "Browse" button to find the same
file and execute it, then it would run properly and communicate.
After a lot of debugging, they traced the problem to a global variable
in the C++ program (that made the dll) that was not being properly
initialized when calling the DLL with the "shortcut" approach. I really do not know
why there is a difference between the two ways of starting the
VI that calls the DLL in Labview.
Once they redefined the variable in a different way they got it working,
finally.
So they found a problem in their dll files, which were programmed in C. Maybe it is a good idea to debug the dll files and look for problems.
Best Regards,
Matteo -
Can someone shed some light on the difference, intended functionality between the /Shared Items and the /Users/Shared folders?
do any/all network services use the Shared Items folder?
Not all services use it. Time Machine Server does, and I'm not sure which others. FTP is not controlled by Server.app. -
Whats the functional difference between user IDs SAP* and DDIC?
Whats the functional difference between SAP* and DDIC? Can any one tell me please. I am new here. Thanks in advance.
Hi Farooq,
There are three user IDs in various SAP clients.
1. SAP* (Client 000 and 001)
SAP* denotes the default super user and has all administrative powers.
2. DDIC (Client 000 and 001)
DDIC user is responsible for the maintenance of the ABAP/4 Dictionary and the software logistics.
3. EarlyWatch (Client 066)
The EarlyWatch user has access only to monitoring and performance data.
Please check this link for more information on data dictionary objects.
http://help.sap.com/saphelp_webas620/helpdata/en/cf/21ea31446011d189700000e8322d00/content.htm
Hope this will help.
Regards,
Ferry Lianto -
Functionality Differences between versions 4.7 and ECC 6.0?
Hi All,
Can anyone tell me what are the main functional differences between 4.7 and ECC 6.0? What is the release date/year for ECC 6.0.
Regards,
MD.Hi.
1) ECC is more towards OOPS concepts.
2) It has new debugger,
3) New Enhancement Framework is introduced in ECC.
4) ECC contains many more badis.. in some functional areas such as HR.
5) Its more efficient to use Adobe forms in ECC.
6) Some of the fields and tables have changed in ECC.
http://solutionbrowser.erp.sap.fmpmedia.com/
http://www.sap.com/services/servuptech/bestpractices/index.epx
Solution Browser would give the differences (Features):
http://solutionbrowser.erp.sap.fmpmedia.com/ Give source and target versions.
Release Info:
ECC 6.0:
http://help.sap.com/saphelp_erp2005/helpdata/en/43/68805bb88f297ee10000000a422035/frameset.htm
ECC 5.0:
http://help.sap.com/saphelp_erp2004/helpdata/en/c6/feda40ebccb533e10000000a155106/frameset.htm
You can find the difference in release notes of each SAP version.
Here are the links.
http://help.sap.com/saphelp_47x200/helpdata/en/fc/e3003deddfae4de10000000a114084/frameset.htm
http://help.sap.com/saphelp_scm50/helpdata/en/28/b34c40cc538437e10000000a155106/frameset.htm
http://help.sap.com/saphelp_erp2005/helpdata/en/43/68805bb88f297ee10000000a422035/frameset.htm
Regards,
Srini Nookala -
Link between Oder number, Operations and PRT ?
Hello,
I am trying to find the link between Ordeer number (T-code IW32) , its Operations and PRT linked to Operations.
Can someone shed some light on the links for these in PM tables ?
Thanks.
Regards,
Rajesh.Hi,
Not sure of the table links..
Use the BAPI BAPI_ALM_ORDER_GET_DETAIL..to get the operations, PRT other details for the service order..
Thanks
Naren -
Javascript function call from PL/SQL block
Hello,
I am writing this pl/sql block that has checkbox and onselect, it calls javascript function.
I defined javascript function in page header, even though I get error that says function is not defined.
Please help.
Thank you,
H.I got it resolved...!!!
-
What is the difference between Execute SQL Task and OLE DB Command
Besides the obvious, Execute SQL Task being used in Control Flow, and
OLE DB Command being used in Data Flow what is the difference between the two? Is one supposed to use
Execute SQL Task to produce a result set that then gets handed over to
Data Flow and OLE DB Command ? Everything that I have seen on
OLE DB Command is pretty much execution of a Stored Procedure with ? parameters. It seems as though I got to a point where I had to perform my data edits pretty much entirely in a Stored Procedure executed by
OLE DB Command rather than trying to use the SSIS GUI for everything. I didn't really see in any of my Google searches out there that simply used
OLE DB Command as a straight parameterized SQL against tables for editing and cleansing purposes and handling returns back from SQL Server for COUNT(*), etc..
I know I have posted multiple forums out there regarding this issue but I cannot seem to get a straight answer and some solid direction. So for now, my
Execute SQL Task gives me my editable result set and then control is handed off to
Data Flow and ultimately to my Stored Procedure executed by an
OLE DB Command which pretty much does the chunking for me and performs my data edits and handles my record anomalies through SQL Server Table data stores accordingly or sets flags accordingly if the data passes.
I welcome your thoughts and Thanks for your review and Thanks in advance for any replies and direction that anyone might provide.
Hi ITBobbyP,
OLE DB Command will always process data row by row, whereas Execute SQL task if you call a Stored Procedure it can process data in bulk. As you said, the biggest difference is that Execute SQL Task being used in Control Flow, and OLE DB Command being
used in Data Flow. They are used in different places.
Using Execute SQL Task, we can save the rowset returned from a query into a variable. The Execute SQL task can be used in combination with the Foreach Loop and For Loop containers to run multiple SQL statements. These containers implement repeating control
flows in a package and they can run the Execute SQL task repeatedly. For example, using the Foreach Loop container, a package can enumerate files in a folder and run an Execute SQL task repeatedly to execute the SQL statement stored in each file. I think this
is a big advantage for Execute SQL Task.
As to OLE DB Command, we can easily run an SQL statement for each row transformation in a data flow, then directly insert the outputs to a destination.
To sum up, there are many difference between those two components. We should make better choice based on our actual requirement.
Thanks,
Katherine Xiong
Katherine Xiong
TechNet Community Support -
Difference between Static SQL Query and Dynamic SQL Query.
Hi,
Please explain the basic difference between static and dynamic sql queries. Please explain with example.Static: http://download.oracle.com/docs/cd/E11882_01/appdev.112/e10472/static.htm
Dynamic: http://download.oracle.com/docs/cd/E11882_01/appdev.112/e10472/dynamic.htm -
Transfer VOIP Calls Between Cisco Desk Phone and Cisco Jabber For IPhone 9.5
Does anyone know how to transfer an active voip call from a Cisco IP Desk Phone to Cisco Jabber for IPhone? I can transfer a call from Cisco Jabber for IPhone to my Cisco IP Desk Phone no problem. I put the call on hold and then click "Resume" on my Cisco IP Desk Phone. However I cannot do the same but the other way around. If I put the call on hold on my Cisco IP Desk Phone, I see "no active call" on my Jabber client. The only information I could find slighlty relevant was using the Mobility Key/Remote Destination Profile feature however this defeats the object as this will forward to an external number, e.g. mobile and I just want to transfer the call within the VOIP environment between the two devices that are using the same directory number.
I am using Cisco Call Manager 9.1(2), Cisco Presence 9.1 and Cisco Jabber for IPhone 9.5.
Any help would be greatly appreciated.
Kind Regards,
Paul Parker.Did you ever find an answer to this ?
I am seeing the same behavior and trying so see if I can put calls on hold and pick them up both ways also.
The only answer I seem to have found is to use park instead
That would/should work but I would just prefer to hold/unhold
Just not sure why we would not be able to hold/unhold on what is essentially a "shared" line
Does anyone have this working for them ? -
What are the functional differences between F55 Zebras 1 and 2, and their respective uses
Would like to hear from those of you who can explain the functional/utility differences between the F55 Zebras 1 and 2. Jon
I'm with Robbie, and I've been making a living doing this for almost 40 yrs. I do often use zebra one, abd yes, skin tones vary widely ( I shoot many black faces) but you have to interpret and adjust based on experience. Having used this camera for over two years and having carefully reviewed everything I shoot, I, like Robbie, have full confidence in what my results will be, now that I have my oled set and the way I like it. I prefer being in the energy on the creative side and Sony has provided a system that frees us from much of the exposure measuring that film required. I stop bring my meters but rarely use them, and my footage looks just fine.
Maybe you are looking for
-
[SOLVED] Suddenly unable to mount samba share using cifs
I have a home server running ArchLinux, hosting an SMB share. My client box is also ArchLinux, both are up to date, running Linux-ck 3.9.2-2-ck. Prior to rebooting both machines around twenty minutes ago, the share mounted fine for months. Here is th
-
Can I put a mark, a red dot, on a photo?
Hi, sorry for this newbie question, have never used iPhoto and need to know if I can use it to place a red dot on a part of any photo. ??? I am posting some pictures on a gardening forum. Trying to identify a certain type of tree. There are many tree
-
I need to reinstall adobe 8.0 standard on another pc.. i have no media.
i need to reinstall adobe 8.0 standard on another pc.. i have no media
-
hello experts! i have a problem with a PLD i cannot add a picture to my PLD. the size is 17 kb and it is saved as jpg also, in the file name it does not appear the name of the file. i select it by clicking the browse button, i find it but stil...it d
-
My serial number isn't working with the new Photoshop on a different computer. Any ideas?