Interesting SQL Injection Reported

May 26, 2008

All of you just read this article

http://www.bloombit.com/Articles/2008/05/ASCII-Encoded-Binary-String-Automated-SQL-Injection.aspx

View 1 Replies


ADVERTISEMENT

CHECKDB Errors Reported

Dec 2, 2005

I actually ran this on a reporting copy of my DB (restored once a week). I would guess the errors are present in the main copy as well. I fear running the check during production hours as it takes 2.5 hours and the system (4 processor) is under a lot of load for almost the entire day and much of the night.

So I've got errors on the tables:

sessions ID(462624691)
map ID(510624862)
links ID(1790629422)

It looks like the repair with data loss is my only choice but I would definitely prefer to know which rows are messed up. I'm also wary of running the repair as it's probably going to take well over an hour on the huge sessions table. I don't know how it got in this corrupted state. I inherited a DB of this size (50GB) that's been known to be very sensitive to any admin or index fiddling due to the high load. After I get this repaired I feel I should run the CHECKDB in a maintenance plan but I'm not sure if this will cause slowdowns in itself if it runs for 2.5 hours. The DB backup takes over 2 hours leaving almost no spare time in the off peak time.

Any advice/suggestions? Thanks.

DBCC results for 'dbloc'.

DBCC results for 'sessions'.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 462624691, index ID 0: Page (1:9517861) could not be processed. See other errors for details.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 462624691, index ID 0: Page (1:9659261) could not be processed. See other errors for details.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 462624691, index ID 7: Page (1:5825743) could not be processed. See other errors for details.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 462624691, index ID 7: Page (1:5890660) could not be processed. See other errors for details.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 462624691, index ID 7: Page (1:5931145) could not be processed. See other errors for details.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 462624691, index ID 7: Page (1:5950021) could not be processed. See other errors for details.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 462624691, index ID 7: Page (1:5978420) could not be processed. See other errors for details.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 462624691, index ID 7: Page (1:5988261) could not be processed. See other errors for details.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 462624691, index ID 7: Page (1:6046306) could not be processed. See other errors for details.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 510624862, Index ID 0. Keys out of order on page (1:11853027), slots 109 and 110.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 510624862, Index ID 0. Keys out of order on page (1:11853027), slots 112 and 113.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 510624862, Index ID 0. Keys out of order on page (1:11853027), slots 113 and 114.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 510624862, Index ID 0. Keys out of order on page (1:11853027), slots 114 and 115.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 510624862, Index ID 0. Keys out of order on page (1:11853027), slots 117 and 118.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 510624862, Index ID 0. Keys out of order on page (1:11853027), slots 118 and 119.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 510624862, Index ID 0. Keys out of order on page (1:11853027), slots 121 and 122.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 510624862, Index ID 0. Keys out of order on page (1:11853027), slots 122 and 123.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 510624862, Index ID 0. Keys out of order on page (1:11853027), slots 124 and 125.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 510624862, index ID 0: Page (1:11858027) could not be processed. See other errors for details.
Server: Msg 8939, Level 16, State 1, Line 1
Table error: Object ID 510624862, index ID 0, page (1:11858027). Test (IS_ON (BUF_IOERR, bp->bstat) &&bp->berrcode) failed. Values are 2057 and -1.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 510624862, index ID 0: Page (1:11865547) could not be processed. See other errors for details.
Server: Msg 8939, Level 16, State 1, Line 1
Table error: Object ID 510624862, index ID 0, page (1:11865547). Test (IS_ON (BUF_IOERR, bp->bstat) &&bp->berrcode) failed. Values are 2057 and -1.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 510624862, index ID 2: Page (1:11889147) could not be processed. See other errors for details.
DBCC results for 'sessions'.
There are 153364096 rows in 3102681 pages for object 'sessions'.
CHECKDB found 0 allocation errors and 9 consistency errors in table 'sessions' (object ID 462624691).
DBCC results for 'map'.
Server: Msg 8939, Level 16, State 98, Line 1
Table error: Object ID 510624862, index ID 2, page (1:11889147). Test (IS_ON (BUF_IOERR, bp->bstat) &&bp->berrcode) failed. Values are 2057 and -1.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 510624862, Index ID 3. Keys out of order on page (1:11931268), slots 206 and 207.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 510624862, Index ID 3. Keys out of order on page (1:11931268), slots 209 and 210.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 510624862, Index ID 3. Keys out of order on page (1:11931268), slots 210 and 211.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 510624862, Index ID 3. Keys out of order on page (1:11931268), slots 230 and 231.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 510624862, index ID 11: Page (1:11988308) could not be processed. See other errors for details.
Server: Msg 8944, Level 16, State 1, Line 1
Table error: Object ID 510624862, index ID 11, page (1:11988308), row 194. Test (ColumnOffsets <= (nextRec - pRec)) failed. Values are 7251 and 18.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 510624862, index ID 11: Page (1:12003992) could not be processed. See other errors for details.
Server: Msg 8939, Level 16, State 1, Line 1
Table error: Object ID 510624862, index ID 11, page (1:12003992). Test (IS_ON (BUF_IOERR, bp->bstat) &&bp->berrcode) failed. Values are 2057 and -1.
There are 15576829 rows in 65455 pages for object 'map'.
CHECKDB found 0 allocation errors and 23 consistency errors in table 'map' (object ID 510624862).
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 1790629422, index ID 16: Page (1:11471717) could not be processed. See other errors for details.
Server: Msg 8944, Level 16, State 1, Line 1
Table error: Object ID 1790629422, index ID 16, page (1:11471717), row 88. Test (ColumnOffsets <= (nextRec - pRec)) failed. Values are 3500 and 28.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 1790629422, index ID 16: Page (1:11474112) could not be processed. See other errors for details.
Server: Msg 8944, Level 16, State 1, Line 1
Table error: Object ID 1790629422, index ID 16, page (1:11474112), row 108. Test (ColumnOffsets <= (nextRec - pRec)) failed. Values are 745 and 20.
DBCC results for 'links'.
There are 9919777 rows in 124284 pages for object 'links'.
CHECKDB found 0 allocation errors and 4 consistency errors in table 'links' (object ID 1790629422).
CHECKDB found 0 allocation errors and 36 consistency errors in database 'dbloc'.
repair_allow_data_loss is the minimum repair level for the errors found by DBCC CHECKDB (dbloc ).
DBCC execution completed. If DBCC printed error messages, contact your system administrator.

