How are parameters based on %ROWTYPE checked?
Hi there,
(Oracle DB 11g)
Please consider the following sample code:
CREATE table t1(c1 number, c2 DATE);
CREATE table t2(c1 number, c2 DATE);
CREATE OR REPLACE PROCEDURE p (p1 IN t1%ROWTYPE) IS BEGIN NULL; END;
DECLARE
v t2%ROWTYPE; -- please note, different table from p definition
BEGIN
p(v); -- this compiles!
END;
/It looks like Oracle validates the parameter based on the underlying record elements only, not on the actual "source" of the record. Is that correct?
Is this a bug or by design? In either case, I think it is not good because I just found a bug in my application where the wrong table was referenced but it was only detected when the code was deployed to another environment where that table didn't exist...
Thanks
Luis
Luis Cabral wrote:
Why is it different when using <table>%ROWTYPE? Maybe because it is not a explicitly named record? Kind of. PL/SQL is an independent language based on Ada. SQL is integrated with it.
PL/SQL is a strong typed language. A type structure in PL/SQL is via defined via the record clause. However, it would be quite inflexible and cumbersome to use the record clause for duplicating SQL structures you want to use in your code. Thus the +%RowType+ clause. Instead of you having to identify the structure members and data types, it does it for you.
The result is a record structure. PL/SQL does not know about SQL tables. It does not use tables. That is the function of the SQL engine - and the SQL language is used (within PL/SQL code) to access tables.
PL/SQL thus needs to make calls to the SQL engine to, for example, insert data into a table. PL/SQL uses a data structure as bind values for that SQL call. PL/SQL itself does not write directly to that table using that structure.
That PL/SQL structure needs to match the structure of the table. And that is about it.
Why should PL/SQL check the write target (specified in another language and written to by that language's engine). Why should it determine whether its structure it is passing to the SQL engine, matches that of the SQL engine's target? The only requirement here is that the structure itself is valid - not whether that structure, when it was defined, was defined using the same SQL target.
I still think that not checking the table the record is based on may lead to confusion.Disagree. It will break a lot of existing code and make existing code a lot more complex.
Similar Messages
-
How are +Cleared+ Outbound Vendor Cheques / Checks reconciled in SAP?
Hello,
We get a cheque Cleared file from our bank everyday. in txt format. The file contains details of all the CLEARED cheques on that day. Since we have approx 10 checkign accounts at same bank branch, the file contains list of cleared cheques from all these checking accounts. e.g. checque number, cheque amount, date and chequing account. The bank also sends a second file apart from cleared check file. The second file contains all other transactions except the outbound cleared checks.
We do not use Electronic or Manual Bank statement functionality.
The project wants to only reconcile the cleared checks file.
Question:
Is there an SAP program used only to reconcile outbound cleared cheques?
What configuration is required to ensure electronic reconciling of cleared checks?
Any tips / thoughts to help make this functionality work in SAP?
ThanksDear,
It is possible for you to reconcile without EBS or Manual BS, you can use transaction code FB05 and have to select post with clearing option. You have to run FBL3N for payments and collection bank accounts, if you have main bank for BS then it would be fine for you to know the entries that have been posted.
If it is a payment transaction then you have to use posting key 50 and amount and main bank gl account in FB05 then select process open give payment bank account and enter. This will list you all the items then select the transaction and save the posting.
If you check in FBL3N, here give main bank gl account and payment bank gl account and execute. You will see that a new item have been posted in main bank account and a clearing document in the payment bank account.
The same procedure for collections also.
Note: It would be easy if you configure EBS or Manual BS, as this will reduce the time taken for the end user to reconcile manually. -
Hi All,
I am new to TestStand. Still in the process of learning it.
What are Parameters? How are they differenet from Variables? Why can't we use variables for passing data from one sequnece to another? What is the advantage of using Parameters instead of Variables?
Thanks in advance,
LaVIEWan
Solved!
Go to Solution.Hi,
Using the Parameters is the correct method to pass data into and out of a sub sequence. You assign your data to be passed into or out of a Sequence when you are in the Edit Sequence Call dialog and in the Sequence Parameter list.
Regards
Ray Farmer -
I can find many purchases in my purchase history, but they are not found when I "Check Available Downloads." How else can I download my purchases?
what happened to the initially downloaded files ? did you make a backup ? do you use time machine ?
-
How to return multiple tags (based on different checks) in a for loop?
Hi,
I'm trying to return multiple elements, based on different checks that are done in the XQuery, within a for loop. But I'm getting syntax errors at any attempt to do this.
This is the structure of what I'm trying to do:
<ActionList>
<ACtion>
let $total := count(...)
for $x in (1 to $total)
let $lineItems := $someVariable/*:Items/*:Item[$x]
return
if(...)
<Qty1>{...}</Qty1>
else ""
if(...)
<Qty2>{...}</Qty2>
else ""
{ if(...)
<Qty3>{...}</Qty3>
else ""
<LinesList>
let $totalcount(...)
for $y in (1 to $totalcount(...)
let $DTL := $someVariable*:DTL[$y]
return
<Line>
<Carrier>{...}</Carrier>
<Path>{...}</Path>
<CA>{
if(...)
data($$someVariable/*:CA)
else
}</CA>
<RE>{
if(...)
data($someVariable*:CA[@XX="RG"])
else
}</RE>
<Time>{
if(...)
data($someVariable*:CA[@XX="BN"])
else
</Time>
</Line>
</LinesList>
</ACtion>
</ActionList>
I'm not able to return elements without having their father being returned as well, I just want to iterate over those fields and, based on that verification, decide whether they should be returned or not.
Can someone please advise?An example anyway...
Input document ($d) :
<ns0:Items xmlns:ns0="http://my.company.org/my-namespace">
<ns0:Item type="A">
<ns0:Qty>2</ns0:Qty>
<ns0:UnitPrice>10.00</ns0:UnitPrice>
<ns0:DTL>
<ns0:Article>ART001</ns0:Article>
<ns0:DispatchDate>2012-01-20</ns0:DispatchDate>
<ns0:Destination direct="1">Location1</ns0:Destination>
</ns0:DTL>
<ns0:DTL>
<ns0:Article>ART002</ns0:Article>
<ns0:DispatchDate>2012-01-21</ns0:DispatchDate>
<ns0:Destination direct="1">Location2</ns0:Destination>
</ns0:DTL>
</ns0:Item>
<ns0:Item type="B">
<ns0:Mass>5</ns0:Mass>
<ns0:Unit>kg</ns0:Unit>
<ns0:DTL>
<ns0:Article>ART003</ns0:Article>
<ns0:DispatchDate>2012-01-20</ns0:DispatchDate>
<ns0:Destination direct="1">Location3</ns0:Destination>
</ns0:DTL>
<ns0:DTL>
<ns0:Article>ART004</ns0:Article>
<ns0:DispatchDate>2012-01-21</ns0:DispatchDate>
<ns0:Destination direct="1">Location4</ns0:Destination>
</ns0:DTL>
<ns0:DTL>
<ns0:Article>ART005</ns0:Article>
<ns0:DispatchDate>2012-01-22</ns0:DispatchDate>
<ns0:Destination direct="2">Location5</ns0:Destination>
</ns0:DTL>
</ns0:Item>
</ns0:Items>XQuery :
declare namespace ns0 = "http://my.company.org/my-namespace";
<DispatchInfo>
for $i in $d/ns0:Items/ns0:Item
return
<Parcel>
if ($i/@type = "A")
then <Amount>{xs:decimal($i/ns0:Qty * $i/ns0:UnitPrice)}</Amount>
else <Weight>{concat($i/ns0:Mass, " ", $i/ns0:Unit)}</Weight>
, for $j in $i/ns0:DTL
return
<Article>
<Num>{data($j/ns0:Article)}</Num>
, <Dt>{data($j/ns0:DispatchDate)}</Dt>
, if ($j/ns0:Destination/@direct = "1")
then <Dest>{data($j/ns0:Destination)}</Dest>
else ()
</Article>
</Parcel>
</DispatchInfo>Output :
<DispatchInfo>
<Parcel>
<Amount>20</Amount>
<Article>
<Num>ART001</Num>
<Dt>2012-01-20</Dt>
<Dest>Location1</Dest>
</Article>
<Article>
<Num>ART002</Num>
<Dt>2012-01-21</Dt>
<Dest>Location2</Dest>
</Article>
</Parcel>
<Parcel>
<Weight>5 kg</Weight>
<Article>
<Num>ART003</Num>
<Dt>2012-01-20</Dt>
<Dest>Location3</Dest>
</Article>
<Article>
<Num>ART004</Num>
<Dt>2012-01-21</Dt>
<Dest>Location4</Dest>
</Article>
<Article>
<Num>ART005</Num>
<Dt>2012-01-22</Dt>
</Article>
</Parcel>
</DispatchInfo> -
How are you checking quality in the upgrade process?
When upgrading your EBS, how are you managing quality?
Are you using solutions such as Quality Center and Quick Test Pro (from Mercury)? Are you using other tools?
Which test sets are you using to ensure that the upgrade had completed successfully?Hi,
I am not very good at testing and nor I have used any testing tools.
But I think there are various post upgrade task which measures the quality of upgrade.
In my view upgrade quality can be decided on two factors
1.) Performance of new instance
2.) Is there any issue with Data ( Check for all tests and reports)
Pravin -
Previously, the "Check for updates" option is found under the Help menu. In Firefox 4, I cannot find this option; how will we be able to check if there are available updates?
Can this new version update itself automatically? How do I set this option?Why do developers move stuff just to move it?
-
I would like to buy used Ipad 3 32 or 64 GB.It is cash deal and no warranty. What are the things I should check and how to do it ?
Make sure it is in perfect working order before you turn over any money.
Test connected to Internet. Test Safari and several other apps for crashes.
If it passes this test, it must now have find my iPhone turned off by the seller. They must also remove the device from their iCloud account.
*****Please observe this. If the seller can't turn off find my iPhone, then it is not his iPad to sell. It will lock when you try to activate and will be worthless.****
If this is the owner of the iPad he can also remotely erase the iPad with iCloud.
http://support.apple.com/kb/HT5661 -
How are the parameters passed by an EJB?
I got a problem on parameters passing of my bean and also got confused.
Let's say my Bean has a method call update(MyObject o);
In the client side, I do
MyObject obj = new MyObject();
myBean.update(obj);
In the bean side, I do
public void update(MyObject obj) {
obj.setX(100); // let say this change one of the members of MyObject
Now, in my client side after the bean update() method call, do I see the changes in MyObject obj? If I do get the changes, the bean must be doing a reverse stub-skeleton call to update my client copy, is that true or I should not assume that?
I was not thinking about all these when developing and the above code works as my assumption in WebLogic 5.1 and 6.0. But, when I port my bean to WebSphere 3.5, the above code crap out -- the client does not see the changes!!
Does anyone know what the inside of this or have any suggestions?Thanks Jerome, harpreet,
What you two say make sense, however, the problem is still a mystery.
I started developing without thinking of the local copy or remote copy of the parameters between the client and the bean. WebLogic somehow reads my mind and worked the way I wanted (the parameter changes affect the the client copy, how they do that?).
When I finished coding and started porting my bean to WebSphere, I realized beans in WebSphere work in a conceptually different way (parameters are passed by value).
Unfortunately WebSphere works in a kind of logical way but not what I wanted, and WebLogic works magically as I intended but I don't understand how they do it.
So, the question comes down to Are parameters passed by reference or passed by value in EJBs?
If WebLogic passes parameters by reference, is it doing a reverse stub-skeleton call?
If WebSphere passes parameters by value, how can I make it pass by reference?
--Lichu -
How can i catch the jsp checking event ?
As we know, there are three parameters which is about checking in the weblogic.xml, pageCheckSeconds,*servlet-reload-check-secs*,*resource-reload-check-secs*, but how can i catch the checking event when the webapp is active.
The fellowing is my simple test, i deployed a webapp on a weblogic server instance, and it was actived. I wrote a simple bash shell to try to catch the event, but fail. i througnt it may be dependent on the webapp's stage mode. but i change the mode, and try again, it was fail too.
[weblogic@tdy218 ~]$ ls
getLastAccessTime.sh webapps
[weblogic@tdy218 ~]$ ./getLastAccessTime.sh ~/webapps/Test/login.jsp
The file's last access time is: 2011-05-22 11:10:21.000000000 +0800
The file's last access time is: 2011-05-22 11:10:21.000000000 +0800
The file's last access time is: 2011-05-22 11:10:21.000000000 +0800
The file's last access time is: 2011-05-22 11:10:21.000000000 +0800
The file's last access time is: 2011-05-22 11:10:21.000000000 +0800
The file's last access time is: 2011-05-22 11:10:21.000000000 +0800
The file's last access time is: 2011-05-22 11:10:21.000000000 +0800
[weblogic@tdy218 ~]$ ./getLastAccessTime.sh
/bea/wls924/user_projects/domains/base_domain/servers/AdminServer/stage/Test/Test/login.jsp
The file's last access time is: 2011-05-22 11:11:37.000000000 +0800
The file's last access time is: 2011-05-22 11:11:37.000000000 +0800
The file's last access time is: 2011-05-22 11:11:37.000000000 +0800
The file's last access time is: 2011-05-22 11:11:37.000000000 +0800
The file's last access time is: 2011-05-22 11:11:37.000000000 +0800
The file's last access time is: 2011-05-22 11:11:37.000000000 +0800
The file's last access time is: 2011-05-22 11:11:37.000000000 +0800
The file's last access time is: 2011-05-22 11:11:37.000000000 +0800
[weblogic@tdy218 ~]$ stat
/bea/wls924/user_projects/domains/base_domain/servers/AdminServer/stage/Test/Test/login.jsp
File: `/bea/wls924/user_projects/domains/base_domain/servers/AdminServer/stage/Test/Test/login.jsp'
Size: 634 Blocks: 8 IO Block: 4096 regular file
Device: 804h/2052d Inode: 583725 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 502/weblogic) Gid: ( 500/ bea)
Access: 2011-05-22 11:11:37.000000000 +0800
Modify: 2010-05-24 14:49:08.000000000 +0800
Change: 2011-05-22 11:10:21.000000000 +0800
The jsp file's last access time didn't changed in the past.
[weblogic@tdy218 ~]$ more getLastAccessTime.sh
#!/bin/bash
declare -i m=1
declare -i n=100
while [ $m -le $n ]; do
echo "The file's last access time is: $(stat -c %x $1)"
m=m+1
sleep 3
done
weblogic.xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE weblogic-web-app PUBLIC "-//BEA Systems, Inc.//DTD Web Application 8.1//EN" "http://www.oracle.com/technology/weblogic/servers/wls810/dtd/weblogic810-web-jar.dtd">
<weblogic-web-app>
<jsp-descriptor>
<jsp-param>
<param-name>pageCheckSeconds</param-name>
<param-value>2</param-value>
</jsp-param>
</jsp-descriptor>
<container-descriptor>
<servlet-reload-check-secs>2</servlet-reload-check-secs>
<resource-reload-check-secs>2</resource-reload-check-secs>
</container-descriptor>
<context-root>/jdbc</context-root>
</weblogic-web-app>
env :
WebLogic 9.2 MP4、Redhat Linux AS 4 Update 8 x86.I tested on WLS 11g ps2(10.3.3) which is running in Development Mode also, but it was the same as WLS 9.2 MP4.
During the weblogic server running, it don't check the application resources , but it will check the $Domain_Home/autodeploy directory every three seconds in Development Mode , the following is the result.
[weblogic@tdy218 ~]$ ./getLastAccessTime.sh /bea/wls924/user_projects/domains/base_domain/autodeploy
The file's last access time is: 2011-05-22 12:01:43.000000000 +0800
The file's last access time is: 2011-05-22 12:01:43.000000000 +0800
The file's last access time is: 2011-05-22 12:01:43.000000000 +0800
The file's last access time is: 2011-05-22 12:01:46.000000000 +0800
The file's last access time is: 2011-05-22 12:01:46.000000000 +0800
The file's last access time is: 2011-05-22 12:01:46.000000000 +0800
The file's last access time is: 2011-05-22 12:01:49.000000000 +0800
The file's last access time is: 2011-05-22 12:01:49.000000000 +0800
The file's last access time is: 2011-05-22 12:01:49.000000000 +0800
The file's last access time is: 2011-05-22 12:01:52.000000000 +0800
Ctrl + ^
[weblogic@tdy218 ~]$ ./getLastAccessTime.sh ~/webapps/Test
The file's last access time is: 2011-05-22 17:26:25.000000000 +0800
The file's last access time is: 2011-05-22 17:26:25.000000000 +0800
The file's last access time is: 2011-05-22 17:26:25.000000000 +0800
The file's last access time is: 2011-05-22 17:26:25.000000000 +0800
The file's last access time is: 2011-05-22 17:26:25.000000000 +0800
The file's last access time is: 2011-05-22 17:26:25.000000000 +0800
The file's last access time is: 2011-05-22 17:26:25.000000000 +0800
The file's last access time is: 2011-05-22 17:26:25.000000000 +0800
The file's last access time is: 2011-05-22 17:26:25.000000000 +0800
Ctrl + ^
[weblogic@tdy218 ~]$ ./getLastAccessTime.sh ~/webapps/Test/
insert.jsp login.jsp query.jsp tdy218.sql WEB-INF/
[weblogic@tdy218 ~]$ ./getLastAccessTime.sh ~/webapps/Test/login.jsp
The file's last access time is: 2011-05-22 11:44:31.000000000 +0800
The file's last access time is: 2011-05-22 11:44:31.000000000 +0800
The file's last access time is: 2011-05-22 11:44:31.000000000 +0800
The file's last access time is: 2011-05-22 11:44:31.000000000 +0800
The file's last access time is: 2011-05-22 11:44:31.000000000 +0800
The file's last access time is: 2011-05-22 11:44:31.000000000 +0800
The file's last access time is: 2011-05-22 11:44:31.000000000 +0800
The file's last access time is: 2011-05-22 11:44:31.000000000 +0800
The file's last access time is: 2011-05-22 11:44:31.000000000 +0800
The file's last access time is: 2011-05-22 11:44:31.000000000 +0800
Ctrl + ^
I set the frequency to every one seconds this time by using sleep method in my Bash Shell script.
#!/bin/bash
declare -i m=1
declare -i n=100
while [ $m -le $n ]; do
echo "The file's last access time is: $(stat -c %x $1)"
m=m+1
sleep 1
done -
How to find Based on PO item find ProjSt or Common Stock?
Hi Gurus,
How to find based on PO item and line item number find whether Project stock or it's common stock? It's there any standard report is there? or provide me table name use with SQVI transaction code?
Thanks and Regards,
Deethya.BPO with account assignment category P - it is created for projects and need to provide account details in the tab.
You can check these details from table EKPO - ( EKPO-KNTTP equal to P).
Project stock can be finding in MMBE using special stock indicator as Q. Details can be getting from table MSPR.
Regards,
Narendra. -
How are ePrint apps created and maintained?
Just bougt a new small HP printer for my home office and discovered ePrint and apps support. And amazed, did not expect this technology in entry level small/home office type printers.
And immediately new questions on what possibilities this opens up for printing applications
What is required to create new apps?
Is it possible to use this technology to add local office apps? I.e. to print site/office specific forms, trivial network interactions and maybe a bit more.
Is subscription type apps supported/allowed, where the app is only available as part of a third party subscription package?
A lot can be built around the email based ePrint service alone, but having ability to also do some simple interaction with the user at the printer would open for a wide range of new possible uses.Hi,
Double post, please use:
http://h30434.www3.hp.com/t5/Printer-All-in-One-Install-Setup/How-are-ePrint-apps-created-and-mainta...
Regards.
BH
**Click the KUDOS thumb up on the left to say 'Thanks'**
Make it easier for other people to find solutions by marking a Reply 'Accept as Solution' if it solves your problem. -
How to change font size in check printing program in AP Invoice
I would like to know how to change font size in check printing program in Oracle Payables Module for Invoice printing. We are using Oracle standard
report to print check.
Concurrent program short name : APXPBFEL
Prt file : APLASP.prt
I modified prt file for code 199 like below
code "199" esc "(8U" esc "(s0p12.00h10.00v0s0b3T" esc "&k11.75H"
Font size changed for last page only which prints checks, for Void pages its printed with default font. For Page 1 printed with default font and page 2 has reduced font. This change is not intiallized for all pages.
Please let me know if you any of you know how to change fonts.
Thanks,
Anand*Default FullZoom Level: https://addons.mozilla.org/firefox/addon/default-fullzoom-level/
-
Hi there how are you guys out there of this forum? I got a question for y'a
Hi there how are you guys out there of this forum? I got a question for y’all
I wanted to know how I could record different folders using iTunes
Cause when recorded 2000 thongs on the DVD
There were 2000 songs to go through
So I really wanted to have had folders and then the music recorded inside them
So I could get right to where I wanted real quickly
Could anyone please teach me how to do that real quickly?
Can we do it with iTunes?
I know we can do it with Nero.1) Go to file, select new playlist. Creat the playlaist.
2) Download your music into iTunes.
NOTE: CHECK 'Recently Added' before you download your music.
If the select boxes has a check in them, turn it off by
holding down the 'ctrl' key and selecting one of the
checked boxes. This shold turn off all the checks.
It would be better to clear 'Resently Add' of all
previous downloads, but I don't know how to do that
yet.
3) under 'PLAYLIST' on the right, select 'Recently Add'.
all of your song should show there with a check in the selection
box.
4)Hold the shift key and select the frist (selete records name),
then the last recorded tune. All of the recordings shouls light
up blue.
5) While holding the 'shift' key, drag one of the records to your new
playlist. All of the blue highlighted song will transfer to the new
playlist. -
How are attribute and text master data tables linked in SAP R/3?
Hello,
how are attribute and text master data tables linked in SAP R/3?
Most tables with attribute master data like T001 for company codes,
have a text master data table T001T (add "T" to table name).
When looking at the content of table T001 via transaction se11,
the text are automatically joined.
But for some tables there is no "T"-table (e.g. table TVBUR for sales offices
has no text table TVBURT), but in se11 you get texts. There is an address
link in TVBUR, but the Name1, etc. are empty.
a) Where are the text stored?
b) How does the system know of the link?
Hope someone can help!
Best regards
ThomasHi Thomas
The master and text table are not linked by name, of course, if you see the text table, it has the same key fields of master table, only it has the field key spras and the field for description.
The link beetween the tables is done by foreign key: if you check the text table TVKBT u need to see how the foreign key for field VKBUR is done:
-> Foreing key with table TVBUR
-> Foreing key field type -> KEY FIELD FOR A TEXT TABLE
->Cardinality-> 1-:CN
It's very important the attribute sets for Foreing key field type, if it's KEY FIELD FOR A TEXT TABLE, it'll mean the table is a text table: i.e. that mean the master table is a check table for the text table, where the foreign key type is for text table.
U can find out the text table of master table by SE11: GoTo->Text Table
U can fined some information in table DD08L.
Max
Maybe you are looking for
-
Mail Wont Open at all! "Mail closed unexpectedly"
Hi, Restarted my Macbook after a preferences error and for some reason I cannot open mail. When I click the applications icon in the dock a box appears in the centre of my screen telling me that "Mail closed unexpectedly". It gives me the option to '
-
I have tried to upgrage my itunes but now it wont open!!!
Hi!! ive got myself in a bit of a mess, ive tried to update my itunes and followed the process ... after restarting my computer i clicked on the itunes icon and it asked me to choose a language so i followed the installation process again, and downlo
-
Hi, ive been searching around for for 4-5 hours on google and here and I'm turning a bit desperate I rebooted the server today, and after that it just hangs on collecting data, mmc stuff works on random, I got evenviewer open, and checked system and
-
How to dsplay the values based on the check box?
forms6i Hi to all the requirment the we have already master detail form.example emp details based on the dept number.in the form just only displays three coloumns per record wise(emp details). actually my requrment is place the check box each record
-
Route Pattern with Pause in CUCM 10.5
Dear Experts, I need to create a route pattern with a pause to dial a secondary number. the customer is forwarding international calls to tollfree number, then the user is dialling the international number. He is requesting to make it as one step, di