View Complete Post
We have been presenting an issue randomly since we changed our replication to use custom stored procedures for replication.
We have several offices which replicate to our central datacenter, each of this offices have different data corresponding only to their site and we centralize the data from all databases in only one database.
We use custom stored procedures for some tables only for the insert method, but randomly the update method of that table drops and I have to create again. We have been set the replication by using the 'replication support only' method so it only creates
the replications sp. All our articles have the create update, insert and delete stored procedures for replication.
We have done traces for this and the replications is generating the drop but it doesn't recreate the procedure. It only occurs for the articles with custom procs for insert.
The snapshot jobs for each office are disabled.
1. I have created Custom DB Installation by Installar Class
2. I created Stored Procedure Script From DB
3. Copyied Script in sql.txt
4.Created Custom DB Setup and Executed, But I am getting SP script Execution issue, same script is working in QueryAnalyser Execution
Here is My Execution code
I want to make my gridview enable for custom paging and sorting. I started to follow a tutorial and write the Stored procedure.
But my stored procedure seems not to be working. here it is:
ALTER PROCEDURE [dbo].[USP_getStudentsEmail]
IF LEN(@sortExpression) = 0
SET @sortExpression = 'SendDate'
DECLARE @sql nvarchar(4000)
SET @sql = 'Select *
Select m.Body,m.Subject,m.SendDate,m.SenderProfile,m.Receiver AS Receiver,m.ID,s.FirstName,ROW_NUMBER() OVER (ORDER BY '+ @sortExpression + ') AS RowRank
from Message m INNER JOIN StudentProfile s ON m.Sender=s.UserId
) AS OrderedEmails
WHERE m.Receiver= '+ CONVERT(nvarchar(38), @receiver) + 'AND RowRank > ' + CONVERT(nvarchar(10), @startRowIndex) +
' AND RowRank <= (' + CONVERT(nvarchar(10), @startRowIndex) + ' + '
+ CONVERT(nvarchar(10), @maximumRows) +')'
EXEC sp_executesql @sql
I tried to run this by the following line
exec USP_getStudentsEmail 'SendDate',1,1,'5ed19f91-eeb7-4c6a-b564-98c8dd83e18c'
but it says
Incorrect syntax near 'd19f91'-
can anybody help
So I've created a DLL assembly using the BIDS tools and Visual Studio, deployed the DLL to the correct folder on the BIDS dev workstation and on the server where Reporting Services is hosting the report. Everything is working fine.
So, how does an "ordinary" user access this report since the dependent DLL is sitting on the server and not on the client where the Report Builder's report processor is running. Does the IT staff have to copy the DDL to somewhere on the client's
system so the Report Builder .EXE can see it? If so, where? What's the "best practice" method here?
Mentor, Consultant, Trainer, MVP
"Hitchhiker's Guide to Visual Studio and SQL Server (7th Edition)"
Please click the Mark as Answer button if a post solves your problem!
*Read the whole question before you decide to send this to the chart forum
So here is what I am trying to do:
I have a chart in VB Express (vb.net) that obtains its data from a stored procedure in my SQL Express database. The chart is a stacked column chart and shows events on the X axis. What I need is these events to be displayed in a very specific order in my
I have been told that I cannot custom order this in the application, but rather I need to change my stored procedure output to get the events in the order I want. It was suggested to me that I should make a new table in my database that has the names of
the events in 1 column and the order I want them in, in the other. Then use that to order my output in my stored procedure.
I do not care how I accomplish what I need to accomplish so long as I do indeed accomplish it. Here is some database structure to help you understand my database:
BuyerID (PK), ProjectID (FK), Status, Type
There are 12 different statuses, though my stored procedure doesn't know that. These 12 statuses need to be shown in a very specific order. My current stored procedure is as follows:
select Status as Status, Type as Type, count(BuyerID) as Value from Buyer WHERE projectID = @ProjectID AND Status IS NOT NULL AND Type IS NOT NULL GROUP BY Status,Ty
I created a stored procedure based custom conflict resolver in SQL 2005, I return the winning result set and also save that result set to a test table to compare the values.ÃÂ The values saved to the test table are correct but some of the values saved as the conflict winter are truncated.
Example a char(3) filed is updated at the subscriber as '111' and updated at the publisher as '222', in my custom conflict resolver if I use the value from the subscriber the conflict resolver updates the field asÃÂ '11 ', if I use the publisher value the conflict resolver updates the field as '22 '.ÃÂ Now the same records is saved to the test table correctly as either '111' or '222' depending on the logic I used.ÃÂ So the result set has the correct values, its after the custom conflict resolver is called where the values is somehow truncated.ÃÂ Has anybody run into this before and what steps can I take to avoid this.