By "variable format" I mean that each row in the text file begins with a single character code denoting the record type, and each record type has a different format. I believe this is some sort of fairly common mainframe data export method. What makes matters worse is the fact that the record types are actually hierarchies. The codes in ...
I am using a Temporary table in Stored Procedure in SQL Server.
I am trying to use that SP in OLE DB Source Editor.
I can see the data output returned in the Query Builder that comes with Build Query button.
But when i Click the Columns tab, I am getting the below error.
Blockquote
- TITLE: Microsoft Visual Studio
Error at Da...
I am new to SQL Server 2008 database development.
Here I have a master table named ‘Student’ and a child table named ‘Address’. The common column between these tables is ‘Student ID’.
My doubts are:
Do we need to put ‘Address Id’ in the ‘Address’ table and make it primary key? Is it mandatory? ( I won’t be using this ‘Address Id’ i...
This is a follow up to my previous question, in t-sql
SELECT SCOPE_IDENTITY()
returns a BIGINT, I did the following to get it to return an INT:
DECLARE @X INT
INSERT ...
SELECT @X = SCOPE_IDENTITY()
-- if i don't include the line below, it will return a BIGINT
SELECT @X
Why does it return a BIGINT unless I do SELECT @X at the...
I have a table with 16 columns. It will be most frequently used table in web aplication and it will contain about few hundred tousand rows. Database is created on sql server 2008.
My question is choice for primary key. What is quicker? I can use complex primary key with two bigint-s or i can use one varchar value but i will need to con...
Hello everyone,
I am using VSTS 2008 + C# + ADO.Net + SQL Server 2008. My questions about what kinds of communication protocols SQL Server 2008 will be using, more details of my questions,
If the connection string looks like this, whether Named Pipe or TCP/IP is used? Will different communication protocol being used dependent on wheth...
Do you know?
PS: Some of you will tell me to check the Sql Server Management Studio features roadmap. But where is it?
...
I have this data as varchar '00072330'. How do I convert it to a decimal that looks like '723.30' in SQL Server 2008?
...
I have a table (table 1) with couple of column on which i want indexed.
There is also ArticleID column (foreign key), with this id I want to use join to retrieve "articleTitle" from the article Table (table 2), and of curse be able to search in this column.
How do I create this kind of index?
Do I need to index both tables?
and how shou...
I've setup a local cache of data in my ASP.NET app. I've got the app reading/writing to the local SDF file using the Entity framework.
When I issue the sync command:
DataCacheSyncAgent syncAgent = new DataCacheSyncAgent();
Microsoft.Synchronization.Data.SyncStatistics syncStats = syncAgent.Synchronize();
The sync agent pulls down al...
I can connect to my sql server 2008 developer server using this in a sample code project:
string connection = @"data source=.\SQLSERVER2008;Integrated Security=SSPI;Initial Catalog=RSINET.MVC";
When I try updating the web.config file like so, I get a sql exception:
<add name="ApplicationServices" connectionString="data source=.\SQLS...
I have the following problem:
Suppose I have a table with the following fields:
[ID]
[Start Date]
[Status Date]
[Status Description]
[ID] is not unique, and so I may have:
ID Start Date Status Date Status
123 01/01/2009 01/01/2009 Start
123 01/01/2009 01/02/2009 Change
123 01/01/2009 01/03/2009 Change
123 01/01/2009...
If I use OnError event handler in my SSIS package, there are variables System::ErrorCode and System::ErrorDescription from which I can get the error information if any things fails while execution.
But I cant the find the same for OnTaskFailed event handler, i.e. How to get the ErrorCode and ErrorDescription from the OnTaskFailed event ...
What is the difference between:
CREATE TABLE #temp ( [ID] INT)
INSERT INTO #temp
SELECT ...
and
DECLARE @temp TABLE ( [ID] INT)
INSERT @temp
SELECT ...
in SQL Server 2008?
...
I am reading a book on SQL and it gives me scripts to run to create a database. But I have only SQL Express 10, which doesn't look like has tools to run SQL commands. Is there any way to run the scripts?
...
What I want to do is simulate right clicking a stored procedure an selecting Modify, then execute so that my stored procedure runs.
Some of the tables in our database have changed and not all the sp's have been modified.
ie old SP =
ALTER PROCEDURE [dbo].[myProcedure]
SELECT name, address, typename from names
GO
Then the names tabl...
Hello!
SQL Server 2008
Using all the correct references I dare say:
System.Data.SqlClient;
Microsoft.SqlServer.Management.Smo;
Microsoft.SqlServer.Management.Common;
Microsoft.SqlServer.Management.Sdk.Sfc;
All compiles with no errors.
I have stripped code down to almost zero for easy debugging.
Connecting to server alright and so o...
I have done some research online but i cant seem to find a proper answer.
I am trying to restore a SQL server 2008 backup onto a sql express 2008 system (Live environment backup to Development environment)
The problem is i keep getting a "SQL Server cannot process this media family" error code 3241.
Any ideas???
Thanks
...
Hey guys,
I am building a suggestive tagging system (sounds seedy), I pass in a string to the db and if there is a match it sends back that tag. I want to stop duplicate tags, so if one tag is WEB, I only want it to be returned once. So if I had WEB as a tag and then add WEEKLY, typing "WE" doesn't bring up WEB for a second time as a s...
I'm writing an app in .NET, and using a dropdown checkbox.
I'm not sure what the best practice is for storing this info in the db.
Currently I'm writing back a comma delimited string to an SP in SQL Server 2008 ie "apple, banana, pear", storing this in a nvarchar(MAX) and then splitting this in the SP into another table holding the ID ...