View 2 Replies View Related

All Sales Reported After Quarter End

Apr 19, 2007

It's been a long time since I've built tough queries and need some help.

I need to report all sales that happened within a quarter but were reported after the quarter end.

Quarters

Q1 - 1/1 thru 3/31
Q2 - 4/1 thru 6/30
Q3 - 7/1 thru 9/30
Q4 - 10/1 thru 12/31

Sample Data

ticketid salespersonid saledate sale_entereddate
1234 bsmith 1/1/2006 2/1/2006
1235 jgarcia 3/31/2006 4/1/2006
1236 bsmith 1/1/2006 2/3/2006
1237 jdoe 6/23/2006 7/1/2006
1238 bsmith 8/5/2006 8/6/2006
1239 bsmith 10/1/2006 1/1/2007

View 4 Replies View Related

Index Reported As Corrupt After Upgrading To 2005

Oct 30, 2006

After upgrading a server from SQL Server 2000 to 2005,
an index was suddenly being reported as corrupt in the SQL Server log
(probably every time an Insert was done). DBCC CHECKDB / CHECKTABLE
reported no errors, with or without the new WITH DATA_PURITY option.

Anyone else experienced something similar?

How can an index be reported as corrupt when DBCC doesn't report it?

Dropping and re-creating the index solved the problem.
I've restored a backup of the database (made before dropping/re-creating
the index) to try repeating the problem, but no success so far.

View 1 Replies View Related

SQL 2012 :: Incorrect Table Size Being Reported

Aug 15, 2014

I have a table that contains 1.6 million rows, and is about 2.6GB in size.One of the columns is ntext and contained some xml.Realistically, I don't need the xml for anything older than about 2 months, however, i'd like to keep some of the data in the other fields.I decided that if I updated the xml to blank, I would see some considerable space savings, however that doesn't appear to be the case.This is the output of sp_spaceused for my table

name rows reserved data index unused
CommitmentsForPosting1660979 2740336 KB 1857104 KB312 KB882920 KB

