I have SQL Server 2008 (Version 10.0.2531).
The following annoying bug? happens, and maybe someone has a workaround: When I create a computed column which also combines values from a scalar valued function, and then add it to the fulltext index via the wizard, everything works fine. The fulltext index correctly picks up on the column a...
EDIT: my apologies, this was a MSSQL2008 issue.
I have a SQL problem that I've come up against routinely, and normally just solved w/ a nested query. I'm hoping someone can suggest a more elegant solution.
It often happens that I need to select a result set for a user, conditioned upon it being the most recent, or the most sizeable...
B"H
What are the steps of keeping Sync Framework up to date with schema changes in the database?
...
Hey Everyone,
Over a year ago I created my own database classes which use PDO, and handle all preparing, executing, and closing connections. These classes have been working great up until now.
There are two different database severs I am grabbing from, MySQL, and MS SQL Express. I am retrieving an employee id from the MySQL server and...
Im trying to execute a stored procedure and simply insert its results in a temporary table, and I'm getting the following message:
The operation could not be performed because OLE DB provider "SQLNCLI" for linked server "MyServerName" was unable to begin a distributed transaction. OLE DB provider "SQLNCLI" for linked server "MyServerNam...
I have a ASP .NET load balanced application (webservice and website). It runs on SQL server. I need to be able to provide large files for download. However, because of the load balancing situation, the files are stored in the SQL database as opposed to the file system. BITS seems to be the best approach. I have full control of the client...
In Oracle, a table cluster is a group of tables that share common columns and store related data in the same blocks. When tables are clustered, a single data block can contain rows from multiple tables. For example, a block can store rows from both the employees and departments tables rather than from only a single table:
http://downloa...
How can I manually introduce an integrity error into my database for the purpose of testing, without totally corrupting the database so that I can still run my program.
Updating with a more specific question...
The actual feature that I am testing runs DBCC CHECKDB and what I am testing is that it reports a failure to the user.
...
I have a device that continuously collects data and stores it on a local database. I would like to also replicate that data to a second computer over the network every 10 seconds to ensure data reliability. Should I use transaction replication to achieve this? What if the network connection is temporarily unavailable, will the replicatio...
UPDATE: I've modified the code to drop the indexes before the inserting, but it makes not difference.
I've been asked to resolve an issue with a .Net/SqlServerCe application. Specifically, after repeated inserts against the db, performance becomes increasingly degraded. In one instance at ~200 rows, in another at ~1000 rows. In the l...
Hi All,
I have a quick question. How do I select the two values I need in one query? Currently I'm doing this, which works fine, but it's obviously running two queries when one should do the trick. I tried MAX(columnA) and GROUP BY ColumnB, but that returns multiple row. I only want one row returned.
DECLARE @biID bigint
, @dtThresho...
Based on the following table
Area S1 S2 S3 S4
--------------------
A1 5 10 20 0
A2 11 19 15 20
A3 0 0 0 20
I want to generate an output that will give the number of columns not having "0".
So the output would be
Area S1 S2 S3 S4 Count
-------------------------
A1 5 10 20 0 3
A2 11 19 15 20 4
A3 0 ...
Hi,
I have a peer to peer Merge Replication from two Sqlserver 2005. The first Sqlserver is both the publisher and distribuitor. All works fine but if the VPN goes down for a couple of hours the replication goes down too and I need to manually restart the sqlserver agent.
In the Sqlserver Agent properties I have set the two option about ...
I need the behaviour of sql2005 where function OBJECT_NAME takes two arguments obj id and db id, while sql2000 takes only obj id so the execution must be in the context of the database to which inspected object belongs to. Solution must be possible to implement in a function, so it can be used in a select query.
...
I have a SQL Server 2008 database with > 300 tables. The application I have to design is an Windows Forms app, .NET 3.5, C#.
Which is the best way to work with Linq-to-SQL ?
I intend to make a datacontext for each business entity.
Is there any problem ?
I need to know if this way of working with Linq-to-SQL has any disadvantage or ca...
I have to tables as follows;
Employees: Name nvarchar(50), Job Title nvarchar(50) and Salary int.
Employers: Name nvarchar(50), Job Title nvarchar(50)
I would like to select every item from the 'Employers' table where 'Job Title' does NOT show up in the 'Employees' table.
I know this is a simple query but it has me stumped.
I'd be ...
This is a database design question.
I want to build an invoice web application, an invoice can have many items, and each user can have an inventory list of product items that they can store and choose to add to an invoice item.
My questions are:
1. Should I store all product inventory for all users using my application under one singl...
I have already setup syncing with Microsoft Sync Framework, and now I need to add fields to a table.
How do I re-provision the databases?
The setup is exceedingly simple:
Two SQL Express 2008 servers
The scope includes the entire database
Using Microsoft Sync Framework 2.0
Synchronizing by direct access. Using the standard new SqlSync...
How to insert rows in an Excel sheet into SQL Server 2005 or oracle ?
For example if I have 5000 rows in Excel sheet how can I insert these rows into a table in any database
...
can any one explain hiow this query works..It's for getting the Nth largest elemet from a table.here it's 4 th largest
SELECT a.ID
FROM tblitem a
WHERE (4) = (select count(*)
from tblItem b
where b.id < a.id)
Thanks in advance
...