Ora-12052 on creating MV via DB-link
Hello,
I am new to materialized views and database links. So I started trying with both of them.
A lot of things worked by searching in the internet. This one despite causes trouble:
I am trying to create a materialized view by using a database link which connects two databases.
The link is established and I am able to create the mv for a single mastertable by using the options 'fast' and 'on demand'.
Now I am facing the problem, that i have to select from several tables.
Oracle answers with the error Ora-12052 and tells me, that there is a hurdle with row-ids or an outer join.
In my layout are neither row-ids used nor I am using an outer join in my statement.
The proposed solution by specifying 'force' or 'complete' doesn't fit in my case as it seems to me, because I am really in need of the fast option.
Can anyone tell me what's wrong?
Thanks in advance.
Oracle answers with the error Ora-12052 and tells me, that there is a hurdle with row-ids or an outer join.You haven't understood the error message. It says that you need to add either ROWIDs in the MV Definition or Join on Unique columns.
Generally, FAST refresh's require Primary Keys. In the absence of a PK, you have to add ROWID of each source table in the MV Definition.
Instead of "searching in the internet" you should use the standard Oracle Documentation.
Thus, you should see "General Restrictions on Fast Refresh" and "Restrictions on Fast Refresh on Materialized Views with Joins Only" at
http://download.oracle.com/docs/cd/B19306_01/server.102/b14223/basicmv.htm#sthref534
In fact, you should read the whole of that chapter and the rest of the documentation, instead of "searching the internet".
Similar Messages
-
ORA-12052 when create materialized view
I following the sample in Oracle document to create materialized viewCREATE MATERIALIZED VIEW LOG ON sales
WITH ROWID, SEQUENCE(amount_sold, time_id, prod_id) INCLUDING NEW VALUES;
CREATE MATERIALIZED VIEW LOG ON times
WITH ROWID, SEQUENCE (time_id, calendar_year) INCLUDING NEW VALUES;
CREATE MATERIALIZED VIEW LOG ON products
WITH ROWID, SEQUENCE (prod_id,prod_name) INCLUDING NEW VALUES;
CREATE MATERIALIZED VIEW sales_mv
BUILD IMMEDIATE REFRESH FAST ON COMMIT
AS SELECT t.calendar_year, p.prod_id, p.prod_name,
SUM(s.amount_sold) AS sum_sales
FROM times t, products p, sales s
WHERE t.time_id = s.time_id AND p.prod_id = s.prod_id
GROUP BY t.calendar_year, p.prod_id, p.prod_name; This works. BUt I actually does not want do aggregation. Thus I changed the MV creation statement toCREATE MATERIALIZED VIEW sales_mv
BUILD IMMEDIATE REFRESH FAST ON COMMIT
AS SELECT t.calendar_year, p.prod_id, p.prod_name,s.amount_sold
FROM times t, products p, sales s
WHERE t.time_id = s.time_id AND p.prod_id = s.prod_id;I got errorSQL Error: ORA-12052: cannot fast refresh materialized view GLU.SALES_MV
*Cause: Either ROWIDs of certain tables were missing in the definition or
the inner table of an outer join did not have UNIQUE constraints on
join columns.
*Action: Specify the FORCE or COMPLETE option. If this error is got
during creation, the materialized view definition may have be
changed. Refer to the documentation on materialized views.Please help or point me to the relevant document.
Thanksdamorgan, Thank you for you reply.
the inner table of an outer join did not have UNIQUE constraints on join columns.
I am not sure how much clearer and explanation can be written.If you look at the query, you will find that there is no outer join in the query.
sales table does not have unique constraints on prod_id and time_id. If this is the cause of the problem, I cannot change the data but is there a work around. That is way I ask for specific doc. In 11g documents, I only find some info on CREATE MV. That is mainly on syntax but not on requirement. -
Creating variable via looped link
i am sending a url with a variable that is a modified series
of variables
sublnk=SECID=2*SECTSUBID=2*SECTSUB1ID=90
i replaced the "&" with "*" because it is a sub variable
in url string (i.e) sublnk=#sublnk#...? (please don't ask)
anyway when i get to the display page i need to split up and
make variables of SECID, SECTSUBID, SECTSUB1ID
I tried a list loop:
<cfloop index="catzzz" list="#sublnk#" delimiters="*">
<cfset #catzzz#>
</cfloop>
what i want is:
<cfset SECID=2>, etc.
does not work.... ????
tnx in advanceksmith,
your code worked great but i modified a little to take remove
some of the functions... see below.
one thing i don't understand is how the variable can be read
without making it dynamic with # sign as in
<cfset "#varName#" = varVal>
the variable "varVal" is dynamic.... it works but i don't get
it. please explain.
way thanks.... -
Error not getting while executing procedure via db link
Hi,
I am executing a database procedure remotely via database link from SQL prompt (SQL > EXECUTE REPLICATE_DATA@DBLK_SALE), and while getting any connectivity issue system is not giving any error (it is just showing as not responding)..
if I am executing the same procedure directly in the remote database then it is giving error as
ORA-02055: distributed update operation failed; rollback required
ORA-02068: following severe error from DBLK_SALE
ORA-03135: connection lost contact
Can someone can help me on this
RegardsDear 823755,
You can think the Database link as a new sqlplus session to the distributed database. You should have defined a user to connect to that remote database and the user has to have the necessary privileges to revoke the relevant object. Does it have that privilege? Can you even connect to the remote database instance?
SQL> SELECT * FROM DUAL@DBLK_SALE;Regards.
Ogan -
I know how to use "navto" to jump to pages within the catalog created for our app.
We want to use the same article files to create a digital page turner using DPS but cannot figure out how to do it. Google searches lead to answers that say it isn't possible, but if i view a page turner I created in 3D Issue via Adobe's Content Viewer, the pages jump (via the links I made in 3D Issue).
I just can't believe that a huge company like Adobe has no way to do this in DPS.On pages you do not want to show-up delselect "include page in navigation menu" in the page inspector:
-
Sharing an imported PDF via a link
I uploaded/imported an AcroForm to my FormCentral (FC) account, added the submit button in FC and now I'd like to share a link to the file for users to access the form, vs me having to send them a the Submission-Enabled PDF version that I downloaded.
I thought there was a way to share the PDF via a link, however, the "copy fillable form link" button is greyed out. My understanding is that the form that I uploaded to my FC account is hosted on the Adobe server, so why can't I generate a link that I can have others point to - to access the form? Or is the option to share direct links to the form ONLY for Web/HTML forms created within FC?
Please advise.Hi;
The Import AcroForm feature allows you to use a form you have already authored, not requiring you to re-author in FormsCentral, to collect your data in FormsCentral and access features like Submission Reciepts, Notifications and the reporting available allowing you to share access to the responses etc. The Imported PDF does not create an HTML fillable form and does not provide any URL to the form.
You can host your form on a website and create a link to download the PDF from there rather than attaching the PDF to email, but there is no URL provided by FormsCentral. How complex is your form? Could you re-create it using our authoring?
Thanks,
Josh -
Problems with query via Database-Link (Oracle 7.3.4)
I made the following simple query via database-link.
select count (*) from [email protected]
I got the result in about 200 miliseconds.
Then I4ve tried the following query.
select * from [email protected]
It took about 2 hours end ended with an error message "ORA-03113: end-of-file on communication channel"
So I made another choice
select * from [email protected] where rownum <=1
Took about 200 miliseconds.
So I made the query again an changed only the number of rownums,until I was at rownum <=8
then it went sleeping again(I've canceled the statement because I didn't want to wait 2 hours again).
We made the same things from another server with the same database-link on the same remote server
and we had no problems.
Any Idea???No, network is OK!
Other links are running, I have also no problems when I connect directly to the remote server. -
Materialized view issue ORA-12052
Hi All,
I'm currently trying to create a MV using Fast refresh method.
and I'm getting the following error:
ORA-12052:
cannot fast refresh materialized view string.string
Cause: Either ROWIDs of certain tables were missing in the definition or the inner table of an outer join did not have UNIQUE constraints on join columns.
Action: Specify the FORCE or COMPLETE option. If this error is got during creation, the materialized view definition may have be changed. Refer to the documentation on materialized views.
I'm trying to create the Unique constraints required. Could anybody help me with this?. Which are the "inner tables of an outer join"?
I have also created the MVs logs with rowid, but also nothing happend.
I' ve created a Unique constraint that includes all the fields of the ourter joins. Nothing happend either.
Thi is the MV script:
'CREATE MATERIALIZED VIEW MVIEW1
USING INDEX
REFRESH ON DEMAND FAST
WITH rowid
DISABLE QUERY REWRITE AS
SELECT fp.FINAL_AMOUNTFIXED,
fp.FINAL_FPRATE,
fp.updated_rate,
fp.gsd_rate,
fp.nongsd_rate,
fp.AMT_CD,
fp.AMT_CD_ADJ1,
fp.AMT_CD_ADJ2,
fp.AMT_LC,
fp.AMT_LC_ADJ1,
fp.AMT_LC_ADJ2,
fp.ASSIGNMENT_STATUS,
fp.CURRENCY,
fp.DOLLARS,
fp.FORECAST_REVENUE_STATUS,
fp.GUID,
NVL(fp.HOURS,0) HOURS,
fp.ID,
fp.JOB_LEVEL,
fp.PJR_AMT_CD,
fp.PJR_HOURS_VALUE,
fp.PJR_LC,
fp.PJR_RATE,
fp.PJR_RATE_VALUE,
fp.PROJECT_COST_CENTER,
fp.PROJECT_COST_CENTERTXT,
NVL(cust.project_manager,fp.project_manager) project_manager,
NVL(cust.project_name,fp.project_name) project_name,
fp.PROJECT_NUMBER,
fp.PROJECT_ORGANIZATION,
NVL(cust.project_status,fp.project_status) project_status,
NVL(cust.project_type,fp.project_type) project_type,
NVL(fp.RATE,0) Rate,
fp.RATE_ADJ1,
fp.RATE_ADJ2,
fp.RATE_LEVEL,
fp.REPORT_DATE_ID,
fp.REPORT_DESCRIPTION,
fp.RESOURCE_COST_CENTER,
fp.RESOURCE_COST_CENTERTXT,
fp.RESOURCE_COUNTRY,
fp.RESOURCE_NAME,
fp.RESOURCE_ORGANIZATION,
fp.RESOURCE_TYPE,
fp.REVENUECOST_TYPE,
fp.ROLE_END_DATE,
fp.ROLE_NAME,
fp.ROLE_START_DATE,
fp.TAB,
fp.TASK_NUMBER,
fp.TPRATE_TP,
fp.WAR,
fp.WE_DATE_ID,
fp.WEEK,
fp.WORK_TYPE,
fp.PJR_FF_DIFF_MONTH,
fp.PJR_FF_DIFF_QTR,
NVL(fp.PJR_WOW,0) WOW,
fp.PJR_WOW_HRS,
fp.REMOVED_BY_ADJUSTMENT,
fp.PICK_FOR_WRITEBACK,
fp.DRAFT_REV_NUM,
fp.DRAFT_INV_NUM,
NVL(pca.country,fp.PROJECT_COUNTRY) Country,
NVL(cust.customer_id,NVL(fp.CUSTOMER_NUMBER,'TBD')) Customer_ID,
NVL(cust.CUSTOMER_NAME,NVL(fp.CUSTOMER_NAME,'TBD')) Customer_Name ,
fp.ITEM_DATE,
fp.REVENUE_CC,
fp.EXPLANATION,
fp.REPORT,
fp.REPORT_ADJUSTMENT,
fp.REPORT_ADJ1,
fp.REPORT_ADJ2,
fp.JE_DESCRIPTION,
pca.REGION_HQ_TIERLAST_CODE,
pca.MANAGER_FIELD_TIERLAST_CODE,
pca.SPECIALTY_HQ_TIERLAST_CODE,
pca.SECTOR_HQ_TIERLAST_CODE,
rca.REGION_HQ_TIERLAST_CODE,
rca.MANAGER_FIELD_TIERLAST_CODE,
rca.SPECIALTY_HQ_TIERLAST_CODE,
rca.SECTOR_HQ_TIERLAST_CODE,
pca.VERTICALS_SUB_LOB,
pca.MISC_GROUP ,
rca.VERTICALS_SUB_LOB,
rca.MISC_GROUP ,
fp.gl_date,
fp.pjr_wow_rate ,
fp.created_by,
fp.created_on,
NVL(fp.TOTAL_FUNDING,0) TOTAL_FUNDING,
NVL(fp.INCEPTION_TO_BURN,0) INCEPTION_TO_BURN,
NVL(fp.AVAILABLE_FUNDING,0) AVAILABLE_FUNDING,
NVL(fp.FORECAST_AMT,0) FORECAST_AMT,
cust.pop_date,
fp.COMMENTS_WOW_PROJ,
fp.COMMENTS_PAPER_CONFIRM,
rep.LOOKUP_CODE,
rep.NAC_SORTING1,
fp.ACTION_TO_CLOSE,
NVL(fp.NEGATIVE_BACKLOG,0) NEGATIVE_BACKLOG,
fp.SALES_REP,
fp.FORECAST_DATE,
pca.NAC_RES_TYPE_3,
rca.NAC_RES_TYPE_3
FROM FACT_PJR fp,
COSTCENTER_ATTRIBUTES pca ,
COSTCENTER_ATTRIBUTES rca,
wb_customer_lookups cust,
XXAPX_LOOKUPS rep
WHERE fp.revenue_cc = pca.LEAF_CC(+)
AND fp.RESOURCE_COST_CENTER = rca.LEAF_CC(+)
AND fp.project_number = cust.project_number(+)
AND fp.REPORT_ADJ2 = rep.VALUE(+)
AND rep.LOOKUP_TYPE = 'NAC_WB_PHASE2';'
Edited by: 859267 on May 3, 2012 11:51 AMPlease edit your post and surround the code with code tags. See 'Are there any useful formatting options not shown on the sidebar?' in the FAQ.
Also provide your 4 digit Oracle version (result of SELECT * FROM V$VERSION). -
Webi - Pass Hierarchy Filter via Document Link
Hi
I am creating WEBI reports on BO 4.0 SP2 patch 8.
I want to pass the parameters from Webi report 1 via document link to Webi report 2.
Within report 1 you can filter the data by the following:
Parameter 1: Customer
Parameter 2: Calender Month
Parameter 3: Profit center Hierarchy
Parameter 1 & 2 work perfectly the selected customer and month passes to report 2.
However Parameter 3: hierarchy is giving me hassles.
I enter the Hierarchy into the document prompt text and key in editing the document link.
On selecting the hyperlink I get the error message:
" Invalid answer 0HIER [ ] for variable ZPCTR_GRP error message WIS 00013."
Has anybody been able to pass a filtered Hierarchy via Document Links on BO 4.0?
Regards
GrahamHi,
I haven't seen this particular issue come through support.
the warning seems to suggest that an invalid selection has been made, however the brackets [ ] show nothing! So perhaps the string's been provided in the wrong format, or text is being returned when infact it needs key. (i'm speculating)
a few questions to begin:
- Are you passing a hiearchy interval as a range parameter ? (i.e. 2 or more nodes/members from different levels in the hierarchy)
- Do you notice a difference when using the other viewer technology: DHTML (WEB) vs JAVA (Rich) ?
It might be worth using the TraceLog service on the webi processing server and DSL_bridge (APS) to capture your workflow, and get more details error messaging. Also, RSTT trace in BW may catch something of interest.
Good luck
Regards,
H -
Executing sql server procedure from oracle via db link with out parameters
HI
we have successfully created the link between oracle and sql server via DB LINK also able to access table from the
sqlserver via dblink
Can any one tell me how to execute procedure with 1 input and 4 out parameters from pl\sql
is it possible using
dbms_hs_passthroughYou should be able to call it like you would any other procedure:
dbo.procedure_name@dblink(parameter_list); -
Multi-Row insert/update/delete not working via db-link
App. Version: 2.0.0.00.49
DB: Oracle 9i, not sure about the build
Problem: Multirow Update/Insert/Delete doesn't work via db-link.
Error received: ....ORA-1460: unimplemented or unreasonable conversion requested....
Where: Tabular Form generated via Wizard
Side note: It's working properly when local table(s) is/are used, it's not working via db-link or view.
I've encountered this error with single update/insert/delete operations before, but was able to fix it via using temp-variables (v_xyz := :Px_xyz; as the proposed v('Px_xyz') was really slow with my scripts)...but with the automated DML-action I don't see a way to edit it accordingly.
Workaround found:
1a) Use local* collection on HTML-DB-Server, then write single row updates/deletes/inserts to the remote DB via DB-Link
1b) Use local* table on HTML-DB-Server, then write single row updates/deletes/inserts to the remote DB via DB-Link
* Local = on the same server that HTML-DB is running on...
So,...to my questions:
1. Can someone confirm that this is a "known feature" (aka bug)?
2. Can someone tell me if this "known feature" has been eliminated in the newer version of HTML-DB/APEX (> 2.0.0.00.49)?
Thanks.
IngoHi,
Do you have a small test case program that demonstrates this? A JDeveloper project showing what exactly is the problem when trying to use the BDB SQL JDBC driver to insert data into the BDB SQL database? What do you mean by "not working", do you get any errors, you do not get errors but you do not see the data in the database etc?
What are the versions of Java, JDeveloper, ADF and BDB SQL you are using, and on what OS?
Regards,
Andrei -
Create or Replace DB link command.
Hi all,
Ora 11.2.0.1 Windows Server 2003
Is there such a CREATE OR REPLACE DATABASE LINK command?
We have lots of Developement databases and our central TNSNAMES.ORA is constantly changing. This is because some database are decommissioned, or newly added, or migrated to other servers.
In this regard, I have a central monitoring database tool that creates dblink connecting to all the databases listed in the TNSNAMES.ORA.
So when there a new db added I will create new dblink. If there is decommissioned I will drop the dblink. If there is migrated I will create or replace db link.
How can I automate or manage this creation of database link but just by reading the TNSNAMES.ORA as input? Any bright ideas please.....
Please help....
Thanks a lot,
KinzHi;
you can create dblink than drop it and create it again.. There is no such a option like replace
You can create scritp which can parse tnsnames.ora and create or drop or recreate dblink by pasring tnsnames.ora
Regard
Helios -
Need help understanding the local caching of jnlp when creating it via jsp
I'm trying to deploy an app via Web Start. I have occasions when I need to pass arguments, so I'm using JSP to create the JNLP and optionally write arguments.
I need some help in figuring out how to cover my different use cases with as few different jnlps as possible and am confused about the local cacheing logic.
Use 1
Initial install: I pass an init=yes url param which writes a preferences file <argument> to be passed to my app. I don't want this argument cached in my jnlp, as this will overwrite the user's preferences on subsequent launches.
Use 2
Subsequent offline launches: no url params passed.
Use 3
Launch via html link (in a CMS): passes a file=<filename> url param which creates a file <argument> for my app to open. Again, I don't want this argument cached, otherwise launching from, say, the desktop shortcut will reopen this file.
Can anyone explain how best to cover these three use cases?
TIA!Did you solve this cache problem? I have a similar issue where I don't want it to use the arguments over again...
-
JDBC Thin driver doesn't support writing data into remote database via database link
Dear Oracle Guru:
Please confirm: Oracle JDBC thin driver does not support writing data to remote database via database link.
The following errors occur when trying to write data into a remote database via database link through jdbc thin driver:
ORA-03106: fatal two-task communication protocol error
ORA-02063: preceding line from FDBE.PAPDSRAS1
ORA-02063: preceding 2 lines from PA
SQL statement is a prepared statement using a SQL like: insert into mytable@pa (col1,col2) values (?,?).
Thanks.
nullThanks, Dan.
I still think it is a driver problem, because I can do similar things in a stored procedure or in PL/SQL Developer to copy records from a local database table to a remote database table via database link (insert into mytable@pa select * from mytable). The value for distributed_transactions of our database is 10. -
Change encore timeline from premiere pro cs5 via dynamic link?
I'm sure this has been covered before, but I can't find
anything on dynamic link in this forum.
I created my video in encore, and exported the sequence to encore via dynamic link.
I then created all my menus etc. in Encore, after which I noticed a couple of glitches I wanted to change, so I went back to premiere and edited the changes.
How do I get encore to pick up on these changes? It didn't happen automatically as I had hoped, and I don't want to have to recreate my menu structure again in Encore.
So, basically, how do I make a change in Premiere, and have it reflected in my Encore project without creating a new project?
thanks,
AndyI have a similar problem:
I created a project in PremPro CS5, then used Adobe Dynamic Link which loaded into Encore
where I created menus then saved off both PremPro and Encore.
Today I opened each to make add some titles in PremPro, however, Dyn Link did not send them to Encore
as I assumed it would. How do I get link to do what I have been lead to believe it will do, that is, carry
over changes from PremPro to Encore?
(I tried "Revert to Original" botton suggestion but Encore does not give me this option.
Seems like a strange suggestion since I want to update not revert.)
Details would be helpful.
Thx
Maybe you are looking for
-
How can i cancel a payment method
Didnt work they put for me:this payment method is declined try another one. I put but the same
-
Get Managed bean name while running tests.
hi, while running web application,i can able get managed name. but how to get managed bean name while running unit tests. thanks siva
-
Can a customer extend Messaging Server cryptographic capabilities?
One more question was brought up internally: is it possible to integrate Messaging Server and the related components with a third-party cryptographic software in order to extend SSL and Certificate authentication? There's certain development in JCP (
-
Where is the function show the double in the version 11?
Where is the function show the double in version 11
-
Cannot open new software program
I managed to successfully download a library cataloging program titled "Delicious Library 2," but when I go to open it, it refuses to open. I dragged the icon into the dock, but instead of the icon bouncing until the program opens, it only bounces on