After I updated the table to remove the xml, the output of sp_spaceused remained the same.My first thought was that it was probably statistics, so I updated statistics for the table, and nothing changed.I then updated statistics for everything in the database, still no change.I then ran DBCC CLEANTABLE for that table. I didn't really expect it to make a difference, and no surprise, it didn't.

The index on the table is a clustered index on just a GUID column.I rebuilt the index and again it still made no difference (that's a bit of a lie - index_size changed by a few hundred KB)my next test was to run 'select * into XXX from YYY' to create a copy of this table with the same data and data types. I also created the same clustered index from the original table onto the new one.If I then run sp_spaceused on this new copy of the table, I see what I expect to see in sp_spaceused - a table using approximately 256MB of space

name rows reserved data index unused
SPS_TEST 1660979 266400 KB 266400 KB 304 KB56 KB

To be honest, this isn't hugely critical, but I'm just curious as to why the original table is still reporting 2.6GB size, when I think it should probably be nearer 256MB.

View 9 Replies View Related

The OLE DB Provider ....reported An Error. Access Denied.

Dec 27, 2007

I'm trying to export excel data to a SQL Server database as:

SELECT * FROM OPENROWSET('Microsoft.ACE.OLEDB.12.0',
'Excel 12.0;Database=D:DATA_SOURCEData2.xlsx', 'SELECT * FROM [Sheet1$');

I get errors:

Error Message: The OLE DB provider "Microsoft.ACE.OLEDB.12.0" for linked server "(null)" reported an error. Access denied.


Is there any reason for this error message? Thanks.

View 6 Replies View Related

Data Transfer Reported As Succesfull BUT Only One Row Is Ever Transfered!!

Apr 11, 2006

Hi,
I have SQL Server 2005 Developer Edition installed on my laptop. At this time, our servers here are currently running SQL Server 2000 Enterprise edition. When I try to use the DTS import/export wizard to transfer records between two SQL Server 2000 databases, SQL 2005 always reports the transfer as successful! Although when you check the destination table there is only ever 1 record transfered

This has happened every I have attempted, on any tables, are there any fixes to either perfmit the copy of all records or at least report the error condition that prevents records being transfered?

Regards

Colin

View 4 Replies View Related

BULK Insert Failure - OLE DB Provider &#39;STREAMS&#39; Reported An Error

Nov 1, 1999

Using BULK Insert with a format file I am receiving the following message:

Server: Msg 7399, Level 16, State 1, Line 1
OLE DB provider 'STREAMS' reported an error. The provider did not give any information about the error.
The statement has been terminated.

I am running SQL Server 7.0 w/ SP1 applied. The same data file and format files work fine if I use bcp.

The data file contains fixed length records.

Any ideas what the problem is?

View 2 Replies View Related

Email Subscription Reported As Successful But Not Arriving In Recipients Inbox.

Jan 24, 2007

I have a report that is sent via email to a list of recipients.  When I look at the subscription in 'My Subscriptions' the value in the Status column states that the message was 'sent successfully', however the email does not appear in the inboxes of any of the intended recipents.  The report renders OK via the browser and only takes a few seconds to process. The subscription exports the report as an Excel file.  The excel file is approx 8MB in size but this is still below the attachment size limit for internal emails within my organisation. The subscription is tied to a shared schedule. Other reports that are tied to the shared schedule are shown as successful in 'My Subscriptions' and also appear in the inboxes of recipients. All email address are correct.

I forgot to mention, the report was successfully received by all recipients until very recently and the report has not been modified since this time. 

Has anyone come across this problem before.

Thanks

 

Mike

 

View 3 Replies View Related

MSSQL Server 2005 Reported Account Locked Out For User 'sa'

Nov 29, 2006

Greetings,

I receive an error message in event log when i try to connect to the Database Server using ODBC on a client machine. The database server is running on Windows 2003 Server Standard Edition and the client machine is Windows XP Professional. Following is the error message from the event log:

2147467259 - [Microsoft][ODBC SQL Server Driver][SQL Server]Login failed for user 'sa' because the account is currently locked out. The system administrator can unlock it.

What causes the error to occur and how to resolve it?Appreciate for your assistence.

Thanks and regards,

Viknes

View 4 Replies View Related

VFPOLEDB For Linked Server Reported An Error. Access Denied

Jul 8, 2007

Hi Cindy,
After hours (days?) researching this, your name keeps popping up, you must be the GOTO person for VFP. So:

We have a server that runs a VFP application and stores .dbf free tables in a directory shared as F:apps ele.

I am working on an XPPro box running SQL Server Express 2005 using Management Studio Express.

I am logged on as a user with administrator rights for the domain

We would like to be able to query this data and move it to our SQL tables as needed.

Here is what I have:

EXEC sp_addlinkedserver @server = 'tele',
@srvproduct = 'VFP',
@provider = 'VFPOLEDB',
@datasrc = 'F:apps ele',
@provstr = 'VFPOLEDB.1'
GO

SELECT * FROM tele...PROSPECT_DIVU

Here is what I get:

Msg 7399, Level 16, State 1, Line 1
The OLE DB provider "VFPOLEDB" for linked server "tele" reported an error. Access denied.
Msg 7301, Level 16, State 2, Line 1
Cannot obtain the required interface ("IID_IDBCreateCommand") from OLE DB provider "VFPOLEDB" for linked server "tele".

I have tried:

exec sp_addlinkedsrvlogin
@rmtsrvname = 'tele',
@useself = false,
@locallogin = NULL,
@rmtuser = 'admin',
@rmtpassword = NULL
go

Same result.

I have also tried:

EXEC sp_addlinkedserver
'tele2',
'Jet 4.0',
'Microsoft.Jet.OLEDB.4.0',
'F:apps ele',
NULL,
'dBase IV'
GO

When I run:

select * from tele2...prospect_divu

I get:

OLE DB provider "Microsoft.Jet.OLEDB.4.0" for linked server "tele2" returned message "The Microsoft Jet database engine could not find the object 'prospect_divu'. Make sure the object exists and that you spell its name and the path name correctly.".
Msg 7311, Level 16, State 2, Line 1
Cannot obtain the schema rowset "DBSCHEMA_COLUMNS" for OLE DB provider "Microsoft.Jet.OLEDB.4.0" for linked server "tele2". The provider supports the interface, but returns a failure code when it is used.

What would you suggest?

View 4 Replies View Related

SQL Server 2008 :: Failed Task In Maintenance Plan Not Being Reported By Database Mail

Apr 29, 2015

I have inherited a server on which is a maintenance plan with two subplans on different schedules. In each subplan there are Execute T-SQL tasks with scripts for index rebuilds. Each task is set up with a Completion arrow to the next task and a Failure arrow to a Notify Operator Task. I was asked to add a task for index rebuilds to a specific subplan for a specific database, which is what the other tasks also do. I discovered that my task was failing but the others were fine. No notification was sent about my task failing even though the job is marked in MSDB as a failed job. I have sent a test email using the "Send Test Email..." option when right clicking Database Mail in SSMSand I receive an email so I know Database Mail works.

I set up a test job to model the index job that I can't get notifications from. I have two T-SQL tasks that just select the top row from a small table. The first task has a syntax error that I did so it would fail. I have a failure arrow to a Notify Operator Task and a Completion arrow to another T-SQL task with no syntax error which has a Success arrow to a Notify Operator task. As expected, when I execute this job I receive one failure email and one success email.

The only other troubleshooting step I know to try is to add a Notify Operator task before my failing task. That Notify Operator task will hopefully fire to tell me that the previous step was successful. I am not having problems with the other steps so I was just thinking I would try to get the subplan to send me a success email about one of the steps that has been working fine.

View 1 Replies View Related

Very Interesting !

Jun 12, 2004

Below is the statement given in MicroSoft SQL Server migration documentation :

"When a view is defined with an outer join and is queried with a qualification on a column from the inner table of the outer join, the results from SQL Server and Oracle can differ. In most cases, Oracle views are easily translated into SQL Server views"

Please can anyone explain the above with some examples. I don't find such a 'CREATE VIEW' statement existsing in two DBs, which results in different result set. Am I wrong ?

Thanks,
Sam

View 2 Replies View Related

Interesting

Aug 26, 2004

Another tech was having the same problem with his sp which he also made into a macro. He was having the same problem as I was, he thought since he made the user the dbo owner that he woud have no problems...but since hes the one who created the db and the stored procedures when the user tried to access it he got that same error message. It went away after he went into the Enterprise manager and in the properties of the stored procedure under permission he gave the user EXEC permissions...And WAAALLLAAA problem solved :):):):)

