I'm developing Reporting services on VS2005 and have to connect to SQLServer 2008.
The following Error occurs:
"This server version is not supported. You must have Microsoft SQLServer 2005 Beta 2 or later."
I found on the net a patch for it, but it doesn't work
(link to patch)
"The upgrade patch cannot be installed by the Windows Installer Service because the program to be upgraded is missing, or the upgrade patch may update a different version of the program."
what else can I do ? :(
Hi!
is it possible to install another IDE language to SQLServer 2008 Express like i can do in Visual Studio? In the options of Visual Studio, i can change the Environnement Language. Can i do the same with SQLServer 2008?
alex
Having a problem moving a site from Win2003 IIS6 w/ SQL2005 Express to a Win2008 IIS7 w/Fill SQL 2005? I keep getting this error
Desc : SQL Network Interfaces: Error Locating Server/Instance Specified [xFFFFFFFF].
Can anyone point me in the right direction
Is it possible to have a varchar column as a primary key with values like 'a ' and 'a', is gives always this error "Violation of PRIMARY KEY constraint" in MS SQLServer 2008.
In Oracle dons't give any error.
BTW I'm not implementing this way I'm only trying to migrate the data from oracle to sqlserver.
Regards
I am planning on deploying a database to SQL Azure, so I cannot use the SQL CLR. However, I have a need to create an aggregate function -- in my case, I need to STUnion a bunch of Geography objects together. (Azure is expected to support Spatial by June.)
Is there another way to accomplish this, without making use of the CLR, in a query? Or do I have to create a UDF that will take a table as a parameter and return the aggregate?
Hi,
I've a sql table with a primary key(Auto Incremented) and a foreign key.Now I need to modify the table by modifying the foreign key to second primary key so that its values are not allowed to duplicate.
How do i alter my table without affecting the data? Need the sql code.
Regards,
Vix
I'm running the following statement to see what queries are executing in sql server:
select *
from sys.dm_exec_requests r
cross apply sys.dm_exec_sql_text(r.sql_handle)
where r.database_id = DB_ID('<dbname>')
The sql text that comes back is parameterized:
(@Parm0 int) select * from foo where foo_id = @Parm0
Is there any way to get the values for the parameters that the statement is using? Say by joining to another table perhaps?
I want to add a database task that runs on a 6 hours interval. The task is to delete some records that matches certain condition.
What is the best way to achieve this in SqlServer 2008 ?
I know I can do this on the app side but I want it on sqlserver side.
Windows 7 computer running SQLServer Express 2008 (sp1).
When I try to run net start mssql$sqlexpress I receive an error:
System error 5 has occurred.
Access is denied
The SQL service is running under "Network Service" account
The service starts fine if I use the services window. Could somebody help me figure out why I am receiving this error?
I am trying to migrate sharepoint wss 3.0 databases from SQL Express 2005 to SQL 2008 Workgroup edition.
I have backed up the database, but not sure how to best attached/restore them to the new version and get up and running again.
Thanks
Please help me to find out error in my SQL query. I have created this query to compare dates
select * from Joinplans jp
where cast(convert(varchar,GETDATE(),103) AS datetime) BETWEEN
CASE(convert(varchar,jp.planstartDate,103) AS datetime) AND
CASE(convert(varchar,DATEADD(DAY,jp.planDays,jp.planstartDate),103) AS DATETIME)
It's giving me the error:
incorrect near 'AS'
I am using SQLServer 2005.
I don't seem to find a tool for it, nor an odbc driver.
Thanks
UPDATE : I'm aware of the sql scripting possibilities. But than again : how to script a sql 2k table? (not just ddl, but data also?)
Of course you can write this all by yourself, but importing data into CE cannot be such a hassle, or can it ?
UPDATE2 : I don't seem to be able to choose the right dialect for inserting
please help me to find out error in my sql query. i have created this query to compare dates
select * from Joinplans jp
where cast(convert(varchar ,GETDATE(),103) AS datetime) BETWEEN
CASE(convert(varchar,jp.planstartDate,103) AS datetime) AND
CASE(convert(varchar,DATEADD(DAY,jp.planDays,jp.planstartDate),103) AS DATETIME)
It's giving me the error:
incorrect near 'AS'
I am using SQLServer 2005.
Simple problem. I have an SQLServer database (MyData.mdf) and I want to convert it to a Compact database. (MyData.sdf) Just can't find the proper tool which can do this for me.
And I would also be able to convert the compact database back to a regular SQLServer database...
Store a byte[] stored in a SQL XML parameter to a varbinary(MAX) field in SQLServer 2005. Can it be done ?
Here's my stored procedure:
set ANSI_NULLS ON
set QUOTED_IDENTIFIER ON
GO
ALTER PROCEDURE [dbo].[AddPerson]
@Data AS XML
AS
INSERT INTO Persons (name,image_binary)
SELECT
rowWals.value('./@Name', 'varchar(64)') AS [Name],
rowWals.value('./@ImageBinary', 'varbinary(MAX)') AS [ImageBinary]
FROM
@Data.nodes ('/Data/Names') as b(rowVals)
SELECT SCOPE_IDENTITY() AS Id
In my schema Name is of type String and ImageBinary is o type byte[].
Is there a SQL statement that will list the names of all the tables, views, and stored procs from MS SQLServer database, ordered by schema name?
I would like to generate an Excel spreadsheet from this list with the columns: schema, type (table, view, stored proc), and name.
I'm using Linq to SQL on an SQL Compact database. I have a function where I insert multiple records into the database. I only call SubmitChanges at the end of the function. Would using a transaction (using the TransactionScope class) bring me any more performance or advantages?
I need to take data from one table and import it into another table. In pseudocode, something like this:
For Each row in table1
If row.personid is in table2 then
update table2.row
Else
insert row into table2
End If
Next
What is the best way to do this in T-SQL? As I understand it T-SQL doesn't support For Each..Next, so what alternatives do I have?
Currently im working on a research paper about sql-injection with RFID tags and Im curious if it is possible to create a database trigger with an sql injections if stacked queries are disabled. If stacked queries are enabled, of course it is easy (assuming you know the table layout), but what if they're disabled for security reasons.
I realise this is a bit flippant but it may highlight some 'interesting' features of t-sql.
Or just provide some light distraction on a Friday morning...
I'm currently torn between
t-sql allows three part naming when dropping tables but not when dropping procudures
and
When using Coalesce to produce a delimited string the presence of a leading delimiter is
dependant on whether the delimited string was initialised prior to calling Coalesce
I'd be interested to hear yours......
I'm using identity specification for a table of sqlserver 2012. Let we have two Insert and then two Delete operation. After these operation primary key should start from 1, but it will start from 3. I'm worry about this problem causing no place for inserting new item after long time. Does "Sql-server 2012" fill these gaps by itself?
If it is possible, please refer me a documentation ( for example from microsoft)
On my SQLServer 2008 I have a stored procedure with a large number of parameters.
The first part of them is used in every call and parameters from the second part are used rarely. And I can't move the logic to two different stored procedures.
Is there a way to encapsulate all this parameters to a class or struct and pass it as a stored procedure parameter?
Can I use SQL CLR. Are there other ways?
I'm trying to drop a SQLServer database from .NET code. I've tried using the SMO classes but get an exception saying the database is in use.
Then I tried executing a query (opening a SqlConnection, executing a SqlCommand), along the lines of:
ALTER DATABASE foo SET SINGLE_USER WITH ROLLBACK IMMEDIATE
(pause)
DROP DATABASE foo
But still I get an exception saying the database is in use.
How do I do this? (Or, how does SQLServerManagement Studio implement the Drop database and close existing connections?)