SetItemDataSources Keeps Telling Me The Data Source Cannot Be Found, But It's There... What's The Trick?
Apr 16, 2007
I have a custom folder layout for reporting services on our test environment so each tester can test the reports against the data in their own instances. The developers have reports in a different layout that's more in line with what will be in production. So I figured some simple RS scripting would handle things.
It was easy to create the folder structure, easy to create the shared data sources in each testers reports folders, and easy to deploy the report from the developers folder (source) to the testers report folders. However, when I try to use SetItemDataSources to change the data source in the newly duplicated reports, I keep getting an error telling me that the data source cannot be found.
Here's the relevant code fragment:
'Set report DataSource references
Dim DataSources(0) As DataSource
DataSources(0) = New DataSource
' update with new data source info
DataSources(0).Name = strDSName
Dim Item1 as DataSourceReference = New DataSourceReference
Item1.Reference = strRef
DataSources(0).Item = Item1
Console.WriteLine( "Setting report {0}, data source to {1}", strTargetReport, strRef)
RS.SetItemDataSources( strTargetReport, DataSources)
strDSName is "OLTP", strRef is the path to the shared data source, "/Reports/Tester1/Data Sources/OLTP". strTargetReport is the name of the report itself, full path name to "/Reports/Tester1/Report1".
Each tester has their own folder off the main reports folder "Reports", with an incremental number, as in "Tester1". Each testers folder has it's own Data Sources folder. There is only one data source for all reports, "OLTP".
/Reports
/Reports/Tester1
/Reports/Tester1/Data Sources
/Reports/Tester1/Data Sources/OLTP
/Reports/Tester1/Report1
/Reports/Tester1/Report2
I even went into SQL Server Management Studio and tried changing the (now broken) data source setting for a report to point to the correct data source (OLTP), then copied the generated script, then ran it - and still got the data source cannot be found error. That's what my latest code shown above was based on.
Anyone got any clues?
Thanks,
--Stan
View 3 Replies
ADVERTISEMENT
May 21, 2008
Hello,
Im developing an asp website, but im getting this error:
Code Snippet
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
/default.asp, line 76
I have 2 servers, the website is running from RACS-IIS-001, and the SQL server is from: RACS-SQL-001
I dont know if i use the wrong driver? im useing SQL Native Client
This is my connection string:
Code SnippetobjConn.Open "Driver={SQL Native Client}; Server=RACS-SQL-001; database=RentACar; uid=sa ; pwd=PASSWORD;"
Can anyone help?
View 4 Replies
View Related
Mar 12, 2007
I know this may be a simple problem, but here it is:
I have SQL server express installed on Windows 2003 server (Testing) it works fine;
When I move it to my production server (Windows 2003) I get the error message"Data source name not found and no default driver specified "
The system DSN in ODBC connections works fine, or at least completes the test ok.
My application is written in Classic ASP
PLEASE HELP
Thanks
View 2 Replies
View Related
Jul 31, 2007
I have this Stored Procedure:
Create PROCEDURE ListEventas If MONTH(GetDate()) <= 6 Begin SELECT EventTitle, EventDuration, (CASE WHEN MONTH(StartDate) = 1 THEN Datename(Day,StartDate) + ' - ' + Datename(Day,EndDate) ELSE '' END) AS 'Jan', (CASE WHEN MONTH(StartDate) = 2 THEN Datename(Day,StartDate) + ' - ' + Datename(Day,EndDate) ELSE '' END) AS 'Feb', (CASE WHEN MONTH(StartDate) = 3 THEN Datename(Day,StartDate) + ' - ' + Datename(Day,EndDate) ELSE '' END) AS 'Mar', (CASE WHEN MONTH(StartDate) = 4 THEN Datename(Day,StartDate) + ' - ' + Datename(Day,EndDate) ELSE '' END) AS 'Apr', (CASE WHEN MONTH(StartDate) = 5 THEN Datename(Day,StartDate) + ' - ' + Datename(Day,EndDate) ELSE '' END) AS 'May', (CASE WHEN MONTH(StartDate) = 6 THEN Datename(Day,StartDate) + ' - ' + Datename(Day,EndDate) ELSE '' END) AS 'Jun'FROM dbo.tblEvent INNER JOIN dbo.tbl ON (tblEvent.EventID = tblEventdate.EventID)WHERE YEAR(StartDate) = Year(GetDate())group by EventTitle, EventDuration,StartDate,EndDateEnd Else BeginSELECT EventTitle, EventDuration,(CASE WHEN MONTH(StartDate) = 7 THEN Datename(Day,StartDate) + ' - ' + Datename(Day,EndDate) ELSE '' END) AS 'Jul', (CASE WHEN MONTH(StartDate) = 8 THEN Datename(Day,StartDate) + ' - ' + Datename(Day,EndDate) ELSE '' END) AS 'Aug', (CASE WHEN MONTH(StartDate) = 9 THEN Datename(Day,StartDate) + ' - ' + Datename(Day,EndDate) ELSE '' END) AS 'Sep', (CASE WHEN MONTH(StartDate) = 10 THEN Datename(Day,StartDate) + ' - ' + Datename(Day,EndDate) ELSE '' END) AS 'Oct', (CASE WHEN MONTH(StartDate) = 11 THEN Datename(Day,StartDate) + ' - ' + Datename(Day,EndDate) ELSE '' END) AS 'Nov', (CASE WHEN MONTH(StartDate) = 12 THEN Datename(Day,StartDate) + ' - ' + Datename(Day,EndDate) ELSE '' END) AS 'Dec'FROM dbo.tblEvent INNER JOIN dbo.tbl ON (tblEvent.EventID = tblEventdate.EventID)WHERE YEAR(StartDate) = Year(GetDate())group by EventTitle, EventDuration,StartDate,EndDateEnd
When I execute it in the SQLExpress, the result returned as expected. But when I bind to Gridview I got this error:
A field or property with the name 'Jan' was not found on the selected data source.
How do I solve this?
I am using drag and drop SQLDatasource to call the Stored Proc and VB.net is the language. Thanks
View 4 Replies
View Related
Nov 26, 2007
I am testing an application that uses mysql that works 100% fine with Microsoft Windows XP on Windows Vista Premium Home Edition.
Using Vista's ODBC Data Source Administrator I have set up and successfuly tested the DSN Connection to the Database.
However, when I call the set up DSN with the application I get [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified.
I am using the mysql-connector-odbc-3.51.12-win32.
I have tried editing the registry DSN files - the problem still persists.
Does anybody know a way to solve this problem
View 1 Replies
View Related
Jan 18, 2007
I was working for 2 days on integrating reporting services with MOSS 2007.
The problem i faces was to create a data source for the
uploaded report (Not created using a wizard ) that will connect
me to the SQL server.
As i clicked on the arrow near the uploaded report to manage the data source, i found no
data source for this item.
I would be pleased to know the howto create this data source and where.
Best Regards,
Lana
View 4 Replies
View Related
Oct 30, 2006
ERROR [IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Data.Odbc.OdbcException: ERROR [IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specifiedSource Error: An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. Stack Trace: [OdbcException (0x80131937): ERROR [IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified]
System.Data.Odbc.OdbcConnection.HandleError(OdbcHandle hrHandle, RetCode retcode) +35
System.Data.Odbc.OdbcConnectionHandle..ctor(OdbcConnection connection, OdbcConnectionString constr, OdbcEnvironmentHandle environmentHandle) +131
System.Data.Odbc.OdbcConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningObject) +98
System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup) +27
System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection) +47
System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) +105
System.Data.Odbc.OdbcConnection.Open() +37
DBConnection.open() +12
ASP.global_asax.Session_Start(Object sender, EventArgs e) +35
System.Web.SessionState.SessionStateModule.RaiseOnStart(EventArgs e) +2163182
System.Web.SessionState.SessionStateModule.CompleteAcquireState() +154
System.Web.SessionState.SessionStateModule.BeginAcquireState(Object source, EventArgs e, AsyncCallback cb, Object extraData) +542
System.Web.AsyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +90
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +155
Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.42 ODBC version 3.526.1830.0strconn = "DSN=testserver;uid=tester;pwd=tester;DATABASE=Test_Database"I've Test_Database on 2 machines (same data in both machines), one is in SQL 2005 server and another one is in SQL 2000 server.When the website was published, it can't work. (with both database). But it work in debug mode in Visual Studio2005.The website can't work when use ODBC connection but it work when use SqlClient.Help me solve this problem please. T_T Thanks in advance,
View 8 Replies
View Related
Oct 19, 2006
trying to install sql server2005 on a windows 2003 server box.
getting msg below at the sql server . i looked at other posts on trying to uninstall SQL Native Access Client and norton antivirus. i could never find the snac on the add - remove programs and this server does not have a virus protection program yet.
here's the history of the installs on the server:
wanted to test a 2005 upgrade so:
1) installed sql server 2000 then sp4 then restored some databases to it - all OK
2) tried to upgrade to sql 2005 but ran into problems and left it at that.
had a disk drive crash on the d drive so lost the installs but not the operating system
when the drive was replaced, left alone for a while
then wanted to test a straight 2005 install
1) removed the broken 2005 attempt
2) removed the 2000
3) installed 2005 and got the error on the subject line:
TITLE: Microsoft SQL Server 2005 Setup
------------------------------
SQL Server Setup could not connect to the database service for server configuration. The error was: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified Refer to server error logs and setup logs for more information. For details on how to view setup logs, see "How to View Setup Log Files" in SQL Server Books Online.
i've gone through as many of the forums that i can and have tried several things - like uninstalling 2005 and installing pieces and parts but but nothing seems to work.
Thanks!
Dan <><
View 17 Replies
View Related
Feb 4, 2008
i am attempting to run phpbb using ms sql 2005 on the same box but get the following error during the setup
Could not connect to the database, see error message below.
[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
i am not sure yet if this is an issue with sql, php or phpbb
php is installed in iis and has all the modules installed which the php msi installer supported. i can run php code but in this case when i'm running the install.php file for the phphbb setup, i fill in the values for the database and got that error
phpbb detects all the required server settings and sees that i have ms sql installed
any suggestions on what that error means or how to go about configuring odbc driver?
probably a simple issue. but i'm still new with sql stuff
View 1 Replies
View Related
Dec 19, 2007
Bug:
An existing SSRS 2005 data source at the root directory cannot be used by the SSRS SetItemDataSource web method.
Steps to reproduce:
1. On the machine running SSRS 2005, create a folder named Reports and upload an RDL file named "Existing.rdl" into that directory. For clarity the SSRS path to this report is /Reports
2. Set up a valid data source at the root directory (For illustrative purposes we'll name it DS).
3. Set up a web reference to a SQL Server Reporting Web Services 2005. e.g. http://localhost/reportserver/reportservice2005.asmx
3. Try to set the DS data source to the "Existing" report by calling the SetItemDataSource web method.
C# Code Excerpt:
...
try{
ReportingService2005 reprtSrvc = new ReportingService2005();
DataSource[] dsarray;
string reportName = "Existing"
string _selectedFolder = "/Reports/"
DataSourceReference reference = new DataSourceReference();
DataSource ds = new DataSource();
dsarray = new DataSource[1];
reference.Reference = "/";
ds.Item = reference;
ds.Name = "DS";
dsarray[0] = ds;
//Exception thown ...
_reprtSrvc.SetItemDataSources("/" + _selectedFolder + reportName , dsarray);
}
catch (SoapException ex)
{
//Exception
Message.displayMessage(ex.Detail["Message"].InnerXml, MessageType.Error);
}
...
Exception details...
ex {"System.Web.Services.Protocols.SoapException: The operation you are attempting on item "" is not allowed for this item type. ---> Microsoft.ReportingServices.Diagnostics.Utilities.WrongItemTypeException: The operation you are attempting on item "" is not allowed for this item type. at Microsoft.ReportingServices.Library.SetItemDataSourcesAction.ResolveNewDataSources(DataSourceInfoCollection newDataSources, Boolean forModel) at Microsoft.ReportingServices.Library.SetItemDataSourcesAction.SetReportDataSources(CatalogItem item, DataSource[] dataSources) at Microsoft.ReportingServices.Library.SetItemDataSourcesAction.PerformActionNow() at Microsoft.ReportingServices.Library.RSSoapAction`1.Execute() at Microsoft.ReportingServices.WebServer.ReportingService2005Impl.SetItemDataSources(String Item, DataSource[] DataSources) --- End of inner exception stack trace --- at Microsoft.ReportingServices.WebServer.ReportingService2005Impl.SetItemDataSources(String Item, DataSource[] DataSources) at Microsoft.ReportingServices.WebServer.ReportingService2005.SetItemDataSources(String Item, DataSource[] DataSources)"} System.Web.Services.Protocols.SoapException
View 4 Replies
View Related
Dec 20, 2005
I have tried my best and not able to locate the source of this error.
The error logged in Event Viewer shows the source is from MSSQLServerOLAPService, but it is impacting the Reporting Services reports that use the Analysis Services as a data source to hang frequently.
Have anyone else encounter this and know what the Category 256 Event ID 22 means?
I am using SQL 2005 RTM MSAS and MSRS.
View 2 Replies
View Related
Oct 4, 2007
Good morning,
I have written a package which accepts variables for the server, initial catalog & table name.
I execute sql to drop the following stored procedure, then following sql statement to create it.
================================================================
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE procedure [dbo].[SP_CreateMatchProc]
@sTable varchar(300)
as
BEGIN
SET NOCOUNT ON
declare @cmd nvarchar(2000)
set @cmd = ''''
Set @cmd = 'SELECT REPLACE(field1 + field2 + field3 + field4 + field5, '' '', '''') AS dBString '
+ 'FROM ' + @sTable + ' ORDER BY <table>_ID COLLATE Latin1_General_CI_AS'
exec (@cmd)
END
GO
================================================================
Then in the Oledb source (validateexternalmetadata = false) I use "sqlcommand from variable" with a variable value of "SP_CreateMatchProc '<tableName>'"
The package runs fine in the IDE regardless of variable values, but when I created a batch file which calls dtexec I get a failure:
Error: 2007-10-04 08:46:42.82
Code: 0xC0202005
Source: Data Flow Task OLE DB Source [310]
Description: Column "dBString" cannot be found at the datasource.
End Error
Log:
Name: OnError
Start Time: 2007-10-04 08:46:42
End Time: 2007-10-04 08:46:42
End Log
Log:
Name: OnError
Start Time: 2007-10-04 08:46:42
End Time: 2007-10-04 08:46:42
End Log
Error: 2007-10-04 08:46:42.82
Code: 0xC004701A
Source: Data Flow Task DTS.Pipeline
Description: component "OLE DB Source" (310) failed the pre-execute phase and returned error code 0xC0202005.
End Error
with the ValidateExternalMetadata set to TRUE I get
Error: 2007-10-04 09:21:35.20
Code: 0xC004706B
Source: Data Flow Task DTS.Pipeline
Description: "component "OLE DB Source" (10621)" failed validation and returned validation status "VS_NEEDSNEWMETADATA".
End Error
the most notable thing I see there is that it looks like a different ID (310) with out the validation and (10621) with it.
Any help would be greatly appreciated.
View 8 Replies
View Related
Sep 2, 2015
I know what error 9002 is, but have found no single source documenting the state codes.
View 14 Replies
View Related
Mar 13, 2008
hi ,
i am trying for a drill through report (rdlc)
ihave written the following code in drill through event of reportviewer, whenever i click on the first report iam getting the error like
An error has occurred during report processing.
A data source instance has no
t been supplied for the data source "DetailDS_get_orderdetail".
the code is
using System;
using System.Data;
using System.Data.SqlClient;
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 Microsoft.ApplicationBlocks.Data;
using Microsoft.Reporting.WebForms;
using DAC;
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
ReportViewer1.Visible = false;
}
protected void Button1_Click(object sender, EventArgs e)
{
DAC.clsReportsWoman obj = new clsReportsWoman();
DataSet ds = new DataSet();
ds = obj.get_order();
ReportViewer1.LocalReport.DataSources.Clear();
ReportDataSource reds = new ReportDataSource("DataSet1_get_order", ds.Tables[0]);
ReportViewer1.LocalReport.DataSources.Add(reds);
ReportViewer1.LocalReport.ReportPath = "C:/Documents and Settings/km63096/My Documents/Visual Studio 2005/WebSites/drillthrurep/Report.rdlc";
ReportViewer1.LocalReport.Refresh();
ReportViewer1.Visible = true;
}
protected void ReportViewer1_Drillthrough(object sender, DrillthroughEventArgs e)
{
DAC.clsReportsWoman obj = new clsReportsWoman();
ReportParameterInfoCollection DrillThroughValues =
e.Report.GetParameters();
foreach (ReportParameterInfo d in DrillThroughValues)
{
Label1.Text = d.Values[0].ToString().Trim();
}
LocalReport localreport = (LocalReport)e.Report;
string order_id = Label1.Text;
DataSet ds = new DataSet();
ds = obj.get_orderdetail(order_id);
ReportViewer1.LocalReport.DataSources.Clear();
ReportDataSource reds = new ReportDataSource("DetailDS_get_orderdetail", ds.Tables[0]);
ReportViewer1.LocalReport.DataSources.Add(reds);
ReportViewer1.LocalReport.ReportPath = Server.MapPath(@"Reportlevel1.rdlc");
ReportViewer1.LocalReport.Refresh();
}
}
the code in method get_orderdetail(order_id) is
public DataSet get_orderdetail(string order_id)
{
SqlCommand cmd = new SqlCommand();
DataSet ds = new DataSet();
cmd.Parameters.Add("@order_id", SqlDbType.VarChar, 50);
cmd.Parameters["@order_id"].Value = order_id;
ds = SQLHelper.ExecuteAdapter(cmd, CommandType.StoredProcedure, "dbo.get_orderdetail");
return (ds);
}pls help me.
View 1 Replies
View Related
Sep 4, 2007
using windows xp with visual studio
once installed, how can you tell wh ichis installed:
Microsoft SQL Server 2005 Express Edition (SQLEXPR32.EXE)
Microsoft SQL Server 2005 Express Edition with Advanced Services (SQLEXPR_ADV.exe)
I have checked all the obvious.
Please advise.
Thanks,
Bob
View 1 Replies
View Related
Jan 8, 2008
I'm a long time user of sQL Server just getting started with SQL Server Express 2005 and I'm alittle confused about how to tell the difference between a SQL Server DB and an Express DB. I understand they both appear in SS Management Sudio. Actually I'm trying to create my first SQL Server Express database, and I'm not seeing any switches in the Create Database statement for specifying an Express database. Is there no difference between a regular and Express datbase?
View 2 Replies
View Related
Jul 23, 2005
I'm looking for a simple way of telling (inside a stored procedure) if I'mcurrently using MSDE or a full SQL server. Ideally, there is somepre-defined environment variable that won't cause me too much overhead. Thereason I'm doing this is because my system "rolls over" databases when itreaches the 2Gb limit with MSDE, but obviously I want to avoid this overheadif the user installs onto a full SQL server instance.ThanksRobin
View 5 Replies
View Related
Sep 8, 2007
Hi people - need help with a little thing on SQL...
I have a function that returns a table of values where one row is called 'UserID' - lets call this table 'x'
I have a another table with a row called 'UserID' in it - lets call this table 'y'
I want an SQL statement that achieves:
Select everything from table x (the table that was generated by the function) where the UserID is not in any row of table y.
Anyone think they can help?
Regards,
Will
View 3 Replies
View Related
Feb 17, 2007
Hi all...I would like to know how it is possible to make my problem below all in ONEquery or stored procedure.I select some rows from a table where the resultset is one column with somevalues. Lets say 1, 4 and 7:row val1 12 43 7Then I would like these results to manipulate another table together withanother value (lets say some 'b' with value 5)Lets say the other table looks like this:id a b text1 1 1 'Some text'2 1 3 'Some text'3 1 5 'Some text'4 4 5 'Some text'5 7 4 'Some text'6 2 5 'Some text'in the above example the rows with id 3 and 4 match my criteria because 1and 4 (and not 7) was in the column 'a' together with the value 5 in column'b'.Here comes the tricky part (at least for me):Now because a row without the 'a' value 7 and the 'b' value 5 existed in thetable I would like to create one row with those values.Also because the 'b' column did have a the value 5 (the row with id 6)without any of the 'a' values of 1, 4 and 7 (here 'a' is 2), that row shallbe deleted.Then at last I would like the resultset matching 'a' column of 1, 4 and 7AND 'b' column 5 as a resultset.I hope that it is understandable and someone can help.- rick -
View 1 Replies
View Related
May 13, 2008
Hi everyone...
I have the following records...
Delivery_Table
ID Description PartNumber
1 one 123
Parts_Table
ID PartNumber Margin Unit_Price
1 123 2.3 0.0
2 123 0.0 63.69
If I join these two tables based on PartNumber, it returns me two records. What I want is that I want to select one record only (IF Margin > 0, than it should take the Margin Record, Otherwise, it should take Unit_Price Record)
For example,
ID Description PartNumber Margin Unit_Price
1 one 123 2.3 0.0
OR
ID Description PartNumber Margin Unit_Price
1 one 123 0.0 63.69
Any clues?
View 1 Replies
View Related
Feb 2, 2008
,
Hi
In this code how can I create a new data source and new data source view and model and structure that it run dynamic.
In this code I have a lot of errors, that they are about server and database don€™t have in current code,
In this code, first I should definition server or no?
Database dbNew = new Database (databaseName,
Utils.GetSyntacticallyValidID(databaseName, typeof(Database)));
srv.Databases.Add(dbNew);
dbNew.Update(true);
***********************************************************
How can I create data source and data source view and model and structure?
Please say code of that, and guide me.
databasename and srv is unknown.
Do I add other reference with analysis services?
Please explain about these codes:
************************************************************************
1)
RelationalDataSource dsNew = new RelationalDataSource(
datasourceName,
Utils.GetSyntacticallyValidID(
datasourceName,
typeof(RelationalDataSource)));
db.DataSources.Add(dsNew);
dsNew.ConnectionString = connectionString;
dsNew.Update();
2)
RelationalDataSourceView rdsv;
rdsv = db.DataSourceViews.Add(
datasourceviewName,
Utils.GetSyntacticallyValidID(
datasourceviewName,
typeof(RelationalDataSourceView)));
rdsv.DataSourceID = ds.ID
***************************************************************
3)
OleDbConnection cn = new OleDbConnection(ds.ConnectionString);
OleDbCommand cmd = new OleDbCommand(
"SELECT * FROM [" + tableName + "] WHERE 0=1", cn);
OleDbDataAdapter ad = new OleDbDataAdapter(cmd);
DataSet dss = new DataSet();
ad.FillSchema(dss, SchemaType.Source);
*************************************************************
4)
// Make sure we have the name we thought
dss.Tables[0].TableName = tableName;
// Clone here - the original DataTable already belongs to a DataSet
rdsv.Schema.Tables.Add(dss.Tables[tableName].Clone());
rdsv.Update();
5)
MiningStructure ms = db.MiningStructures.Add(miningstructureName, Utils.GetSyntacticallyValidID(miningstructureName,
typeof(MiningStructure)));
ms.Source = new DataSourceViewBinding(dsv.ID);
ms.CaseTableName = "Customer";
Add columns:
ScalarMiningStructureColumn smsc;
// From table "Customer" we will add a couple of columns
// CustomerID - key
smsc = new ScalarMiningStructureColumn("Customer ID",
Utils.GetSyntacticallyValidID("Customer ID", typeof(ScalarMiningStructureColumn)));
smsc.IsKey = true;
smsc.Content = "Key";
smsc.KeyColumns.Add("Customer", "customer_id", OleDbType.Integer);
ms.Columns.Add(smsc);
*******************************************
6)
MiningModel mm = ms.MiningModels.Add(miningmodelName,
Utils.GetSyntacticallyValidID(miningmodelName,
typeof(MiningModel)));
mm.Algorithm = "Microsoft_Decision_Trees";
mm.Parameters.Add("COMPLEXITY_PENALTY", 0.3);
MiningModelColumn mc = new MiningModelColumn("Customer ID",
Utils.GetSyntacticallyValidID("CustomerID",
typeof(MiningModelColumn)));
mc.SourceColumnID = ms.Columns["Customer ID"].ID;
mc.Usage = "Key";
mm.Columns.Add(mc);
mm.Update();
Please exactly say, whatever I want
Thanks a lot for your answer
Please don€™t move this question because I don€™t know where I should write this.
View 1 Replies
View Related
Mar 2, 2007
I have set up a new connection as a connection from data source, but I cannot see how to use this connection to create my Data Flow Source. I have tried using an OLE DB connection, but this is painfully slow! The process of loading 10,000 rows takes 14 - 15 minutes. The same process in Access using SQL on a linked table via DSN takes 45 seconds.
Have I missed something in my set up of the OLE DB source / connection? Will a DSN source be faster?
Thanks in advance
ADG
View 2 Replies
View Related
Jul 2, 2007
Hi, I have another question about code in RS.
I have a table cell with FORMAT of "$#,##0,0".
If I have any number in the cell I want to display it.
If I have 0 (zero) I want the cell to be empty.
I know how to do it with an expression:
iif (Fileds!myFiled.Value == 0,"", Fileds!myFiled.Value)
Now I want to do it with a code section:
=Code.hideIfZero(Fileds!myFiled.Value)
The problem is that the function should return Integer and if the value is zero I need to return empty string.
It does't say any thing about returning the string but when it trying to use the format on a string it give me a worning and print #ERORR in the cell.
is there a solution for this?
Do you know the syntax to format the number in the function before the return?
(Sorry for the dumb question but I know C# not VB.net and there is no intelisance in that editor).
Thanks a lot!
View 3 Replies
View Related
Aug 11, 2002
Hi all. Here is a little trick I came up with the other day. Although a bunch of yu may have already thought of it, I thought I might share it.
I had a directory with about 30 .sql files in it (each one a Create Procedure statement). I needed to deploy all the files to a live database. Being the incredibly lazy person I am I didn't want to open up each file and run it.
So, I dropped into DOS, went to that directory and typed
type *.sql > newfile.sql
This created a new file that contained all of the other files, I could just run that file in query analyzer and I was done.
Give it a try!
Damian
View 6 Replies
View Related
May 8, 2007
hi everybody,
i want to create data source and data source view for data mining, with using C Sharp.
i have create data source and data source view and export to XML file, but when i change to another computer, run those XML file, it return error, when i run statement to create and biuld mining model, what can i change on xml or how to run XML on another computer sucessfully,
and have i build data source and data source view, how to do it.?
thanks for you helps
View 1 Replies
View Related
Dec 11, 2007
Today I was making a few reports.
When I tested the reports in Visual Studio, they worked great: I got the expected result.
But when I deployed the reports to our reportserver the problem started.
When I click on the directory in which my reports are deployed, I got my 4 reports.
Till now everything worked correct.
But when I click on a report to view the results it went wrong.
I got an error:
"Cannot create a connection to data source 'Live'"
(Live is the name of our data source).
We are using the Windows Logons and I am sure that I have all the rights on the server, I gave myself 'sysadmin' rights, so it should work.
I also have tried it with all the roles assigned on my account, but then it still won't work.
When I modify the data source, and set it to another server en database it works.
The datasource 'Live' exists on a x64 MsSQL server, en the other datasource is on a x86 MsSQL server.
Maybe that is the problem?
Can someone tell me what is wrong?
View 1 Replies
View Related
May 20, 2007
Hi there,
I'm trying to build a report for Windows Forms (C#) using .rdlc files.
But every time I run it, I get this error message. I've followed the step-by-step from MSDN instructions... but it doesn't work!
Could anyone help me?!
Tks a lot!
Luis Antonio - Brazil
View 1 Replies
View Related
Dec 13, 2007
I was trying to load data using SSIS, Data Flow Task, OLE DB Source, source was a view to a OLE DB Destination (SQL Server). This view returns 420,591 rows from Query Analyzer in 21 seconds. Row length is 925. When I try to executed the Data Flow Task from SSIS, I had to stop the process after 30 minutes, because only 2,000 rows had been retrieved. I modified the view to retun top 440, 000 and reran. This time all 420, 591 rows were retrieved and written in 22 seconds. Next, I tried to use a TOP 100 Percent. Again, only 2,000 rows were return after 30 minutes. TempDB is on a separate SAN Raid group with 200 gig free, Databases on a separate drive with 200 gig free. Server has 13 gig of memory and no other processes were executing.
The only way I could populate the table was by using an Execute SQL Task and hard code an Insert into table selecting data from the view (35 seconds) from SSIS.
Have anyone else experience this or a similar issue? Anyone have a solutionexplanation?
View 13 Replies
View Related
Mar 6, 2008
I have a table that looks like this:
RecordId
PictureId
KeywordId
111
212
313
421
522
623
725
817
932
1044
I need to run a query where I pass in an unknown number of KeywordIds that returns the PictureId. The 'IN' clause will not work because if a KeyWordId gets passed into the Stored Procudure the PictureId must have a record with each KeyWordId being passed in. For example, lets say you need to see the result of all PictureIds that have both 1 and 2, the correct result set should only be PictureId 1 and PictureId 2.
Im going crazy trying to find a simple solution for this. Please advise.
View 7 Replies
View Related
Sep 25, 2007
I'm a bit stumped at this. I have done this before a bunch of times. The difference is that this time I have two rectangles in the footer. For the each, the visibility is set to an expression which checks whether the page is page 1 or 2. If it is 1, the first rectangle is visible, if 2, the second. When I reference the hidden fields on the main area of the report via ReportItems, they come through fine on the first rectangle, but are invisible on the second. I've tried the same exact fields and every time they are visible in rectangle1, and invisible in rectangle2. What is going on here???
View 2 Replies
View Related
Aug 8, 2007
I'm trying to deploy a project that I deployed yesterday just fine, but today I get the following error:
------ Deploy started: Project: Point Reports, Configuration: Debug ------
Deploying to http://reporting.companyname.com/reportserver
Deploying data source '/Data Sources/Srv24.FieldResponse2_1'.
The permissions granted to user 'DOMAINharley.p.bartman' are insufficient for performing this operation.
Deploy complete -- 1 errors, 0 warnings
This seems like a basic permission issue, except I'm not logged in as the user listed! I've never logged into my computer as the user. I did log in to the reporting services website yesterday as that user, but since have rebooted my machine and logged into bothe my computer and the reporting services website as me. Yesterday this report deployed fine. Today, this error message. I've even tried creating a new project and just creating a simple datasource and deploying just that, but still this message! Where is Visual Studio storing and reusing this user name during my deploy process???
View 4 Replies
View Related
Nov 26, 2007
Hi there,
I am trying to use the new ListView control in VS2008 in an ASP.Net app. My problem starts already with the datasource. I drag and drop a SqlDataSource and select
Microsoft SQL Server Compact 3.5 (.NET Framework Data Provider for Microsoft SQL Server Compact 3.5)
I can connect to the database and test the query in the wizard (I do not need to use a password??)
This is the webconfig entry
<add name="ConnectionString" connectionString="Data Source=C:Program FilesMicrosoft SQL Server Compact Editionv3.5SamplesNorthwind.sdf" providerName="Microsoft.SqlServerCe.Client.3.5"/>
I add the following line in the page load event
AppDomain.CurrentDomain.SetData("SQLServerCompactEditionUnderWebHosting", true);
However I get the error message that the data provider cannot be found and it might not be installed. I added the reference and also gave the folder above ASP.NET full access rights.
Anyone else encountered this problem. It is quiet strange? Thanks a lot for your help.
Cheers,
Chris
View 2 Replies
View Related
Dec 20, 2004
I am trying to combine 2 tables, one is an event table, the other is a system table.
I would like to update field system.transaction with the first event.transaction
Where event.account = system.account
and event.effdt > system.effdt
and event.effdt <= system.effdt + 30
It's not really a join so I'm not sure how to write it.
Thanks,
Doug
View 2 Replies
View Related