View 10 Replies View Related

Interesting SQL...

Oct 22, 2004

Anyone else experience this? A developer just finished complaining about the performance of one of our databases. Well, he sent me the query and I couldn't understand why it was such a dog. Anyways I rewrote it. The execution plan is totally different between the two. I had no idea specifying the join made such a difference. First sql executed in 7 minutes that 2nd took 1 second. SELECT dbo.contract_co.producer_num_id, contract_co_statusFROM dbo.contract_co, dbo.v_contract_co_statusWHERE ( dbo.v_contract_co_status.contract_co_id = dbo.contract_co.contract_co_id ) AND contract_co_status = 'Pending' OR ( contract_co_status = 'Active' and effective_date > '1/1/2004' )SELECT dbo.contract_co.producer_num_id, contract_co_statusFROM dbo.contract_co INNER JOIN dbo.v_contract_co_status ON dbo.contract_co.contract_co_id = dbo.v_contract_co_status.contract_co_idWHERE contract_co_status = 'Pending' OR ( contract_co_status = 'Active' and effective_date > '1/1/2004' )

View 3 Replies View Related

Interesting ID Issues...

Feb 1, 2007

Hi all,

I have a system in place currently that both a  local and a live database, currently the sales database is kept in line with a home grown "syncronise" script that controls keeping the two tables (live and local) in sync with the use of Local and Remote ID'sFor example;Table "Sales"ID - IntRemoteID - IntVarious Data fieldsThe 'Live' System writes new records using the RemoteID field, whilst the local inserts new records using the ID field. The Sync script copies the data up/down and assigns the corresponding RemoteID/ID's to the records as they are copied accordingly.Its been decided that this process must change, in favor of Two Way Replication. I have been tasked with finding the solution to the safe handling of ID's as theres a danger that two people can be writing a record (one live, one local) and possibly create the same ID's - i know that replication has its own ID's and could probably manage this well on its own, but these 'Internal' ID's have to be unique due to business rules.So i have been considering two possibilities to address this problem,1. Staggering the ID's - for instance Live ID's begin at 1,000,001 and local ID's begin at 1.2. Having a controlling ID table which provides the next IDBoth options have their advantages and disadvantages, with option 1 we will run into a problem later when the local ID's reach the 1 million mark (a few years away, i admit) and option 2 will need careful locking/transactional code to ensure the same ID isnt given twice.Does anyone have experience with this kind of issue? or could suggest an alternative approach to this problem?  Thanks in advance! 

View 2 Replies View Related

An Interesting Problem

Jan 3, 2001

We've had an interesting server issue here since about the start of the year, where the dual processor Netfinity server we've been running SQL 7 on has been holding steady at almost exactly 50% CPU utilization, give or take about 5%-10%. Disk utilization in all areas is relatively low. In fact, the server will do this right after a fresh reboot, with no users accessing. The really interesting part is that a graph of the two processors mirror each other. When the utilization of one goes up, the other goes down, almost perfectly. The two processors are the same speed, but their firmware build is different. IBM says it's not a problem. What say ye?

View 1 Replies View Related

Interesting Question!

Nov 28, 2001

If Query1 gives 1 row output as:

customer_id
1234
-------------------
Query2 gives 1 row output as:

product_id
8970
-------------------
How do we get the above results as a single result set of 2 columns side by side? as follows:

customer_id product_id
1234 8970


Is that possible in a single select statement??
Query1 and Query2 both are select statements on the same table with different where clauses.

Sheila.

View 2 Replies View Related

Interesting Problem

Jul 14, 1999

Hi ! I am facing an interesting problem for one of my databases. When I double click on a particular table in Enterprise Manager, the Manage Tables window shows me only one or two fields from the table. (it does not show me all the fields). When I run sp_help <tablename> in isql, all the information is displayed. Why is there such inconsistency. It happens only on one particular database. I have run DBCC commands but still no help. Does anyone have any ideas on this. Thankx,

View 3 Replies View Related

Interesting Challenge

Jul 12, 2005

We're having to work with some legacy data. The tables in the so-called database seem to have way more nulls than actual data. One table appears to have around 100 or more columns in it. It has close to 40,000 rows.

