Need Help With Error: Dimension Level Or It's Parent Is NULL

Apr 23, 2008

Hello,

I am getting this error when trying to open a report created with the cube. We use dundas olap chart to generate the xml for the report from the base cube or default perspective. What we do is change the xml dynamically to a different perspective for security purposes and then load the report. If the report xml accesses a dimension that is hidden the assigned perspective then we get the error shown below. Does anyone know how to handle this error?

Exception Details: System.NullReferenceException: Internal error. Dimension level or it's parent is NULL.

This only happens with some of our dimensions. With the other hidden dimensions we get no data message on the chart which is what we want.

I am comparing our dimensions to the Adventure Works cube dimensions which seem to work (I have not tried all of their dimensions yet). Nothing sticks out to me as being a setting that will make the error go way. Anyone have suggestions?

Other things I tried but didn't help were removing the parent child hierarchies and Role based security that uses one of the dimensions that throws the error. I also did a trace on the cube when the error is thrown. I could not see any errors and I was able to execute all of the MDX queries without any problems (I copied and pasted the mdx into SSMS).

As an aside we tried used the Cube Roles and Dimension security (Hiding measures in the Measures Dimension too) but the error that MS (#Error or #Value) throws causes dundas not to work. We also looked UDFs and Cell Level Security but both are more complex/what we need for now.


Thanks in advance,
Sean

View 10 Replies


ADVERTISEMENT

Error Processing Cube With Disabled Lowest Level Of Shared Dimension

Jul 23, 2005

Hi,This is probably a classic scenario with a shared dimension that weneed to use in different cubes, where all fact tables do not offer thesame level of detail. Dimension is snow-flaked.The cube that's causing me troubles was designed by marking the lowestdimension level Diabled and not Visible. This allows me to get rid ofone of the snow-flake tables (the one with the lowest level), thusallowing an INNER JOIN with the remaining table which has a level ofdetail corresponding to the fact table.When processing the cube, I get a 'member with key '[blah]' was foundin the fact table but was not found in the level '[blah]' of thedimension '[blah]'' that seems to indicate that none of my fact foreignkeys exist as primary keys in the dimension table. However if I thenattempt to query the cube, all data seems to be there.Would anybody be in a position (and willing ;-)) to share his/her ownexperience working around a similar issue?Thanks,SRL

View 2 Replies View Related

Parent ID In A Slowly Changing Dimension

Dec 7, 2006

Hi There,

Just wondering if any of you implemented a (Kimball type 2) dimension structure, in which a ParentID column exists which points to a record from the same dimension table, using a SCD objects in SSIS. The ParentID column would have to be "Historical".

The challange here is that you would need to go through the table twice somehow, because if I would do a lookup of the parent record in the first run, I wouldn't be sure if I got the right parent record.

Thnx, Jeroen.

View 13 Replies View Related

Analysis :: Parent Child Dimension Not Displaying Name Value

Apr 16, 2015

I have a parent Child attribute in my dimension.  It show the correct ID value in the reports but when I change the value from the NameColumn to be something else it still only shows the ID value. I have an identical case in another dimension and it is working correctly.  However this dimension for some reason does not seem to work and I believe they are built the same way I must be missing something.  I have tried to show the OrgNodeID and tried to display the OrgNodename but neither displays all it displays is the intdimParentOrgNodeID.My dimension table looks something like this

intdimOrgNodeID int Key (surreget key)
intOrgNodeID int (Actual ID)
intDimParentOrgNodeID
intOrgNodeName

[code]....

View 4 Replies View Related

Report Against Parent-child Referenced Dimension

Feb 20, 2008

Hello,

I want to create a report in SSRS against a cube in SSAS 2005.

I have a Sales fact table, a Products dimension which is related directly to the fact table, and a Categories dimension which is related to the fact through Products (referenced dimension).

Fact --> Products --> Categories

In the Categories dimension i have also implemented a parent-child hierarchy. Only leaf category members are joined to Products.

Is it possible to create a report, drilling down from parent categories to child categories to products?

I 've already implememted the categories parent-child report but when i add the Products dimension in the flattened rowset, the Products seem to be joined to non-leaf category members.

Thanks.

View 4 Replies View Related

Report Based On Parent-child Dimension

Feb 19, 2008

Hello,

I want to create a report based on an AdventureWordsAS parent-child dimension.

I created a new report item.
In the Data tab i created a new dataset using AnalysisServicesAS data source.
I dragged and dropped into the designer [Organization].[Organizations] and [Measures].[Financial Reporting].[Amount] from the metadata pane.

How can i configure a table control in the Layout tab, to create a drilldown report?
How do i set the Group On and Parent Group fields if i have only one attribute?

Thanks in advance

View 1 Replies View Related

Parent-Child-Dimension In SQL Srv 2005 Analysis Services

Jul 20, 2005

Hi experts,having a parent-child-table with the columns child_id, child_name, parent_idin SQL Server 2005 I just cannot create a parent-child dimension in BI DevStudio. Can anyone give me some hints? The Dim Build wizard doesn't createthe hierarchies, manually setting "parent" property to parent_id and "key"to child_id as well as dragging and dropping the stuff into the hierachyfield haven't just led to success. I also tried to right-click bothparent_id and child_id to create a member property. It just never workedout.Any help would be greatly appreciated.Kind regards,Joerg

View 1 Replies View Related

Creating Report Based On Parent-child Dimension

Nov 17, 2005

Hi

View 43 Replies View Related

Analysis :: How Time Dimension Aggregate Parent Child In MDX

May 21, 2015

I have a parent child dimension. a time dimension i have year.

Assume,

ParentID ChildID sales Year

171 171 10 2014
171 172 200 2014
171 173 300 2014
171 172 44 2015

if I pass 2014 and 2015 in sub select  171 data is not coming in result. i i pass only 2014 in sub select i get value of only 2014. if I pass 2015 in sub select i didn't get any value.                                                                         

View 2 Replies View Related

Aggregation Issue With Parent Child Dimension When Not Using Primary Key

Mar 10, 2006

When creating a parent child dimension I am not using the primary key of the underlying table. I define the key when I create the dimension. The parent/child relationship works fine but my measure aggregation does not work.

The dimension has a regular relation type to the measure and the primary key from the underlying dimension table is used in the relationship to join in the measure. Since I have not used the primary key in the dimension and have defined my own key the define relationship page warns me that I have selected a non-key granularity attribute and I must directly or indirectly relate all other attributes to it. When I attempt to relate the attributes on the dimension structure tab I receive errors that I have created an attribute loop.

Any ideas?

View 3 Replies View Related

Excel Export Report With Parent Child Dimension OLAP

Feb 6, 2008


Hi,

I have a problem with a reporting services 2005 report.
The data source is OLEDB for OLAP 9.


The report contains all the members of a parent child dimension. An example of the implementation is defined in the post following the forum msdn:
Http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=138549&SiteID=1.


The report works fine in web. The problem is when the report is exported as Excel, the groups disappeared and the entire dimension is ragged down.


Normally toggled groups in reporting services are exported to Excel with the appearance '+' or '-' on the left side of the sheet. This feature is very useful to hide / show lines.

It seems that with the implementation specified in the msdn post above,
It is not possible to export correctly the report in Excel.

So my questions are:

Has someone already encountered this problem?
Are there solutions with a different implementation?

Thanks,

Gurvan

View 2 Replies View Related

Analysis :: Include And Exclude Children In A Single Hierarchy In Parent Child Dimension In MDX

Apr 8, 2015

Include children and exclude children in a single  hierarchy in parent child dimension in mdx

*12-parent
 **20-parent
 - 9-parent
       --250-child1
       --210-child2
        --240-child3
aggregation of 12-parent only
aggregation of 20-parent only
aggregation of  9 with children

View 3 Replies View Related

Analysis :: How To Get Max Level Member Of A Dimension Without Mentioning

May 29, 2015

I am Using following MDX Query to get the data for max date in the Dimension. But every time I am passing date key to dimension to get data. How to automatically get the Max available Level member for that dimension.In this case I am passing 20150429 to every line instead i need to get that automatically.

SELECT 
(
{
[DimDate].[HierYQMD].[Date Key].&[20150429],
{[DimDate].[HierYQMD].[Date Key].&[20150429].PARENT.PARENT.PARENT.LAG(4):
[DimDate].[HierYQMD].[Date Key].&[20150429].PARENT.PARENT.PARENT},

[code]....

View 4 Replies View Related

Analysis :: Average Calculation On Leaf And Aggregate Parent Level And Above Using Averaged Value?

Sep 14, 2015

At the 2nd level, the calculated measure will only be correct if it is Averaged. And at the 1st level, the calculated measure will only be correct to take these Average value from 2nd level and Sum then up together. 

Level 1 Level 2
A    
X1
X2
=================
(Avg of X1 + X2)  
B
Y1
Y2
Y3
=================
(Avg of Y1 + Y2 + Y3)
===================================================
(Sum of (Avg of X1 + X2)  + (Avg of Y1 + Y2 + Y3) )

Currently, Instead of summing all the 3 averaged value, it is averaging against all the items like,

(Avg of X1 + X2 + Y1 + Y2 + Y3)

My MDX currently looks something like that 

[Measure].[Value] / [Dimension].[Attribute.count] -> so i can get the avarage at the 2nd level but it doesn't require on the 1st level but retaining this value.

How can i do an average on the leaf level and using these average values to sum at parent level?

View 4 Replies View Related

Analysis :: Count Function Taking More Time To Get Count From Parent Child Dimension?

May 25, 2015

below data,

Countery
parentid
CustomerSkId
sales

A
29097
29097
10

A
29465
29465
30

A
30492
30492
40

[code]....
 
Output

Countery
parentCount

A
8

B
3

c
3

in my count function,my code look like,

 set buyerset as exists(dimcustomer.leval02.allmembers,custoertypeisRetailers,"Sales")
set saleset(buyerset)
set custdimensionfilter as {custdimensionmemb1,custdimensionmemb2,custdimensionmemb3,custdimensionmemb4}
set finalset as exists(salest,custdimensionfilter,"Sales")
Set ProdIP as dimproduct.dimproduct.prod1
set Othersset as (cyears,ProdIP)
(exists(([FINALSET],Othersset,dimension2.dimension2.item3),[DimCustomerBuyer].[ParentPostalCode].currentmember, "factsales")).count

it will take 12 to 15 min to execute.

View 3 Replies View Related

NULL Values In Cube Dimension

Apr 16, 2004

I have a fact table with a simple integer lookup key into a basic dimension table. However, some of the fact lookup key fields are NULL. I would like the Analaysis Services reports to show this NULL category. Instead, Analysis Services discards any NULL entries and the records are completely absent from the reports. What is the best way to achieve this?

Thank you!

View 2 Replies View Related

Analysis :: If Parent Is NULL But Child Have Transaction Will Not Come In MDX Query

Oct 15, 2015

I have parent child dimension,

for customer id-101
---------H1-p  Sales Value-50
---c1-c  Sales Value-100
---c2-c Sales Value-200

If I will see H1 Value then it show =350

But when my head office is not exists for a customer but Child is exist i want to see data of child Aggregate value.

Example

for Customer ID-102
NO --H1 it is null
----c1 c sales Value -200
---c2 c Sales Value-50

When I want to see value of 102 at H1 leval it show me 250 . even H1 is  null.

View 3 Replies View Related

Analysis :: Add Dimension To Cube Dimension Without Any Relation In Dimension Usage

Oct 26, 2015

When i add a dimension to the cube dimension without any relation in my dimension usage to any measure group my units are going down.However when i remove the dimension from the cube am getting the correct values.

View 4 Replies View Related

Error Running Child Packages From Parent Package - Error 0xC0011008

Mar 31, 2008



Hey...

I am running a parent SSIS package (running sp2, 9.0.3042) that calls several child packages.

On our development server, we now cannot run this because we get 1 or more of these errors:

"Error 0x80004003 while preparing to load the package. Invalid pointer . "
"Error 0xC0011008 while preparing to load the package. Error loading from XML. No further detailed error information can be specified for this problem because no Events object was passed where detailed error information can be stored. . "

It is not occuring on the same packages. It varies every time it is run.

I can run every one of the child packages individually, using the same login ID that the parent is executed under.

The parent package works fine on my local machine and other servers running the same version of SSIS. Just not on this server.

Does anyone have any ideas???

Thanks

BobP

View 17 Replies View Related

Getting A Parent Key Error

Jun 19, 2008

i get a error message like this: Table RENTAL_ITEM in RENTALB23 does not have a matching parent key.

this is the sql:
CREATE TABLE RENTALB23/RENTAL_ITEM (RENTALITEM# INT PRIMARY KEY,
RENTALTYPE CHAR(3), TITLE CHAR(30), CATEGORY CHAR(15), DUEDATE DATE,
FOREIGN KEY(RENTALTYPE) REFERENCES
RENTALB23/RENTAL_CHARGE(RENTALTYPE), FOREIGN KEY(CATEGORY)
REFERENCES RENTALB23/RENTAL_CHARGE(CATEGORY))

this is the sql for the rental_charge table:
CREATE TABLE RENTALB23/RENTAL_CHARGE (RENTALTYPE CHAR(3),
CATEGORY CHAR(15), CHARGE DECIMAL(5,2), PRIMARY KEY(RENTALTYPE,
CATEGORY))

any ideas what can cause this?

View 4 Replies View Related

Parent Value Error When Trying To Use A 'where' In My Query.

Mar 28, 2008

I'm building a page that will display link categories with the links under each one.  I have that part working however there is a code issue that I cant quite figure out related to the SQL query.
I want to be able to have the category only display if the 'linkcolumn' is set to 1 in the database. (so I can later separate which ones show in each column of the page.
However, I get an error if I try to make my 'select' statement have a 'where' in it. I think it does this because it ends up not showing all the records but I'm not sure why.
Exception Details: System.ArgumentException: This constraint cannot be enabled as not all values have corresponding parent values.
My codebehind file:
using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Data.SqlClient;
using System.Data.Sql;using System.Data.SqlTypes;
public partial class Modules_NCG_NCGLinks : System.Web.UI.UserControl
{public void Page_Load(object sender, EventArgs e)
{
//Create the connection and DataAdapter for the Category table.SqlConnection cnn = new SqlConnection(ConfigurationManager.ConnectionStrings["mystringname"].ConnectionString);
SqlDataAdapter cmd1 = new SqlDataAdapter("select * from NCG_Links_Category Where LinkCategory = 'Test'",cnn);
//Create and fill the DataSet.DataSet ds = new DataSet();
cmd1.Fill(ds, "NCG_Links_Category");
//Create a second DataAdapter for the Links table.SqlDataAdapter cmd2 = new SqlDataAdapter("select * from NCG_Links",cnn);
cmd2.Fill(ds,"NCG_Links");
//Create the relation bewtween the Category and Links tables.ds.Relations.Add("myrelation",
ds.Tables["NCG_Links_Category"].Columns["LinkCategory"],ds.Tables["NCG_Links"].Columns["LinkCategory"]);
//Bind the Category table to the parent Repeater control, and call DataBind.parentRepeater.DataSource = ds.Tables["NCG_Links_Category"];
Page.DataBind();
//Close the connection.
cnn.Close();
}private void Page_Init(object sender, EventArgs e)
{
InitializeComponent();
}private void InitializeComponent()
{ this.Load += new System.EventHandler(this.Page_Load);
}
}
 

View 2 Replies View Related

Error Running Package From Parent

Nov 7, 2007

I am very new to SQL Server 2005, and I am currently trying to migrate a 2000 db to 2005.

I have now migrated all the DTS to SSIS, removing any legacy & replacing with new functionality.

I have been through a group of related packages ironing out any problems. They ALL now run fine when called individually.

However, I am now having problems with the parent package that is used to string these all together. It will not even run the 1st package.

For info, the first task of this package is a "Transfer SQL Server Objects Task". I am copying a few tables with data, but WITHOUT indexes, etc.

Following this, there is an "Execute SQL Task" that creates an index on one of those copied tables.

To get past another issue I had to set the "CopySchema" property of the "Transfer..." task to true, but did not select any schemas to transfer.

Now, when running the PARENT package, it is failing at the 1st step of the 1st package as follows:

Error: 0xC002F325 at Copy LT Data Tables, Transfer SQL Server Objects Task: Execution failed with the following error: "ERROR : errorCode=-1071636471 description=SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code: 0x80004005.
An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80004005 Description: "The statement has been terminated.".
An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80004005 Description: "Cannot insert duplicate key row in object 'dbo.Hidden Hearing Limited$Telemarketer' with unique index 'IX_Hidden Hearing Limited$Telemarketer1'.".
helpFile=dtsmsg.rll helpContext=0 idofInterfaceWithError={8BDFE893-E9D8-4D23-9739-DA807BCDC2AC}".

I have been searching and searching, finding similar problems, and even the same error codes, but nothing quite matching this particular scenario.

I have been trying to set the "DelayValidation" at various levels, but with no luck.

I would greatly appreciate any help in trying to resolve this. Has anyone else had the same, or similar, issue?

Many Thanks,
Simon

View 3 Replies View Related

Error Running Package From Parent

Nov 7, 2007

I am very new to SQL Server 2005, and I am currently trying to migrate a 2000 db to 2005.

I have now migrated all the DTS to SSIS, removing any legacy & replacing with new functionality.

I have been through a group of related packages ironing out any problems. They ALL now run fine when called individually.

However, I am now having problems with the parent package that is used to string these all together. It will not even run the 1st package.

For info, the first task of this package is a "Transfer SQL Server Objects Task". I am copying a few tables with data, but WITHOUT indexes, etc.

Following this, there is an "Execute SQL Task" that creates an index on one of those copied tables.

To get past another issue I had to set the "CopySchema" property of the "Transfer..." task to true, but did not select any schemas to transfer.

Now, when running the PARENT package, it is failing at the 1st step of the 1st package as follows:


Code BlockError: 0xC002F325 at Copy LT Data Tables, Transfer SQL Server Objects Task: Execution failed with the following error: "ERROR : errorCode=-1071636471 description=SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code: 0x80004005.An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80004005 Description: "The statement has been terminated.".An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80004005 Description: "Cannot insert duplicate key row in object 'dbo.Hidden Hearing Limited$Telemarketer' with unique index 'IX_Hidden Hearing Limited$Telemarketer1'.". helpFile=dtsmsg.rll helpContext=0 idofInterfaceWithError={8BDFE893-E9D8-4D23-9739-DA807BCDC2AC}".

I have been searching and searching, finding similar problems, and even the same error codes, but nothing quite matching this particular scenario.

I have been trying to set the "DelayValidation" at various levels, but with no luck.

I would greatly appreciate any help in trying to resolve this. Has anyone else had the same, or similar, issue?

Many Thanks,
Simon

View 15 Replies View Related

Parent Package Configuration Error

May 7, 2008

Hi,
I have a child package running under main parent pakage.
I am passing value of integer & string type variables from parent package to child package's variables ( as disscussed in following artical http://msdn.microsoft.com/en-us/library/ms345179(SQL.100).aspx) ,values assigned in child package variables are futher used to build connection string for flat file connection manager in child package.

I have been using this whole SSIS package sucessfully for last three months,but suddenly the following error arises

"OnError,,,,,,,The result of the expression



Code Snippet
"@[User::StrTextFileImpDirectory] +"SomeTextStringHere"+ @[User::StrANTTextFileName] +(DT_STR,30,1252) @[User::Staging_Date_Key]+ "SomeTextStringHere"

on property "ConnectionString" cannot be written to the property. The expression was evaluated, but cannot be set on the property."




When I see the result of above mentioned expression through Log file than it appears that my string variable



Code Snippet"@[User::StrTextFileImpDirectory]



in child package has not been populated with any value from parent package variable, I.e it has been populated with empty string(While this is not desired value).

Same problem arises with my integer type variable



Code Snippet@[User::Staging_Date_Key]


,it has ben populated with value zero (i.e default value at design time for integer type),while this is not desired value.


Can some one guide me how to figure out the cause for error....
Is it possible that such kind of error may arise due to any change in enviornment of server....

View 1 Replies View Related

Slowly Changing Dimension [58] Error

Sep 21, 2006

i am using SCD to insert or update .my source and destination table are Oracle and i am using Orcale OLEDB provider . i am getting the following error while executing the package.what could be the solution

[Slowly Changing Dimension [58]] Error: An OLE DB error has occurred. Error code: 0x80040E5D. An OLE DB record is available. Source: "Microsoft OLE DB Provider for Oracle" Hresult: 0x80040E5D Description: "Parameter name is unrecognized.".


Thanks

Jegan

View 3 Replies View Related

Analysis :: Dimension Error In SSMS

Sep 2, 2015

I AM GETTING THIS ERRORS, and even when i drag and drop calculated measures, it gives error as" query error" with RED mark..

View 4 Replies View Related

Analysis :: Dimension Processing Error

Mar 14, 2013

I'm getting this error during processing one dimension.OLE DB error: OLE DB or ODBC error: SQL Server blocked access to STATEMENT 'OpenRowset/ OpenDatasource' of component 'Ad Hoc Distributed Queries' because this component is turned off as part of the security configuration for this server. A system administrator can enable the use of 'Ad Hoc Distributed Queries' by using sp_configure. For more information about enabling 'Ad Hoc Distributed Queries', see "Surface Area Configuration" in SQL Server Books Online.; 42000.my dimension contains member from two datasource table.

and in another dimension i get error;Errors in the high-level relational engine. The 'dbo_vicidial_Users' table that is required for a join cannot be reached based on the relationships in the data source view.Errors in the OLAP storage engine: An error occurred while the dimension, with the ID of 'Staging User', Name of 'DimUsers' was being processed.

View 4 Replies View Related

Pass Back Error Count To Parent Pkg

Aug 29, 2007

I am trying to pass back the number of errors encountered by a child package to the Parent package. I have a script within the child package, which will set the value of the Parent package's variable (ChildErrCount). However, I have no idea how to access the Child package's Errors collection to get a count.

Any ideas? Has someone figured out a way to reference the current package's properties (besides what's available from Dts.* ?

Thanks!

View 11 Replies View Related

Activex Script - DTSGlobalVariables.Parent - Error

Sep 5, 2006

Hi,
I migrated DTS From sql server 2000 to 2005 .
But i have problemes with the ativex :

Error: 0xC0048006 at Loop action, ActiveX Script Task: Retrieving the file name for a component failed with error code 0x000F5544.

In DTS ActiveX scripting it was common to get a reference to the package itself using the following line of code:

Dim package = DTSGlobalVariables.Parent

This was used to navigate over the DTS object model , to loop.



Someone can help me to know haw I can do the same thing with the SSIS.

Regards,

View 3 Replies View Related

Error While Using A Slowly Changing Dimension Transformation

Jun 6, 2007

I have a SSIS package which contains a number of slowly changing dimension transformations. While the majority work I have one which gives me the following error 'Error: The variable "System::LocaleID" is already on the read list. A variable may only be added once to either the read lock list or the write lock list. '. This error only occurs if the destination table holds data. If I truncate the table and reload the data then the package complete successful. The only difference I can see between this dimension transformation and the other dimension transforms is that the one in question has 2 business keys while the rest have 1.



Can anyone shed light on this?



Thanks



View 3 Replies View Related

Get All Children Of A Parent If Present Or Parent Itself?

Nov 21, 2012

I have the below query which in turn goes in the where clause

Code:

SELECT CASE WHEN EXISTS (SELECT child.id FROM InspectionType parent,
InspectionType child WHERE parent.id = child.parentId AND
parent.code = 'INSPECTION_TYPE_SAFETY_LIFE' AND parent.zoneId = 10129)
THEN (SELECT child.id FROM InspectionType parent, InspectionType child
WHERE parent.id = child.parentId AND parent.code ='INSPECTION_TYPE_SAFETY_LIFE' AND parent.zoneId = 10129)
ELSE (SELECT id FROM InspectionType WHERE code = 'INSPECTION_TYPE_SAFETY_LIFE' AND zoneId = 10129)
END

I am getting below error

Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression.

I tried to solve this problem with If and else but it is not going well with in-clause

Code:
select * from InspectionType where id in (select IF EXISTS (SELECT child.id FROM InspectionType parent,
InspectionType child WHERE parent.id = child.parentId AND
parent.code = 'INSPECTION_TYPE_SAFETY_LIFE' AND parent.zoneId = 10129)
BEGIN (SELECT child.id FROM InspectionType parent, InspectionType child
WHERE parent.id = child.parentId AND parent.code ='INSPECTION_TYPE_SAFETY_LIFE' AND parent.zoneId = 10129)
END
ELSE (SELECT id FROM InspectionType WHERE code = 'INSPECTION_TYPE_SAFETY_LIFE' AND zoneId = 10129) )

I am using select * from InspectionType where id in() for illustation only. The sub-query results will go another query

Code:
SELECT child.id FROM InspectionType parent, InspectionType child
WHERE parent.id = child.parentId AND parent.code ='INSPECTION_TYPE_SAFETY_LIFE' AND parent.zoneId = 10129

This returns more than one row.I know why is the error message but need to achieve this functionality.

View 1 Replies View Related

OLEDB Command Stage Error In SLOWLY CHANGING DIMENSION

Jul 13, 2006

I have created a sample dataflow to parse the employee details (empid,empname,empaddr) from a flat file to oracle 9i database table named employee(columns : empid,empname,empaddress - All are varchar2(15)) using SLOWLY CHANGING DIMENSION transformation for insert/update on the table.

EMPID as Businees key

EMPNAME and EMPADDR as changing attributes.

Connection string is using Microsoft oledb provider for oracle.

I am getting the following oledb command error.

-----------------------------------------------------------------------------------

TITLE: Microsoft Visual Studio
------------------------------

Error at Data Flow Task [OLE DB Command 1 [2007]]: An OLE DB error has occurred. Error code: 0x80040E51.
An OLE DB record is available. Source: "Microsoft OLE DB Provider for Oracle" Hresult: 0x80040E51 Description: "Provider cannot derive parameter information and SetParameterInfo has not been called.".

Error at Data Flow Task [OLE DB Command 1 [2007]]: Unable to retrieve destination column descriptions from the parameters of the SQL command.

Warning at {CF5DCB64-279E-45A4-A9A8-FF2FBB130980} [Insert Destination [1972]]: Cannot retrieve the column code page info from the OLE DB provider. If the component supports the "DefaultCodePage" property, the code page from that property will be used. Change the value of the property if the current string code page values are incorrect. If the component does not support the property, the code page from the component's locale ID will be used.



------------------------------
ADDITIONAL INFORMATION:

Errors were encountered while generating the wizard results:
Error at Data Flow Task [OLE DB Command [1996]]: An OLE DB error has occurred. Error code: 0x80040E51.
An OLE DB record is available. Source: "Microsoft OLE DB Provider for Oracle" Hresult: 0x80040E51 Description: "Provider cannot derive parameter information and SetParameterInfo has not been called.".

Error at Data Flow Task [OLE DB Command [1996]]: Unable to retrieve destination column descriptions from the parameters of the SQL command.

Error at Data Flow Task [OLE DB Command 1 [2007]]: An OLE DB error has occurred. Error code: 0x80040E51.
An OLE DB record is available. Source: "Microsoft OLE DB Provider for Oracle" Hresult: 0x80040E51 Description: "Provider cannot derive parameter information and SetParameterInfo has not been called.".

Error at Data Flow Task [OLE DB Command 1 [2007]]: Unable to retrieve destination column descriptions from the parameters of the SQL command.



For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft%u00ae+Visual+Studio%u00ae+2005&ProdVer=8.0.50727.42&EvtSrc=Microsoft.DataTransformationServices.Design.SR&EvtID=ScdWizardGenerationErrors&LinkId=20476

------------------------------
BUTTONS:

OK
------------------------------

View 4 Replies View Related

Error On Starting SQL Express - Cannot Create A Stable Subkey Under A Volatile Parent Key.

Jan 8, 2007

Hi,



This error comes up immediately after opening:



Unhandled exception has occurred in a component in your application

If you click Continue, the application will ignore this error and attempt to

continue.



Cannot create a stable subkey under a volatile parent key.



It then provides a whole pile of (to the absolute beginner) mumbo-jumbo under a details button.



It does provide the option to continue, whereupon everything appears
normal; however, I consider this rather unwise at my very first opening
of Management Studio Express.



I have created a databse in VB Express (I have completed the Lesson 09
Video) dealing with databinding - I created the application etc with
the video to enhance my learning.



Should this affect it? It's the only database I have created.



This looks to me (my Express illiteracy intact, of course) like the
kind of message one would get after having an error in something
already created or in the process of being created.



What is this? I was going to begin the video tutorials for SQL, but not with this message.



I have only just installed the Express 'suite' a few days ago.



Please keep replies non-jargonistic - absolute beginner.



Fran...

View 5 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved