Prevent sql server Compact as a subscriber to anonymous merge pull publication - sql-server-2008

Is there a way to specify as a property to my publication, to say it doesn't need to handle sql compact subscriptions?
Sql server 2008 R2 as the publisher, when I originally created the publication, I set the compatibility to 2005 and up. I unknowingly used a time column in one of the replicated articles, and realized after it is too late that for sql ce, it comes down as nvarchar.
First of all, time datatype is introduced from 2008, so I changed my publication compatibility to 2008. And createad new snapshot, reinitialized subscriptions etc.
Currently all my subscibers are 2008 express. I will never need to handle 2005 subscribers.
Also, I never need to handle 2008 Compact subscribers. since time is not supported only for compact, my theory is, if I can somehow specify that the publication need not allow compact subscribers and regenerate my snapshot and redo subscriptions, that column will finally come down as 'time' instead of nvarchar.
So, is it a possibility?
EDIT:
I overlooked the fact that there is no such thing as 'sql server 2008 compact'. I guess my question now is, after I created a pubication with 'subscriber types' as 2005 and up, and later after atleast one subscriber exists(only 2008 express), I change the publication property to 2008 and up, why doesn't any new subscibers get 'time' datatype? Can someone assure that if I totally delete the publication and recreate it from scratch, subscriptions will get the 'time' column fine?

The "New Publication Wizard" has a "Subscriber Types" dialog, on this, select only SQL Server 2008.

Related

Any function like LOOKUP in SSRS 2008

There is any function like LOOKUP in 2008 apart of sub reports because i have a tablix from where the columns are coming from different datasets.
No. SSRS took big leaps forward with 2008R2. I recommend installing a more recent version of SSRS, which could still connect to a SQL 2008 server four your datasources.
Alternately, change your queries to combine the fields in the dataset.

Insert Into using Microsoft SQL Server 2008 R2

I am tryng to insert a new user into a simple table that contains ID and Name.
This is the query that I execute:
INSERT INTO [dKArchive].[dbo].[Logins]
([IDL]
,[Name])
VALUES
(37
,'pippo.paperino')
GO
I am using Microsoft SQL Server Management Studio.
After executing query, the value is added in the table, after when I close the Microsoft SQL Server Management Studio and reopen it, this data disappears.
Why does it happen?
Thanks. Best regards.
Second attempt at answering:
SSMS has an option to set that every query is a transaction. You find this under
Tools...->Options->Query Execution->SQL Server->ANSI->SET IMPLICIT_TRANSACTION
If this option is on, you will get something close to the behaviour you describe. However, when closing SSMS, you will get a warning about uncommitted transactions. Ignoring this warning is not a good idea.
At that time, you can click Commit and all is well, or you can just turn off this option.

Microsoft SQL resetting ID auto increment

I am using Microsoft SQL server 2012 and i am trying to reset my table primary key IDs so its in a sequential manner, i know some will say its better to leave it as it is but i just want to find out a way to do it.
Question edited due to extra knowledge gained within the first 10mins of post
This is the command to use in SQL Server 2008, and should be the same for 2012:
Reset autoincrement in Microsoft SQL Server 2008 R2
DBCC CHECKIDENT ("YourTableNameHere", RESEED, 1);
And it's not very clear if you want it in MySQL or T-SQL syntax.

SQL Server 2008 Linked Server and CONTEXT_INFO

I'm trying to use the SQL Server 2008 Change Tracking feature. Once the feature is enabled, you can make use of the CHANGETABLE(... function to query the change tracking history that is kept internally by SQL Server, e.g.:
SELECT
CT.ID, CT.SYS_CHANGE_OPERATION,
CT.SYS_CHANGE_COLUMNS, CT.SYS_CHANGE_CONTEXT
FROM
CHANGETABLE(CHANGES dbo.CONTACT,20) AS CT
where the SYS_CHANGE_CONTEXT column records the CONTEXT_INFO() session value. This column is useful for auditing who changed what etc.
Some of the statements that change data are executed using four-part notation by a remote SQL Server that has the home server as a linked server e.g.:
INSERT INTO [home server].[db name].[dbo].[CONTACT](id) values(#id)
My problem is that the CONTEXT_INFO() as set on the remote server in the session executing the query does not get picked up in my home server change tracking, i.e. it doesn't look like the CONTEXT_INFO spans a distributed query. This means that the following will not result in the CONTEXT_INFO being logged on the home server change tracking.
-- I'm running on a remote server
WITH CHANGE_TRACKING_CONTEXT (0x1256698477)
INSERT INTO [home server].[db name].[dbo].[CONTACT](id) values(#id)
Does anyone know whether this is a limitation or if there is a way to persist/communicate CONTEXT_INFO across the distributed query?
Thanks
I was thinking about using Context_Info to audit changes (web app). but after doing some tests understood its not good idea. Because of connection pooling context_info was not working the way i desired.
Ended up with using GUID identifier associated with each logical session + table, where is stored session GUID and information related to session + each table stores that identifier in separate column. Not as easy to code as it would be with context_info()..
And as far as i understood from documentation, change tracking is not designed for audit purposes (think that is what you trying to do).

How do you migrate SQL Server 2000 reports to SQL Server 2005/2008?

Can anyone explain how to import or migrate SQL Server 2000 reports to SQL Server 2005 or 2008?
Mostly you just need to port your data from your old ReportServer database to the new one. The report RDL is stored in the Catalog table, for instance, and you just need to import all of that. That table also includes all of the path names you've defined. The subscriptions table contains all the subscription that have been defined, as you would expect.
I've not done a full migration between the two, but it should be relatively straight forward -- just dedicate a day or so to matching up all the fields and then run with it.