Showing posts with label project. Show all posts
Showing posts with label project. Show all posts

Thursday, March 29, 2012

Direct Connection to Local SQL express gives error

I'm just starting out here.

I created a simple formview connected to a local file copy of the database by adding the database into the project. It worked fine.

However, I noticed that this copy of the database was not synch'ing with the database with the same name in SQL express. So I created a new connections string to access the SQL database directly out of SQL express. Its just a simple Select * from column. However, this gives an error. Why?

Server Error in '/NETCatMgr' Application.

The data types ntext and nvarchar are incompatible in the equal to operator.

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.SqlClient.SqlException: The data types ntext and nvarchar are incompatible in the equal to operator.

This is the connection string

<

addname="CatalogMgrConnectionString"connectionString="Data Source=mymachine\sqlexpress;Initial Catalog=CatalogSQL;Integrated Security=True"providerName="System.Data.SqlClient" />

Doesn't make sense. How can the formview work fine with the SQL integrated into the project but not working with a connection string to the SQL Express proper?


The error seems to be a data operation error other than a connection error. It indicates your code was trying to compare nvarchar value and ntext using "=" operator. Please make sure you choose proper data for comparation. To manipulate text/ntext/image data in SQL Server, you should use specific functions:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/tsqlref/ts_fa-fz_0gs3.asp

|||Its not me -- the problem appears to be some kind of bug in the GridView. The database column is a type nText and the GridView doesn't seem to be able to write code for SQL databases with column types nText. It writes the code with a string comparison and then it crashes... I didn't write any code at all.

Tuesday, March 27, 2012

Direct access of MDF file?

I am a project manager with a contractor that is very protective of
his programmer.
I've just received an alpha version of a program that appears to
access the .mdf file directly, maybe without a connection string. I
have not seen the source code yet.
I can picture a half dozen reasons not to do this mostly related to
server directory permissions, IT ownership, etc.
Is there any reason to do it? I'd like to do my homework before
telling the contractor to do what I tell him regardless of the cost.
Thanks in advance,
DennisWhat do you mean, "access the MDF file directly"? Why do you think the
program does this, if you haven't even seen the source code?
--
http://www.aspfaq.com/
(Reverse address to reply.)
"Hussman" <hussman_30@.hotmail.com> wrote in message
news:9c4bd326.0411160813.6865b58a@.posting.google.com...
> I am a project manager with a contractor that is very protective of
> his programmer.
> I've just received an alpha version of a program that appears to
> access the .mdf file directly, maybe without a connection string. I
> have not seen the source code yet.
> I can picture a half dozen reasons not to do this mostly related to
> server directory permissions, IT ownership, etc.
> Is there any reason to do it? I'd like to do my homework before
> telling the contractor to do what I tell him regardless of the cost.
> Thanks in advance,
> Dennis|||Not sure what you mean by direct access to an mdf file - the
only thing I can think of would be something possibly using
sp_attach_db, sp_detach_db.
-Sue
On 16 Nov 2004 08:13:20 -0800, hussman_30@.hotmail.com
(Hussman) wrote:
>I am a project manager with a contractor that is very protective of
>his programmer.
>I've just received an alpha version of a program that appears to
>access the .mdf file directly, maybe without a connection string. I
>have not seen the source code yet.
>I can picture a half dozen reasons not to do this mostly related to
>server directory permissions, IT ownership, etc.
>Is there any reason to do it? I'd like to do my homework before
>telling the contractor to do what I tell him regardless of the cost.
>Thanks in advance,
>Dennis|||Also, there's an option in the ODBC DSN for filenames to attach. Perhaps such an option also exists
in an ADO(.NET) connection string and this is used?
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Sue Hoegemeier" <Sue_H@.nomail.please> wrote in message
news:alakp0hh4da9ga6dkoskrbt3okbd5s0ec4@.4ax.com...
> Not sure what you mean by direct access to an mdf file - the
> only thing I can think of would be something possibly using
> sp_attach_db, sp_detach_db.
> -Sue
> On 16 Nov 2004 08:13:20 -0800, hussman_30@.hotmail.com
> (Hussman) wrote:
> >I am a project manager with a contractor that is very protective of
> >his programmer.
> >
> >I've just received an alpha version of a program that appears to
> >access the .mdf file directly, maybe without a connection string. I
> >have not seen the source code yet.
> >
> >I can picture a half dozen reasons not to do this mostly related to
> >server directory permissions, IT ownership, etc.
> >
> >Is there any reason to do it? I'd like to do my homework before
> >telling the contractor to do what I tell him regardless of the cost.
> >
> >Thanks in advance,
> >Dennis
>

Thursday, March 22, 2012

Dimension creation manually issue

I have created a new dimension manually from a project.But when I rebuild,deploy and process and view browser for that cube, I couldnt see the new dimension from the list of dimensions. Under what condition should the new dimension 'relates' to the cube?

Thanks.

Regards

Alu

You have to add it to your cube and then define right relationship between dimension and measure group|||

You do this in the dimension usage tab in the cube editor in BIDS.

Right click on the dimensions and choose add cube dimension

HTH

Thomas Ivarsson

|||

Thanks.

Regards

Alu