Sorry to bug people, I searched google and the newsgroups but the
problem is that there is so much about the Slammer Worm that I was
just getting all those hits.
Is there a command or function in MS SQL Server to send a UDP packet
from a stored procedure similar to syb_sendmsg?
Something like syb_sendmsg(w.x.y.z, portnum, @.stringbuf)
http://manuals.sybase.com/onlinebooks/group-as/asg1250e/refman/@.Generic__BookTextView/21457;pt=5472
I have some monitoring projects and I would like to code them
similarly using sybase and MS SQL Server, I don't have much experience
with MS SQL Server but have tons with sybase. I was also not able to
find any good online command/function references, I guess I am spoiled
by the Sybase online and pdf manuals.
TIA for any help on either of those topics.Hi,
Use the procedure "sp_add_notification" to send a notification .The details
and usage you can get from books online.
You could install the SQL server 2000 books online. DOwnload the books
online form below link:-
http://www.microsoft.com/sql/techinfo/productdoc/2000/books.asp
Could you install the latest service pack in your server to secure your sql
server from Slammer. Download and install the
sp3a from below link.
http://www.microsoft.com/sql/downloads/2000/sp3.asp
Thanks
Hari
MCDBA
"forsale" <google.20.webinfo@.xoxy.net> wrote in message
news:b754dde0.0407251800.20129d4d@.posting.google.com...
> Sorry to bug people, I searched google and the newsgroups but the
> problem is that there is so much about the Slammer Worm that I was
> just getting all those hits.
> Is there a command or function in MS SQL Server to send a UDP packet
> from a stored procedure similar to syb_sendmsg?
> Something like syb_sendmsg(w.x.y.z, portnum, @.stringbuf)
>
http://manuals.sybase.com/onlinebooks/group-as/asg1250e/refman/@.Generic__Boo
kTextView/21457;pt=5472
> I have some monitoring projects and I would like to code them
> similarly using sybase and MS SQL Server, I don't have much experience
> with MS SQL Server but have tons with sybase. I was also not able to
> find any good online command/function references, I guess I am spoiled
> by the Sybase online and pdf manuals.
> TIA for any help on either of those topics.|||Thanks, that might almost work, but I was really looking for something to send UDP.
"Hari Prasad" <hari_prasad_k@.hotmail.com> wrote in message news:<#T69eEscEHA.1356@.TK2MSFTNGP09.phx.gbl>...
> Hi,
>
> Use the procedure "sp_add_notification" to send a notification .The details
> and usage you can get from books online.
Showing posts with label bug. Show all posts
Showing posts with label bug. Show all posts
Monday, March 26, 2012
Friday, March 23, 2012
MS SQL SERVER 2005 BUG? Cannot insert NULL into column diagram_id
Hi friends,
when trying to save a diagram I got an error:
The sp_creatediagram procedure attempted to return a status of NULL, which is not allowed.
Whats with this??I had the same issue an just fixed it by turning the "diagram_id" field in SysDiagrams table to "identitity".
I dropped the table and ran the following script.
CREATE TABLE [dbo].[sysdiagrams](
[name] [nvarchar](128) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[principal_id] [int] NOT NULL,
[diagram_id] [int] identity(1,1),
[version] [int] NULL,
[definition] [varbinary](max) NULL
) ON [PRIMARY]
It worked.
when trying to save a diagram I got an error:
The sp_creatediagram procedure attempted to return a status of NULL, which is not allowed.
Whats with this??I had the same issue an just fixed it by turning the "diagram_id" field in SysDiagrams table to "identitity".
I dropped the table and ran the following script.
CREATE TABLE [dbo].[sysdiagrams](
[name] [nvarchar](128) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[principal_id] [int] NOT NULL,
[diagram_id] [int] identity(1,1),
[version] [int] NULL,
[definition] [varbinary](max) NULL
) ON [PRIMARY]
It worked.
Wednesday, March 21, 2012
MS SQL Server 2000 JDBC Driver setDate() bug report
Hi,
Recently, I found a bug in Microsoft's official SQL Server2000 JDBC driver.
It seemed to lie in the Statement's setDate() method. Maybe they simply assumed
all date are represented in 12-hours format.
The test code is below:
public void testMisc() throws Exception {
Connection conn = TransactionManager.getConnection();
String sql = "select count(salescheck0_.ID) as x0_0_ " +
"from T_CHK_OUT_BILL_TEST salescheck0_ " +
"where (salescheck0_.EX_TIME>?)" +
"and(salescheck0_.EX_TIME<?)";
PreparedStatement stmt = conn.prepareCall(sql);
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
Date timefrom = sdf.parse("2004-04-02 00:00:00.000");
Date timeto = sdf.parse("2004-04-02 23:00:00.000");
stmt.setDate(1, new java.sql.Date(timefrom.getTime()));
stmt.setDate(2, new java.sql.Date(timeto.getTime()));
// stmt.setString(1, "2004-04-02 00:00:00.000" );
// stmt.setString(2, "2004-04-02 23:59:59.000" );
ResultSet rs = stmt.executeQuery();
if(rs.next()) {
int count = rs.getInt(1);
System.out.println("count = " + count);
}
}
The test data is following:
ID, SO_ID,WH_ID,CLIENT_ID,CODE,OPERATOR,CHK_OUT_TIME, STATUS,CREATE_TIME,DELIVER_TYPE
86179,67521,1,661,SLCCK200404020016,xuwei,2004-4-2 12:15,20,2004-4-2 9:40,10
86229,67566,1,118,SLCCK200404020066,xuwei,2004-4-2 12:23,20,2004-4-2 9:41,10
86231,67568,1,130,SLCCK200404020068,xuwei,2004-4-2 12:23,20,2004-4-2 9:41,10
86232,67569,1,134,SLCCK200404020069,xuyili,2004-4-2 11:08,20,2004-4-2 9:41,10
86233,67571,1,151,SLCCK200404020070,xuwei,2004-4-2 12:23,20,2004-4-2 9:41,10
86234,67572,1,55,SLCCK200404020071,xuwei,2004-4-2 12:23,20,2004-4-2 9:41,10
86235,67573,1,71,SLCCK200404020072,xuwei,2004-4-2 12:23,20,2004-4-2 9:41,10
86252,67590,1,298,SLCCK200404020089,xuwei,2004-4-2 12:33,20,2004-4-2 9:41,10
86268,67576,1,25,SLCCK200404020105,xuwei,2004-4-2 12:23,20,2004-4-2 10:18,10
86269,67588,1,271,SLCCK200404020106,xuwei,2004-4-2 12:33,20,2004-4-2 10:20,10
86270,67506,1,42,SLCCK200404020107,xuwei,2004-4-2 12:15,20,2004-4-2 10:21,10
86271,67531,1,751,SLCCK200404020108,xuyili,2004-4-2 11:28,20,2004-4-2 10:22,10
86272,67570,1,149,SLCCK200404020109,xuwei,2004-4-2 12:23,20,2004-4-2 10:29,10
86273,67600,1,6,SLCCK200404020110,xuwei,2004-4-2 12:15,20,2004-4-2 10:40,10
86373,67665,3,686,SLCCK200404020210,root,2004-4-2 17:18,20,2004-4-2 16:32,10
86374,67657,3,883,SLCCK200404020211,root,2004-4-2 17:18,20,2004-4-2 16:32,10
86375,67666,3,686,SLCCK200404020212,root,2004-4-2 17:18,20,2004-4-2 16:32,10
86376,54799,1,395,SLCCK200404020213,zhouliyi,2004-4-2 19:52,20,2004-4-2 19:51,10
86377,55383,1,341,SLCCK200404020214,zhoulingyi,200 4-4-2 19:52,20,2004-4-2 19:51,10
Given the code and data, the expected output ought to be "count = 19"
But it's "count = 19" instead.
However, if you set date by using alternative method like the commented statements,
you can get the correct result.
Does anybody know if there exists any patch?
Could we expect Mircosoft to fix this bug? If so, where could I submit this bug report?
Regards,
JustinWhich version of the Microsoft JDBC Driver are you using?|||Originally posted by peterlemonjello
Which version of the Microsoft JDBC Driver are you using?
Don't know very clearly.
It may be rather old.
We have used it for about 2 years.
I notice there is a SP2 of MS SQL Server 2000 JDBC driver.
I'll try it immediately, and feedback ASAP.
Regards,
Justin|||Given the code and data, the expected output ought to be "count = 19"
But it's "count = 19" instead.
So what's wrong with that?sql
Recently, I found a bug in Microsoft's official SQL Server2000 JDBC driver.
It seemed to lie in the Statement's setDate() method. Maybe they simply assumed
all date are represented in 12-hours format.
The test code is below:
public void testMisc() throws Exception {
Connection conn = TransactionManager.getConnection();
String sql = "select count(salescheck0_.ID) as x0_0_ " +
"from T_CHK_OUT_BILL_TEST salescheck0_ " +
"where (salescheck0_.EX_TIME>?)" +
"and(salescheck0_.EX_TIME<?)";
PreparedStatement stmt = conn.prepareCall(sql);
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
Date timefrom = sdf.parse("2004-04-02 00:00:00.000");
Date timeto = sdf.parse("2004-04-02 23:00:00.000");
stmt.setDate(1, new java.sql.Date(timefrom.getTime()));
stmt.setDate(2, new java.sql.Date(timeto.getTime()));
// stmt.setString(1, "2004-04-02 00:00:00.000" );
// stmt.setString(2, "2004-04-02 23:59:59.000" );
ResultSet rs = stmt.executeQuery();
if(rs.next()) {
int count = rs.getInt(1);
System.out.println("count = " + count);
}
}
The test data is following:
ID, SO_ID,WH_ID,CLIENT_ID,CODE,OPERATOR,CHK_OUT_TIME, STATUS,CREATE_TIME,DELIVER_TYPE
86179,67521,1,661,SLCCK200404020016,xuwei,2004-4-2 12:15,20,2004-4-2 9:40,10
86229,67566,1,118,SLCCK200404020066,xuwei,2004-4-2 12:23,20,2004-4-2 9:41,10
86231,67568,1,130,SLCCK200404020068,xuwei,2004-4-2 12:23,20,2004-4-2 9:41,10
86232,67569,1,134,SLCCK200404020069,xuyili,2004-4-2 11:08,20,2004-4-2 9:41,10
86233,67571,1,151,SLCCK200404020070,xuwei,2004-4-2 12:23,20,2004-4-2 9:41,10
86234,67572,1,55,SLCCK200404020071,xuwei,2004-4-2 12:23,20,2004-4-2 9:41,10
86235,67573,1,71,SLCCK200404020072,xuwei,2004-4-2 12:23,20,2004-4-2 9:41,10
86252,67590,1,298,SLCCK200404020089,xuwei,2004-4-2 12:33,20,2004-4-2 9:41,10
86268,67576,1,25,SLCCK200404020105,xuwei,2004-4-2 12:23,20,2004-4-2 10:18,10
86269,67588,1,271,SLCCK200404020106,xuwei,2004-4-2 12:33,20,2004-4-2 10:20,10
86270,67506,1,42,SLCCK200404020107,xuwei,2004-4-2 12:15,20,2004-4-2 10:21,10
86271,67531,1,751,SLCCK200404020108,xuyili,2004-4-2 11:28,20,2004-4-2 10:22,10
86272,67570,1,149,SLCCK200404020109,xuwei,2004-4-2 12:23,20,2004-4-2 10:29,10
86273,67600,1,6,SLCCK200404020110,xuwei,2004-4-2 12:15,20,2004-4-2 10:40,10
86373,67665,3,686,SLCCK200404020210,root,2004-4-2 17:18,20,2004-4-2 16:32,10
86374,67657,3,883,SLCCK200404020211,root,2004-4-2 17:18,20,2004-4-2 16:32,10
86375,67666,3,686,SLCCK200404020212,root,2004-4-2 17:18,20,2004-4-2 16:32,10
86376,54799,1,395,SLCCK200404020213,zhouliyi,2004-4-2 19:52,20,2004-4-2 19:51,10
86377,55383,1,341,SLCCK200404020214,zhoulingyi,200 4-4-2 19:52,20,2004-4-2 19:51,10
Given the code and data, the expected output ought to be "count = 19"
But it's "count = 19" instead.
However, if you set date by using alternative method like the commented statements,
you can get the correct result.
Does anybody know if there exists any patch?
Could we expect Mircosoft to fix this bug? If so, where could I submit this bug report?
Regards,
JustinWhich version of the Microsoft JDBC Driver are you using?|||Originally posted by peterlemonjello
Which version of the Microsoft JDBC Driver are you using?
Don't know very clearly.
It may be rather old.
We have used it for about 2 years.
I notice there is a SP2 of MS SQL Server 2000 JDBC driver.
I'll try it immediately, and feedback ASAP.
Regards,
Justin|||Given the code and data, the expected output ought to be "count = 19"
But it's "count = 19" instead.
So what's wrong with that?sql
Monday, February 20, 2012
MS Scripting bug
SQL Server 2005
I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
(after both specifying 2000 in the scripting options and
setting database compatibility to 80) still used sys.objects and WITH
(IGNORE_DUP_KEY = OFF).
Since I wasn't expecting it, it was kind of a pain.
If this is, in fact, a bug, where would I report it?
You can report it at http://connect.microsoft.com
Jason Massie
Web: http://statisticsio.com
RSS: http://statisticsio.com/Home/tabid/36/rssid/1/Default.aspx
"Jay" <nospam@.nospam.org> wrote in message
news:%233LgD74NIHA.3852@.TK2MSFTNGP06.phx.gbl...
> SQL Server 2005
> I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
> (after both specifying 2000 in the scripting options and
> setting database compatibility to 80) still used sys.objects and WITH
> (IGNORE_DUP_KEY = OFF).
> Since I wasn't expecting it, it was kind of a pain.
> If this is, in fact, a bug, where would I report it?
>
|||Hi Jay,
I tried the same on SQL Server 2005 (Service Pack 2) and didnt find any
problem. Right click >>tasks>>generate scripts wizard generated the scripts
for indexes correctly for both 2000 and 2005.
Not sure whether in SP 2 MS resolved it.
Manu
"Jay" wrote:
> SQL Server 2005
> I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
> (after both specifying 2000 in the scripting options and
> setting database compatibility to 80) still used sys.objects and WITH
> (IGNORE_DUP_KEY = OFF).
> Since I wasn't expecting it, it was kind of a pain.
> If this is, in fact, a bug, where would I report it?
>
>
I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
(after both specifying 2000 in the scripting options and
setting database compatibility to 80) still used sys.objects and WITH
(IGNORE_DUP_KEY = OFF).
Since I wasn't expecting it, it was kind of a pain.
If this is, in fact, a bug, where would I report it?
You can report it at http://connect.microsoft.com
Jason Massie
Web: http://statisticsio.com
RSS: http://statisticsio.com/Home/tabid/36/rssid/1/Default.aspx
"Jay" <nospam@.nospam.org> wrote in message
news:%233LgD74NIHA.3852@.TK2MSFTNGP06.phx.gbl...
> SQL Server 2005
> I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
> (after both specifying 2000 in the scripting options and
> setting database compatibility to 80) still used sys.objects and WITH
> (IGNORE_DUP_KEY = OFF).
> Since I wasn't expecting it, it was kind of a pain.
> If this is, in fact, a bug, where would I report it?
>
|||Hi Jay,
I tried the same on SQL Server 2005 (Service Pack 2) and didnt find any
problem. Right click >>tasks>>generate scripts wizard generated the scripts
for indexes correctly for both 2000 and 2005.
Not sure whether in SP 2 MS resolved it.
Manu
"Jay" wrote:
> SQL Server 2005
> I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
> (after both specifying 2000 in the scripting options and
> setting database compatibility to 80) still used sys.objects and WITH
> (IGNORE_DUP_KEY = OFF).
> Since I wasn't expecting it, it was kind of a pain.
> If this is, in fact, a bug, where would I report it?
>
>
MS Scripting bug
SQL Server 2005
I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
(after both specifying 2000 in the scripting options and
setting database compatibility to 80) still used sys.objects and WITH
(IGNORE_DUP_KEY = OFF).
Since I wasn't expecting it, it was kind of a pain.
If this is, in fact, a bug, where would I report it?You can report it at http://connect.microsoft.com
Jason Massie
Web: http://statisticsio.com
RSS: http://statisticsio.com/Home/tabid/.../1/Default.aspx
"Jay" <nospam@.nospam.org> wrote in message
news:%233LgD74NIHA.3852@.TK2MSFTNGP06.phx.gbl...
> SQL Server 2005
> I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
> (after both specifying 2000 in the scripting options and
> setting database compatibility to 80) still used sys.objects and WITH
> (IGNORE_DUP_KEY = OFF).
> Since I wasn't expecting it, it was kind of a pain.
> If this is, in fact, a bug, where would I report it?
>|||Hi Jay,
I tried the same on SQL Server 2005 (Service Pack 2) and didnt find any
problem. Right click >>tasks>>generate scripts wizard generated the scripts
for indexes correctly for both 2000 and 2005.
Not sure whether in SP 2 MS resolved it.
Manu
"Jay" wrote:
> SQL Server 2005
> I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
> (after both specifying 2000 in the scripting options and
> setting database compatibility to 80) still used sys.objects and WITH
> (IGNORE_DUP_KEY = OFF).
> Since I wasn't expecting it, it was kind of a pain.
> If this is, in fact, a bug, where would I report it?
>
>
I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
(after both specifying 2000 in the scripting options and
setting database compatibility to 80) still used sys.objects and WITH
(IGNORE_DUP_KEY = OFF).
Since I wasn't expecting it, it was kind of a pain.
If this is, in fact, a bug, where would I report it?You can report it at http://connect.microsoft.com
Jason Massie
Web: http://statisticsio.com
RSS: http://statisticsio.com/Home/tabid/.../1/Default.aspx
"Jay" <nospam@.nospam.org> wrote in message
news:%233LgD74NIHA.3852@.TK2MSFTNGP06.phx.gbl...
> SQL Server 2005
> I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
> (after both specifying 2000 in the scripting options and
> setting database compatibility to 80) still used sys.objects and WITH
> (IGNORE_DUP_KEY = OFF).
> Since I wasn't expecting it, it was kind of a pain.
> If this is, in fact, a bug, where would I report it?
>|||Hi Jay,
I tried the same on SQL Server 2005 (Service Pack 2) and didnt find any
problem. Right click >>tasks>>generate scripts wizard generated the scripts
for indexes correctly for both 2000 and 2005.
Not sure whether in SP 2 MS resolved it.
Manu
"Jay" wrote:
> SQL Server 2005
> I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
> (after both specifying 2000 in the scripting options and
> setting database compatibility to 80) still used sys.objects and WITH
> (IGNORE_DUP_KEY = OFF).
> Since I wasn't expecting it, it was kind of a pain.
> If this is, in fact, a bug, where would I report it?
>
>
MS Scripting bug
SQL Server 2005
I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
(after both specifying 2000 in the scripting options and
setting database compatibility to 80) still used sys.objects and WITH
(IGNORE_DUP_KEY = OFF).
Since I wasn't expecting it, it was kind of a pain.
If this is, in fact, a bug, where would I report it?You can report it at http://connect.microsoft.com
--
Jason Massie
Web: http://statisticsio.com
RSS: http://statisticsio.com/Home/tabid/36/rssid/1/Default.aspx
"Jay" <nospam@.nospam.org> wrote in message
news:%233LgD74NIHA.3852@.TK2MSFTNGP06.phx.gbl...
> SQL Server 2005
> I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
> (after both specifying 2000 in the scripting options and
> setting database compatibility to 80) still used sys.objects and WITH
> (IGNORE_DUP_KEY = OFF).
> Since I wasn't expecting it, it was kind of a pain.
> If this is, in fact, a bug, where would I report it?
>|||Hi Jay,
I tried the same on SQL Server 2005 (Service Pack 2) and didnt find any
problem. Right click >>tasks>>generate scripts wizard generated the scripts
for indexes correctly for both 2000 and 2005.
Not sure whether in SP 2 MS resolved it.
Manu
"Jay" wrote:
> SQL Server 2005
> I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
> (after both specifying 2000 in the scripting options and
> setting database compatibility to 80) still used sys.objects and WITH
> (IGNORE_DUP_KEY = OFF).
> Since I wasn't expecting it, it was kind of a pain.
> If this is, in fact, a bug, where would I report it?
>
>
I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
(after both specifying 2000 in the scripting options and
setting database compatibility to 80) still used sys.objects and WITH
(IGNORE_DUP_KEY = OFF).
Since I wasn't expecting it, it was kind of a pain.
If this is, in fact, a bug, where would I report it?You can report it at http://connect.microsoft.com
--
Jason Massie
Web: http://statisticsio.com
RSS: http://statisticsio.com/Home/tabid/36/rssid/1/Default.aspx
"Jay" <nospam@.nospam.org> wrote in message
news:%233LgD74NIHA.3852@.TK2MSFTNGP06.phx.gbl...
> SQL Server 2005
> I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
> (after both specifying 2000 in the scripting options and
> setting database compatibility to 80) still used sys.objects and WITH
> (IGNORE_DUP_KEY = OFF).
> Since I wasn't expecting it, it was kind of a pain.
> If this is, in fact, a bug, where would I report it?
>|||Hi Jay,
I tried the same on SQL Server 2005 (Service Pack 2) and didnt find any
problem. Right click >>tasks>>generate scripts wizard generated the scripts
for indexes correctly for both 2000 and 2005.
Not sure whether in SP 2 MS resolved it.
Manu
"Jay" wrote:
> SQL Server 2005
> I generated some DDL in 2005 MS (Tasks->Scripting) the DDL it generated
> (after both specifying 2000 in the scripting options and
> setting database compatibility to 80) still used sys.objects and WITH
> (IGNORE_DUP_KEY = OFF).
> Since I wasn't expecting it, it was kind of a pain.
> If this is, in fact, a bug, where would I report it?
>
>
Subscribe to:
Posts (Atom)