This Db has pretty much 0 normalization present.

IOW, your worst nightmare.

Is there a way we could run a query that would return the total number cells inthat contain NULL and another that could return the total number of data-bearing cells so we could come up with a % or a ratio.

View 9 Replies View Related

Folks ! Very Interesting !

Jun 8, 2004

Hi Folks,

This is a create table statement in DB2 z/ODS and OS/390 ( mainframe versions ) :

create table test(sno int) IN DATABASE database1 AUDIT NONE DATA CAPTURE NONE

This will create a table in the named database 'database1'.

1) In SQL Server, is there any equivalent for this 'IN DATABASE' syntax in DB2 ?

2) 'Data capture none' will not store any extra info about the data replication in the log files. Is there any eqiuivalent for this in SQL Server ?


Thanks,
Sam

View 1 Replies View Related

Interesting Error

Jan 10, 2008

In this SQL query I get en error like this:Incorrect syntax near ','.SELECT SUM(mCount * mPrice), CONVERT(DATEPART(yyyy, mDate), varchar) + '.' + CONVERT(DATEPART(mm, mDate), varchar) AS DateSoldFROM salesWHERE mDate BETWEEN '9/10/2007 0:0:0' AND '1/10/2008 23:59:59'I think you it isnt necessary to show values in the table because it is a syntax error but I dont undertand how it can be incorrect...Thanks for help...Saren Taşçıyan

View 14 Replies View Related

Interesting Problem

Jul 23, 2005

Imagine a table in Microsoft Sql Server 2000 named Pictures with threefields. A primary key ID(int), a Name(nvarchar) and a Picture(image)field.Lets put some records into the table. The first two fields as expectedwould take an int and a string. The third field is of type image.Instead of putting a bitmap in this field lets place an xml documentthat has been streamed into a byte array. The xml document woulddescribe the Picture using say lines. If the picture was that of asquare we would have four lines in the xml document. You could think ofthe xml document as something similar to vector graphics but thedetails are not relevant. The important fact is that the contents ofthe image field is NOT a bitmap but a binary stream of an xml document.Now imagine we have a reporting tool like Crystal Reports that can beused to report on this database table. Imagine we create a report byusing the three fields mentioned above. As far as Crystal is concernedthe first field is an int, the second a string and the third an image.If our table had ten records and we preview the report we like to see10 entries each consisting of an ID, Name and a Picture.This can only happen if the image field contains a Bitmap, but asmentioned above the field contains an xml document.Now my question...Can we write something in SQL Server 2000 (not 2005) to sit between thetable and Crystal Reports so to convert the XML document to a bitmap.The restriction is that we cannot use anything but sql server itself.The client in the above case has been Crystal Reports but it could beanything.I know SQL Server 2005 supports C# with access to the .NET frameworkwithin the database. Unfortunately, I am not using SQL server 2005.Some people have suggested the use of User Defined Functions and TSQL.I like to know from the more experienced SQL Server people if what I amtrying to achieve is possible. Maybe it has not been done but is itpossible?Any suggestions would be greatly appreciated...Many Regards

View 5 Replies View Related

Really Interesting Issue!

Sep 20, 2007



Hi All,

When I wanted to see ONLY today€™s records on the sql server, it took 5 minutes.
When I wanted to see records including today€™s records on the sql server, no problem. (19 Sep. is a past date which is working properly)
It is very interesting it takes 5 minutes to sort the lastday there is nothing wrong with the other days.
I ran DBCC INDEXDEFRAG method but no change anything.

I am wondering about something, everyday at 22:00 pm we are getting backup. Is this process creating a difference between before getting the back up and after got the backups?
It is really interesting issue. I do not know what I can say. It seems there is an issue with today€™s records. May be there are some locks on the today€™s records. I do not know. Why does not cause any issue for old dates but for current day ?



SELECT DISTINCT CallIDChar, ANI, DNIS, CallerName, AgentName, CallQueue, AgentID, CallType, CallStartTimeStamp, CallEndTimeStamp, CallDuration
FROM (SELECT MAINTBL.*, DRTTABLE.CallDuration AS CallDuration



FROM CallInfo AS MAINTBL

JOIN ( SELECT CallID, DateDiff(second, min(CallStartTimeStamp), max(CallEndTimeStamp)) as CallDuration


FROM CallInfo

GROUP BY CallID
) AS DRTTABLE ON MAINTBL.CallID=DRTTABLE.CallID
) as CallInfo

