Microsoft Sync Framework 2.1 + Change Tracking in Sql-Server 2008 - sql-server-2008

When I provision a scope for synchronization in an SQL 2008 database like this:
SqlSyncScopeProvisioning sqlServerProv = new SqlSyncScopeProvisioning(sqlServerConn, myScope);
if (!sqlServerProv.ScopeExists(scopeName))
{
sqlServerProv.Apply(); // Apply the scope provisioning.
}
i see a bunch of change tracking tables, stored procedures and triggers created.
Why is this not using the "Change Tracking" feature of SQL 2008, which is much cleaner and everything gets tracked behind the scenes?
I thought that the "Change Tracking" feature of SQL 2008 was designed precisely to simplify these scenarios.
Now turning the question around: Is there a way to do a 2-way synchronization between two SQL Server 2008 databases just using Change Tracking in both of them instead of provisioning the triggers/auxiliary tables ?

See Syncing SQL Server 2008 Databases over HTTP using WCF & Sync Framework

Related

One table in my SQL Server 2008 Express r2 database is timing out

I have been using a SQL Server 2008 Express R2 database for a few months now. Recently, one of my tables started timing out if I try to make an UPDATE through code or through Management Studio. I have tried making changes via the designer in management studio as well, and the same thing.
What can cause a single table to time out like this? My other tables are instant response to my changes, but this one just refuses to let me make any changes.
It sounds like your bad table has some kind of trigger attached to it. I suggest firing up SQL Profiler to see exactly what queries are being sent to the table.

Using SQL Server 2008 R2 with Visual Studio Express

I want to create either "LINQ to SQL" classes or use "Entity Framework" from Visual Studio Express 2010. When I attempt to add a data source my only options are:
"Microsoft Access Database File"
"Microsoft SQL Server Compact 3.5"
"Microsoft SQL Server Database File"
Do I need VS2010 Pro to use LINQ to SQL or EF? I thought I could do all of this from Express. I even went so far as to install, "Microsoft SQL Server 2008 Native Client" and it still doesn't show SQL Server 2008 as a data source.
Thanks!
p.s. I feel like a complete idiot that I cannot get this to work
LINQ to SQL (L2S) and LINQ to Entities (L2E) (aka Entity Framework) are part of the .NET Framework, and so are part of .NET regardless of what version of VS you use.
Both first appeared in 3.5 and are updated in 4.0, although LINQ to SQL won't be progressed any further in terms of functionality. Hence there isn't a dependency on the IDE. What might be missing is the LINQ to SQL or LINQ to Entity designers, but I don't think from memory they are.
If you select Add New Item and look in the Data group you should find "LINQ to SQL classes" and "ADO.NET Entity Data Model" - if not perhaps the designers are not part of Express.
[edit]
Seems this has been asked before:
Connecting to SQL Server with Visual Studio Express Editions
For LINQ, use SQLMetal to generate the spew and then just form connection string and let the code connect - you shoudldn't let VS mess with your data representation anyway. SQLMetal's spew is very clean and you can also edit it, once you learn what's what, to make it lighter - or heavier :-) - there are hooks for more code as well.
Before that check that your SQL instance is running and visible - VS installed SQL Express as default instance it can prevent real SQL's default instance from even being visible - a lot of uninstalls in your future if that happened.

sql-server-2008 audit tables

In one of my application Iam using SQL SERVER 2008, I like to implement audit tables for few tables. One option I have to create triggers on the respective tables. Can anyone suggest me any other good, robust and secure option.
SQL Server 2008 has a new auditing feature: Auditing in SQL Server 2008.
There is also Change Data Capture
Triggers are the usual way to go. Another option could be to handle this in your stored procedures. Of course this assumes, that all data modification goes via stored procedure. Since you are on SQL Server 2008 and assuming you don't care about any lower version, check out the new auditing features here: http://msdn.microsoft.com/en-us/library/dd392015.aspx
You don't mentione which edition of SQL Server you are using as the Auditing features are only available in the Enterprise edition.
You should download a copy of the free eBook Developing Time-Oriented Database Applications in SQL by Richard T. Snodgrass from here: http://www.cs.arizona.edu/people/rts/tdbbook.pdf.
He talks about auditing and many other time related issues in databases.

How can I detect which version of SQL (eg SQL 2008 or SQL Azure)

I need to detect which version of SQL I am dealing with to perorm various tasks, I need specifically detect if I am on SQL 2008 or SQL Azure.
How can I do this with detection code written in SQL?
A good place to start might be: Programmatically detect SQL Server Edition.

What are the limitations on using SSRS with SQL Server 2005 Express edition?

I found this extremely old document which appears to say that many of the web client features are not availiable when running on express edition--scheduling, subscription, etc--as well as no access to the report builder. Is that information still current, and are there any other features which are unavailable?
Subscriptions and scheduling are indeed absent in both MSSQLEx2005 and MSSQLEx2008, but I have never found this to be much of a problem. The underlying platform has a scheduler and the web service will do all the rendering, so you can recreate the missing elements without too much trouble.
The report builder is also absent, and this is non-trivial to replicate. You could always install SQLEx locally and let them use BIDS. Or you could stop being cheap. It's pretty good for free.
I recommend you use SSRS2008 rather than 2005 because it no longer requires IIS, and there are several sexy new capabilities in the report engine. In particular it now supports flow-based rich text with inline fields for mail-merge type reports.
Compatibility is excellent but some applications reject a newer database engine version. If this is a problem, continue to use SQLExpr2005 for the database.
So, are you saying that A) SSRS 2005
requires IIS whereas 2008 does not,
and that B) SSRS2008 is backwards
compatible with a SQL2005 database?
(It sounds like you might be saying
that SSRS 2008 could be used with
somebody running 2005 DBs
Yes, I am indeed saying that
SSRS 2005 requires IIS whereas 2008 does not
SSRS 2008 is backwards compatible with a SQL2005 database
SSRS 2008 could be used with somebody running 2005 DBs, or even 2000 DBs.
You can use SSRS with any database server for which ADO.NET drivers are available, including Oracle and MySQL.
I've caught somewhere the idea about rich text in SSRS 2008.
As I see it will allow me to make such static text
"Some test with some text in bold and some italic text"
with a single text box which was impossible in RS 2005. (even don't know good way to make it there)
You wrote it doesn't require SQL Server 2008 to be installed.
What about IDE for reports development ?
Looking forward with big hopes for SSRS 2008,
thanks for attention in advance,
Alex