Home » Developer & Programmer » Forms » Form Closes While Compiling (Forms 6i, 10G Database)
Form Closes While Compiling [message #466536] Tue, 20 July 2010 01:18 Go to next message
stalin4d
Messages: 226
Registered: May 2010
Location: Chennai, Tamil Nadu, Indi...
Senior Member
Dear,

I have a form, using views which has tables from other databases.
eg:my database name is G1 here i have a view

MR_HEAD

CREATE OR REPLACE VIEW MR_HEAD AS
SELECT "MR_HEAD_KEY","MR_TRAN_TYPE","MR_NO","MR_DATE","PO_TYPE","PO_NO","VENDOR_CODE",
       "MODIFY_FLAG","SUPERSEDE_FLAG","REF_MR_HEAD_KEY","PO_KEY","PO_DATE","REJECTION_NO",
       "USER_ID","LAST_UPD_DATE" 
FROM INMATMAS.MR_HEAD@SPICFIN


i am linking my database G1 with Above Database.
so after using this in my form as 'INMATMAS.mr_head@DB_OPTIMAT'[/email]
for insert/select.

i cant able to compile it. form closes immly when i compile this.

what must be the reason, pls help.

Stalin Ephraim
[EDITED by DJM: cut overly long line]

[Updated on: Tue, 20 July 2010 07:21] by Moderator

Report message to a moderator

Re: Form Closes While Compiling [message #466564 is a reply to message #466536] Tue, 20 July 2010 02:58 Go to previous messageGo to next message
Littlefoot
Messages: 21818
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Try to create a SYNONYM and use it withing the form (instead of a database link).
Re: Form Closes While Compiling [message #466575 is a reply to message #466564] Tue, 20 July 2010 03:32 Go to previous messageGo to next message
stalin4d
Messages: 226
Registered: May 2010
Location: Chennai, Tamil Nadu, Indi...
Senior Member
Are you saying to create a Synonym for a View?

Re: Form Closes While Compiling [message #466578 is a reply to message #466575] Tue, 20 July 2010 03:39 Go to previous messageGo to next message
cookiemonster
Messages: 13938
Registered: September 2008
Location: Rainy Manchester
Senior Member
That's right
Re: Form Closes While Compiling [message #466582 is a reply to message #466578] Tue, 20 July 2010 03:59 Go to previous messageGo to next message
stalin4d
Messages: 226
Registered: May 2010
Location: Chennai, Tamil Nadu, Indi...
Senior Member
ok sure
Re: Form Closes While Compiling [message #466586 is a reply to message #466564] Tue, 20 July 2010 04:08 Go to previous messageGo to next message
stalin4d
Messages: 226
Registered: May 2010
Location: Chennai, Tamil Nadu, Indi...
Senior Member
I have a doubt;
Then whats the purpose of using Database Links,
why it fails?

Re: Form Closes While Compiling [message #466592 is a reply to message #466586] Tue, 20 July 2010 04:31 Go to previous messageGo to next message
Littlefoot
Messages: 21818
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Without a database link, you can't access another database.
If you use a database link in a form PL/SQL program unit, you get an error.

Therefore, it seems that (in your version / combination of Forms Builder + Database + perhaps operating system) database link won't work.

So, you can either sit and cry over it, or try a workaround. One of these is a synonym. I don't know whether it will work or not - you'll tell us. If it still won't work, we'll try to figure something else.
Re: Form Closes While Compiling [message #466601 is a reply to message #466592] Tue, 20 July 2010 05:08 Go to previous messageGo to next message
stalin4d
Messages: 226
Registered: May 2010
Location: Chennai, Tamil Nadu, Indi...
Senior Member
yes, synonyms created and changed for the views used from other database, but problem arises still, form immly closes when compiled.

what might be the problem.
Re: Form Closes While Compiling [message #466603 is a reply to message #466601] Tue, 20 July 2010 05:15 Go to previous messageGo to next message
cookiemonster
Messages: 13938
Registered: September 2008
Location: Rainy Manchester
Senior Member
Can you create a view in your local db that selects from the view in the remote db?

I suspect it might be a dependencies problem - forms stores a list of everything it references in the db internally,
it might have problems with something that's not in the db it's connected to.
icon5.gif  Re: Form Closes While Compiling [message #466608 is a reply to message #466603] Tue, 20 July 2010 05:39 Go to previous messageGo to next message
stalin4d
Messages: 226
Registered: May 2010
Location: Chennai, Tamil Nadu, Indi...
Senior Member
yes there is already a view Named 'MR_HEAD' in the local database which was created from the table 'MR_HEAD' of the other database.

Are you saying to create another view from the local database's same view(MR_HEAD)?

Sad

REMOTE DATABASE TABLE(MR_HEAD) --> LOCAL DATABASE VIEW(MR_HEAD)-->
LOCAL DATABASE VIEW(Some other name from this Local View) ?

[Updated on: Tue, 20 July 2010 05:45]

Report message to a moderator

Re: Form Closes While Compiling [message #466611 is a reply to message #466608] Tue, 20 July 2010 06:11 Go to previous messageGo to next message
cookiemonster
Messages: 13938
Registered: September 2008
Location: Rainy Manchester
Senior Member
If the view is in the local db why are you doing this:
Quote:

so after using this in my form as 'INMATMAS.mr_head@DB_OPTIMAT'

Re: Form Closes While Compiling [message #466616 is a reply to message #466611] Tue, 20 July 2010 06:37 Go to previous messageGo to next message
stalin4d
Messages: 226
Registered: May 2010
Location: Chennai, Tamil Nadu, Indi...
Senior Member
Its not working even the View is the local Database.

while running the view in a PL/SQL Developer(tool) it fetches the data but applying that view in form wont works.

so i tried Quote:
' INMATMAS.mr_head@DB_OPTIMAT'[/email]


[Updated on: Tue, 20 July 2010 06:43]

Report message to a moderator

Re: Form Closes While Compiling [message #466628 is a reply to message #466616] Tue, 20 July 2010 07:03 Go to previous messageGo to next message
cookiemonster
Messages: 13938
Registered: September 2008
Location: Rainy Manchester
Senior Member
Are you basing blocks on the view or just referencing it in PL/SQL in triggers/procedures?
Re: Form Closes While Compiling [message #466987 is a reply to message #466628] Wed, 21 July 2010 22:30 Go to previous messageGo to next message
stalin4d
Messages: 226
Registered: May 2010
Location: Chennai, Tamil Nadu, Indi...
Senior Member
Yes basing blocks on the view
Re: Form Closes While Compiling [message #467053 is a reply to message #466987] Thu, 22 July 2010 02:46 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
What version of Forms are you using? Look at "Patching Lifecycle / Strategy of Oracle Developer (Forms and Reports) [ID 266541.1]" in Metalink to get the release number that you are using.

David
Re: Form Closes While Compiling [message #468123 is a reply to message #467053] Thu, 29 July 2010 00:28 Go to previous message
stalin4d
Messages: 226
Registered: May 2010
Location: Chennai, Tamil Nadu, Indi...
Senior Member
Dear djmartin,

I don't have a Metalink Support id, what can I do?
Previous Topic: Error in view
Next Topic: Forms - POST Command
Goto Forum:
  


Current Time: Thu Sep 19 17:51:51 CDT 2024