WHERE CallIDChar = CallIDChar


AND (CallStartTimeStamp >= '2007-09-20T00:00:00')

AND (CallStartTimeStamp <= '2007-09-20T23:59:59')

What can be reason for this issue and how can I solve it ?

Thank you in advance,

Melih

View 15 Replies View Related

An Interesting Bug For SSIS

Apr 12, 2007

I have a very simple SSIS package that imports data from ODBC source. There are two "Time" columns in source, but When this table is created in SQL2005, it give me "bigint"!!!



How can this happen?



I tried to import data to SQL2000, those two columns are created as "smalldatetime" properply.



Thanks.

View 11 Replies View Related

Interesting Challenge..

Aug 2, 2007

I am making a report in Visual Studio..Now my question is,is there anyway that i can add a tab control for my rdl??Hope to here from anyone out there with a know how..Thanks guys!!

View 13 Replies View Related

An Interesting Idea...

Jun 23, 2007

Having no more experience than reading books online, here is an interesting idea I would like to run by you guys and you can let me know if it is feasible or tell me I need to put the crack pipe down...



We are going to increase the number of disks in our SAN, and I was speaking with the SAN administrator and he mentioned the shuffling of logical drives to match the new space. He said he is going to have to go through quite a few combinations/permutations on figuring out the best configuration for what data goes on the old vs. new to get the optimal space.



Is this something that can be modeled out? I can write something that recursively figures it out, but why not explore fun ideas with tools that may be able to do it?



Thank you in advance,

John Hennesey

View 3 Replies View Related

SQL Injection Bug

Jul 4, 2006

This is my code:
CommandText = "SELECT * FROM Products"

If textboxStockID.Text.Length > 0 Then
CommandText = CommandText & " where [StockID] like '%" & textboxStockID.Text & "%'"
End If
Is this subject to the sql injection bug... if so, what changes do I need to make?
Canning

View 2 Replies View Related

SQL Injection

Nov 25, 2007

What is the best way to avoid SQL injection?I know not to do stuff in Visual Basic such as... 

Dim objCmd As New SqlCommand("SELECT * FROM mytable where id ='" & Request.QueryString("id") & '" , objConn)As it's best to use stored proceduresIs there any other problems you guys might have had happen to you or other possibilites for attackers that I should know about? Cheers  

View 6 Replies View Related

SQL Injection

Jun 5, 2008

I manage a VBSript/ASP/IIS/SQL website for a nonprofit, and our website has been hacked by SQL injections.  I have changed the code on the website so it can't access the database, cleaned the database, backed up the database, but now need to find a way to tighten up the security so it won't happen again.
We're a non-profit- so the server is Windows 2000 Terminal SP4 (yeah, I know, it's old, bear with me).
 I was using the following code to access the database from the website:
dbconn.open "DSN=cptigers;UID=sqlwebaccess;Password=password" (where cptigers is the name of the DSN connection with SQL server authentication).
So far, I've removed read permission in IIS on the include file that I use to open the database.  I've changed the data source to use Windows NT authentication, and set the SQL login MDBCA/cptigers (this is the IIS login) to have public and db_denydatawriter roles.
But I'm not sure how to call this database connection in the code (how do you define the IIS user and password?), and not sure if this is sufficient to protect from future SQL injections.
Am I heading the right direction?  Thanks, Amanda

View 4 Replies View Related

Help On SQL Injection...

Jun 16, 2005

Hi All:I can't seem to get this thing work... When I type this in a textbox : '; exec master.dbo.sp_addsrvrolemember 'redice','sysadmin' -- , there's no respond, I mean, I check redice's role, but the System Administrators is not checked.Any idea about this?Thanks in advance.

View 11 Replies View Related

SQL Injection ???

Jul 21, 2005

Hi All,
First explain the SQL Injection and how it working and second what is the Solution of SQL Injection..... ?
Thanx,
Shally

View 2 Replies View Related

Sql Injection

Aug 14, 2004

Hi there !

Can anyone put some more lights on SQL Injection ? Is there anyway to get rid of it ? If yes then please let me know ?

With Thanks !
sqlboy

View 5 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved