Showing posts with label custom. Show all posts
Showing posts with label custom. Show all posts

Tuesday, March 27, 2012

default delimiter change from comma to semicolon

Is this possible? I now that i can use custom application to do this, but is
it possible to change semicolon as a default delimiter on server.
Thank's in advance.."AG, NLB d.d." wrote:
> Is this possible? I now that i can use custom application to do this, but is
> it possible to change semicolon as a default delimiter on server.
This probably has to do with the default regional setting on the server. For
US formats comma is used as list seperator, but for most EU countires comma
is used as the decimal seperator so they use semicolon as list seperator.
Otherwise you could get into trouble with a list like this:
5,67,34,56,32,09
Is it 5;67;34;56;32;09 or is it 5,67;34,56;32,09 or any other combination.
In regional settings you can change what the seperator character should be.
Perhaps this link will help you:
http://www.adopenstatic.com/faq/systemdateformat.asp|||i'am sorry to mislead you.
I have a problem with exporting data in CSV format, because data includes
commas, so i have to use some other delimeter like semicolon as default
delimiter on server.
Thanks.
"Glenn F. Henriksen" wrote:
> "AG, NLB d.d." wrote:
> > Is this possible? I now that i can use custom application to do this, but is
> > it possible to change semicolon as a default delimiter on server.
> This probably has to do with the default regional setting on the server. For
> US formats comma is used as list seperator, but for most EU countires comma
> is used as the decimal seperator so they use semicolon as list seperator.
> Otherwise you could get into trouble with a list like this:
> 5,67,34,56,32,09
> Is it 5;67;34;56;32;09 or is it 5,67;34,56;32,09 or any other combination.
> In regional settings you can change what the seperator character should be.
> Perhaps this link will help you:
> http://www.adopenstatic.com/faq/systemdateformat.asp
>|||"AG, NLB d.d." wrote:
> I have a problem with exporting data in CSV format, because data includes
> commas, so i have to use some other delimeter like semicolon as default
> delimiter on server.
Okay, I haven't tried this, but I think you could change the list seperator
value in the control panel->regional settings. But you have to do it for the
user that Reporting services is running under. You may have to change the
default user's settings. Make the change on your own account and then try to
set it to the default system value.
Another option is to make sure that your data in enclosed in quotes, like
this:
"35,54","this, is a test", "example.com, example.net"
--
Glenn F. Henriksen
http://www.henriksen.no/

Thursday, March 22, 2012

Default conflict resolver in Sql 2000

Hi, I'm replicating a database between two instances of Sql 2000 using Merge Replication. I have no custom resolvers at present but I'm seeing something unexpected.

If I change the same record in both databases at the same time, but the changes affect different columns then I thought the changes would be merged and there would be no conflict because the changes were in different columns. What I actually see is a conflict and hence the publisher is winning and pushing it's changed row to the subscriber.

Have I got this wrong, will a conflict occur if the same row changes regardless of the columns updated?

Regards

GrahamCould it be the timestamp column that is causing the conflict? When I set up the publisher I simple published all tables and sp.

Is there any way in enterprise manager establishing what columns conflicted?

Thanks

Graham|||Merge replication can track conflict at row level or column level. It looks that you wanted to track conflicts at column level but set it up at row level.

You can launch conflict viewer to see the conflicts. From Enterprise Manager, if you right click the publication, there should be a menu called View Conflicts.|||Thanks for the reply.

I do have it tracking conflicts at column level. However, I did a little more digging, this is what I found...

I have a published table with two int columns, A and B. The initial data looks like:

A B
--
1 2

If on the publisher I update column A to a value 2 and on the Subscriber I update the same row but Column B to a value 3 the a merge happens and the result is that the pub and the subscriber looks like:

A B
--
2 3

If however, on the publisher I update both columns to A=3 and B=3 (net result only column A has changed) and on the subscriber I again update both columns to A=2 and B=4 (net result only column B changes), I then get a conflict as the agent thinks both A and B have been changed on the publisher and the subscriber.

I was expecting the net results to be sent when the merge agent runs, but it seems to send all the data regardless of whether any column data was changed or not.

Is this behaviour normal?

Regards

Graham
|||Hi Graham,
Yes this is the expected behavior.
Once a column is touched (to the same value or the new value) it will be sent to the other side.
However if you touch the same column multiple times, only the net effect is sent.

Sunday, March 11, 2012

Declaring DataTable in script causes error?

As discovered when trying to create a custom transformation for this question (http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=899895&SiteID=1&mode=1) I tried creating an object of type DataTable and I get this error

dim myTable as DataTable

Reference required to assembly 'System.Xml, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' containing the implemented interface 'System.Xml.Serialization.IXmlSerializable'. Add one to your project. dts://Scripts/ScriptComponent_3851bc3613714d2d904d79bc006234f9/ScriptMain 19 24 ScriptComponent_3851bc3613714d2d904d79bc006234f9

Even if I add "Imports System.XML" I get the same error. Isn't DataTable part of System.Data (which is imported by default in Script Components)? Everyone else get the same behavior?

Chris,

The Imports directive brings namespaces from referenced assemblies. please see the link below for more details:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vblr7/html/vastmimports.asp

You need to add a reference to System.Xml.dll through the project pane in order to be able to use any types from System.Xml namespace.

|||Thanks that works!... so even though its listed as part of System.Data it uses something from System.Xml?

Friday, February 24, 2012

Debugging Report Manager

Hi,
I have created a custom data processing extension that retrieves a Data
Table object from my DAL. It all works fine in the report designer, I can
preview the report and data is returned etc However when I deploy the report
and then try to access via the report manager web interface I get an error
has occurred during report processing... I can't for the life of me see what
is could be causing the error and I don't know how to debug this
Can anyone provide any useful tips/tricks?
ThanksMy bet is that dotnet security is tripping you up. When in development you
are the admin of the box and have all the rights you need to do anything.
The context of your assembly in production is different and you need to
setup the rights for the assembly. That is my guess anyway.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Neil" <Neil@.discussions.microsoft.com> wrote in message
news:B8854717-92A7-4ED1-8FDC-0D8462A594AB@.microsoft.com...
> Hi,
> I have created a custom data processing extension that retrieves a Data
> Table object from my DAL. It all works fine in the report designer, I can
> preview the report and data is returned etc However when I deploy the
> report
> and then try to access via the report manager web interface I get an error
> has occurred during report processing... I can't for the life of me see
> what
> is could be causing the error and I don't know how to debug this
> Can anyone provide any useful tips/tricks?
> Thanks
>

Sunday, February 19, 2012

Debugging custom Sql delivery provider

We can not get the sql server custom delivery protocol working. Code found on MSDN. We have a custom MQ working and this subsciription works sent to file only. But whenever we use the sqlprotocol we get this error.

Event Type: Error
Event Source: NotificationServices
Event ID: 4048
Description:
Description: Some notifications cannot be delivered because they reference non-existent subscribers, unknown subscriber device names, or unsupported protocols for the notification class. Use the NSDiagnosticFailedNotifications stored procedure for details about undeliverable notifications.
EventParameters:
InstanceName: EasyNS
ApplicationName: DocEvents
Component: Generator
Thread: 10

The NSDiagnosticFailedNotifications NSDiagnosticFailedNotifications outputs

AppName, Notifclass, delchanlname, notifbatchid, notid, subid, subdevadd,

DocEvents, NewDoc, NULL, 1, 2, RushDiamondSQL, RushDiamondNotifierAgent, NULL, NULL, NULL

the del channel name is null? Any other debugging tips? we have pathers book.

the protocol assembly definition only has the path/file dll name.

thanks

I got it figured out. my subscription was calling the wrong notif class which did not have this protocol.

Debugging Custom Report Data Processing extension

Hi,

I've created our own custom report data processing extension and it works successfully. I also know how to debug the extension while in the Report Designer environment (in Visual Studio).

However, is it possible to debug the extension in the run-time mode. That is, when I run Report Manager to view the report that usees this extension.

Thank you very much

Yes, you should be able to attach a remote debugger to the IIS worker process, just like an ASP.NET application.|||Please help! I still don't know how to debug during run-time ... FYI, I'm using Windows 2003 Server. I can't seem to find the ASP.NET worker process ... am I missing anything?

I have no problems previewing the report data in report designer. However, when I try to run the report in report manager, I get this error:

"An error has occurred during report processing."

What could possibly be wrong? Any thoughts?

Thank you!!|||On Windows 2003, attach the debugger to w3wp.exe

-- Robert

Debugging Custom Report Data Processing extension

Hi,

I've created our own custom report data processing extension and it works successfully. I also know how to debug the extension while in the Report Designer environment (in Visual Studio).

However, is it possible to debug the extension in the run-time mode. That is, when I run Report Manager to view the report that usees this extension.

Thank you very much

Yes, you should be able to attach a remote debugger to the IIS worker process, just like an ASP.NET application.|||Please help! I still don't know how to debug during run-time ... FYI, I'm using Windows 2003 Server. I can't seem to find the ASP.NET worker process ... am I missing anything?

I have no problems previewing the report data in report designer. However, when I try to run the report in report manager, I get this error:

"An error has occurred during report processing."

What could possibly be wrong? Any thoughts?

Thank you!!|||On Windows 2003, attach the debugger to w3wp.exe

-- Robert

Debugging a customponent used in a Integration Services project

Hi there
I'm building a SQL Server integration services project with a custom component. I created the custom component as a separate C# library project and compiled it. With the help of some online resources I was able to make it appear in the Dataflow Transformations toolbox items of Integration Services IDE. But this component is throwing some errors. My question how do I setup the environment such that I can set break points and debug the component's source while debugging the integration services project?

Any help will be greatly appretiated.

Thanks in advance.

Arun M

Hi Arun,

open the SSIS designer with your component in it, open another VS window with your C# project where you would like to debug. For design-time debugging, attach the VS debugger (using Debug\Attach to Process...) to devenv.exe process that hosts the SSIS designer. For runtime debugging, attach your debugger to DtsDebugHost.exe.

HTH.

Thanks,

|||Here's another way to debug things, a little different than the way Bob suggested above:

Setup the Custom task to run using DTEXEC as it's startup
program. In the CommandLine arguments, pass in the
filename of the DTSX package that includes the custom
task. Then start the debugger and it should hit your
breakpoints...|||

I am trying to use the second method of DTEXEC but I am getting a "The product level is insufficient for component ..." message on one of my machines and ONLY ONE of them.

The notable difference is that I am connecting to my local machine running the databases VS a remote database. The one using the remote database is failing with the above message and the local database machine debugs just fine.

Note: Running the package with the custom component through VS works just fine.

I am going to attempt the DtsHost... item above but I don't like that one as you have to close the VS environment over and over to do testing of changes!

|||This issue has already been discussed in this forum. To use dtexec you must have a server OS.|||

Then why would I get one working and not the other when they are both on Windows XP SP2?

Is it that DTEXEC can only connect remotely while on a server OS? That seems rather strange to me...

|||No you must have installed SSIS. DTEXEC runs fine on all OS's that SSIS runs on, which includes XP. The message is usally encountered when using the Wizard, and only having installed workstation components, and not the SSIS server components.|||

I am pretty sure I have it all installed and not just the workstation components as I am developing and running on the machine itself.

The component runs fine in BIDS both at design and run-time but only fails with the message when I try to run using DTEXEC.

Darren: Thank you for the pointer to the Regex example that was recently released. I am building a component that will use Regex to allow validation with custom messages logged, data type reformatting based on the matches (e.g. yyyyMMdd -> ^(\d{4})(\d{2})(\d{2})$ would validate the data and $1-$2-$3 would convert the data to a data string that can be type cast to DT_DBTIMESTAMP). Makes the date conversion much simpler.

Debugging a customponent used in a Integration Services project

Hi there
I'm building a SQL Server integration services project with a custom component. I created the custom component as a separate C# library project and compiled it. With the help of some online resources I was able to make it appear in the Dataflow Transformations toolbox items of Integration Services IDE. But this component is throwing some errors. My question how do I setup the environment such that I can set break points and debug the component's source while debugging the integration services project?

Any help will be greatly appretiated.

Thanks in advance.

Arun M

Hi Arun,

open the SSIS designer with your component in it, open another VS window with your C# project where you would like to debug. For design-time debugging, attach the VS debugger (using Debug\Attach to Process...) to devenv.exe process that hosts the SSIS designer. For runtime debugging, attach your debugger to DtsDebugHost.exe.

HTH.

Thanks,

|||Here's another way to debug things, a little different than the way Bob suggested above:

Setup the Custom task to run using DTEXEC as it's startup
program. In the CommandLine arguments, pass in the
filename of the DTSX package that includes the custom
task. Then start the debugger and it should hit your
breakpoints...
|||

I am trying to use the second method of DTEXEC but I am getting a "The product level is insufficient for component ..." message on one of my machines and ONLY ONE of them.

The notable difference is that I am connecting to my local machine running the databases VS a remote database. The one using the remote database is failing with the above message and the local database machine debugs just fine.

Note: Running the package with the custom component through VS works just fine.

I am going to attempt the DtsHost... item above but I don't like that one as you have to close the VS environment over and over to do testing of changes!

|||This issue has already been discussed in this forum. To use dtexec you must have a server OS.
|||

Then why would I get one working and not the other when they are both on Windows XP SP2?

Is it that DTEXEC can only connect remotely while on a server OS? That seems rather strange to me...

|||No you must have installed SSIS. DTEXEC runs fine on all OS's that SSIS runs on, which includes XP. The message is usally encountered when using the Wizard, and only having installed workstation components, and not the SSIS server components.|||

I am pretty sure I have it all installed and not just the workstation components as I am developing and running on the machine itself.

The component runs fine in BIDS both at design and run-time but only fails with the message when I try to run using DTEXEC.

Darren: Thank you for the pointer to the Regex example that was recently released. I am building a component that will use Regex to allow validation with custom messages logged, data type reformatting based on the matches (e.g. yyyyMMdd -> ^(\d{4})(\d{2})(\d{2})$ would validate the data and $1-$2-$3 would convert the data to a data string that can be type cast to DT_DBTIMESTAMP). Makes the date conversion much simpler.

Debugging a Custom Resolver in VS2005

Hi,

I have created a custom resolver in VB .net (VS2005). The resolver works ( Both Publisher and Subscriber are SQL 2005 ), but I need to be able to debug the code within the resolver. How do I do this? I have tried a number of things without success.

Any suggestions would be appreciated.

Cheers

Neil

Neil, you can open the merge agent (replmerg.exe) as a project in Visual Studio 2005, attach symbol files for your custom resolver, set a break point in your custom resolver source code, and run the agent with parameters. You will be able to trace into your resolver code from there.

To open the replmerg.exe as a project in VS2005, go to menu File->Open->File/Project, and choose the executable directly. There is a "Executable" in the dropdown list in the dialog but if it is not there, you need to install VC++ components of VS2005.

|||

That fixed it.

The only other thing I had to do is in the properties of replmerg.exe I had to set the Debugger Type to "Mixed" not leave as "Auto"

Thanks for you help.

Neil

debugging a Custom Data Processing Extension

How do I go about debugging a Custom Data Processing Extension written in VB
or C#? How do I tell the debugger which process to attach to?
--
-PeterPlease check RS books online:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/rsprog/htm/rsp_prog_extend_dataproc_9plu.asp?frame=true
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"jpstewart" <jpstewart@.discussions.microsoft.com> wrote in message
news:F42133CD-B143-4E63-8461-0E6785EE8F5B@.microsoft.com...
> How do I go about debugging a Custom Data Processing Extension written in
> VB
> or C#? How do I tell the debugger which process to attach to?
> --
> -Peter
>

Tuesday, February 14, 2012

Debug deployed extension

I have a custom data extension I'm working on. I can debug this when the
report using it is being designed by adding a line in the code for the
extension like:
System.Diagnostics.Debugger.Break();
When I then run the report in design mode I'll get a choice of debuggers and
I can then open one and debug the extension.
However, if I then deploy the report (with
System.Diagnostics.Debugger.Break(); still in the code) and run the report
from say Report Manager or just via URL I don't get the choice to debug and
the report just seems to hang. Right now this is all just on my one
development PC (when I'm deploying I'm actually just deploying it to my
development machines version of reporting services).
Any thoughts on the problem or how to debug a deployed custom extension?
Cheers!Hi Cayman:
You might have to use Debugger.Launch if the debugger is not already
attached (which you can check with the Debugger.IsAttached property).
Is this in a custom assembly? Let me know if this works, I might check
it out later this evening. I imagine there still might be a problem
since the reporting service has it's own desktop / winsation where GUI
elements appear that are invisible to the logged in user. An old
school solution to this problem is to run as Local System and check
"Allow service to interact with desktop", but running as Local System
is risky, and allowing a service to interact with the desktop is even
riskier, because a malicious program could start pumping Windows
messages into the service.
--
Scott
http://www.OdeToCode.com/blogs/scott/
On Thu, 11 Nov 2004 07:00:06 -0800, "Cayman Visitor" <Cayman
Visitor@.discussions.microsoft.com> wrote:
>I have a custom data extension I'm working on. I can debug this when the
>report using it is being designed by adding a line in the code for the
>extension like:
>System.Diagnostics.Debugger.Break();
>When I then run the report in design mode I'll get a choice of debuggers and
>I can then open one and debug the extension.
>However, if I then deploy the report (with
>System.Diagnostics.Debugger.Break(); still in the code) and run the report
>from say Report Manager or just via URL I don't get the choice to debug and
>the report just seems to hang. Right now this is all just on my one
>development PC (when I'm deploying I'm actually just deploying it to my
>development machines version of reporting services).
>Any thoughts on the problem or how to debug a deployed custom extension?
>Cheers!