Archived Months
January 2003
June 2003
July 2003
August 2003
September 2003
October 2003
November 2003
December 2003
January 2004
February 2004
March 2004
April 2004
May 2004
June 2004
July 2004
August 2004
September 2004
October 2004
November 2004
December 2004
January 2005
February 2005
March 2005
April 2005
May 2005
June 2005
July 2005
August 2005
September 2005
October 2005
November 2005
December 2005
January 2006
February 2006
March 2006
April 2006
May 2006
June 2006
July 2006
August 2006
September 2006
October 2006
November 2006
December 2006
January 2007
February 2007
March 2007
April 2007
May 2007
June 2007
July 2007
August 2007
September 2007
October 2007
all groups > sql server (alternate) > may 2007

Filter by week: 1 2 3 4 5

Help on Partitioning column was not found.
Posted by Sonny at 5/31/2007 2:11:09 PM
Hi, I don't know if I missed anything. I have 2 member tables and one partition view in SQL 2000 defined as following CREATE VIEW Server1.dbo.UTable AS SELECT * FROM Server1..pTable1 UNION ALL SELECT * FROM Server2..pTable2 CREATE TABLE pTable1 ( [ID1] [int] IDENTITY (1000, 2) NO...more >>


DTS w/ Oracle Issue
Posted by Jimbo at 5/31/2007 11:31:10 AM
Im having an issue with DTS and I dont know if anyone else has experienced this...In my transformation I have a sql statement that executes against oracle..in it I'm selecting COUNT(DISTINCT I.PX_INVOICE_ID) ...however when the DTS package executes I get an error stating that "DISTINCTI"."PX_...more >>

How to distinguish operation type in trigger?
Posted by Hubert Trzewik at 5/31/2007 3:19:11 AM
Hi, I want to have all-in-one trigger, defined like this: CREATE TRIGGER MyInsertDeleteUpdateHandler ON MyTable FOR DELETE, INSERT, UPDATE AS BEGIN (...) END Now, how can I tell why this trigger was fired (what event caused trigger to be fired) - was it DELETE, INSERT or UPDATE? I...more >>

DOWNLOAD CRACKED 2007's SOFTWARE: ARCHICAD 11,UNIGRAPHICS NX5,SOLIDWORKS 2008,XSTEEL 13,AUTOCAD 2008
Posted by William Eistenach at 5/30/2007 9:50:00 PM
Our team provide different types of services such as: - proffessional cracking of any kind of software (CAD,CAM,CAE,EDA,GIS,PCB,FEA,FEM,CNC,CFD,PDS,3D,Optics etc.) designed for any kind of operating systems(Windows 95/98/ME/2000/XP, Linux, FreeBSD, OS/2, MAC OS etc.) - producing key...more >>

SQL Enterprise Manager - Not very usefull tool for building views
Posted by grant NO[at]SPAM technologyworks.co.nz at 5/29/2007 3:34:26 PM
Man do I struggle with Enterprise Manager as a graphical tool for building views etc. Its flaky and hangs frequenlty so i have to kill it with the task manager and re open it. You cant debug functions ( or am I missing something) But the worst thing is that it appears to cache the results...more >>

Book recall
Posted by --CELKO-- at 5/29/2007 11:11:21 AM
Copies of my book "Analytics & OLAP in SQL" have pages 13-44 missing and pages 61-92 printed twice. Please contact Morgan-Kaufmann or your book dealer for replacements. I cannot do anything (Remember the movie THE PRODUCERS? "Don't kill us [the producers]!! Kill the actors!!') ...more >>

sorting table while inserting
Posted by Oonz at 5/29/2007 9:04:02 AM
Hi Friends, How can we insert records in sorted order like consider a table No Name Phone 1 test1 12345 1 test1 23455 2 test2 68638 3 test3 67684 4 test4 54808 4 test4 74594 if i add a new record like this 2 test2 34454 it should go in specific order. so...more >>

Escaping international (unicode) characters in string
Posted by Greg R. Broderick at 5/29/2007 8:22:53 AM
Y'all: I am needing some way, in the SQL Server dialect of SQL, to escape unicode code points that are embedded within an nvarchar string in a SQL script, e.g. in Java I can do: String str = "This is a\u1245 test."; in Oracle's SQL dialect, it appears that I can accomplish the same thin...more >>



What do you think about the checksum function ?
Posted by Kurt at 5/29/2007 5:39:17 AM
Hi, I'd like advices about an idea I add to resolve a problem. thanks to you in advance for yours answers. I have a database with tables that I load with flat file. The size of each table is 600 Mb. The flat file are the image of an application and there is no updated date or created date on ...more >>

Transpose column into rows
Posted by Oonz at 5/29/2007 2:52:43 AM
Hi Friends, How to transpose the columns into rows i want to convert the table which looks like this ID Name HomePhone WorkPhone Email 1 test1 678364 643733 test1@test.com 2 test2 678344 643553 test2@test.com to a table which should look like this ID Name...more >>

needed: 1 + null = 1
Posted by info NO[at]SPAM vanoordt.nl at 5/29/2007 2:25:39 AM
Hi, I need this behaviour: 1 + null = 1 I have a (dynamic) set of many columns containing decimals that I want to add as follows: if all columns are null the result should be null if not all columns are null, the null columns may be regarded as 0. E.g. null + null + 1 = 1 null + null + n...more >>

ANN: SQL Monitor Version 2 has just been released
Posted by DBMonitor at 5/28/2007 10:43:30 PM
SQL Monitor version 2.0 has just been released. http://dbmonitor.tripod.com SQL Monitor is an application that displays performance statistics for sessions running on SQL Server databases. It has a very small footprint on the server yet displays all the information required for a DBA or da...more >>

Char or varchar for a primary key?
Posted by D. at 5/28/2007 12:00:00 AM
Hi, I'm planning the structure of a SqlServer 2005 database for a new application. The requirement is that primary keys must be "natural"; i.e. in the table Customers the primary key will be a max. 10 characters string (but the string may be filled i.e. with only 5 charachters). Should I ...more >>

SQLExpress
Posted by Shane at 5/25/2007 3:43:28 PM
I am trying to write an application for a MSSQL database, using SQL Express, and Visual Studio (Express edition) I tried to connect to an existing database (named testing) but to no avail. Visual Studio claims the database does not exist. Any ideas? TIA -- Q: What is the difference bet...more >>

uploading image files
Posted by M NO[at]SPAM at 5/25/2007 10:24:37 AM
I have a directory of files that I would like to upload with some data to a table so that I can store the files in the db. I'm not trying to parse files into rows, I want to stick the actual file in the column. Is there some kind of insert script, or bulk copy that I can use? I have about 150...more >>

Database design
Posted by KR at 5/25/2007 9:18:40 AM
Hi All, I wanted the expert opinion out there in the use of foreign keys as primary keys in a table. I am not very good at explaining this concept, but I am going to try - Let us say you have a parent/master table( Ex: purchase order) that is generating number (primary key for the main ta...more >>

Need Help with a SQL Statement - Trying not to use a Cursor
Posted by kyle.fitzgerald NO[at]SPAM gmail.com at 5/25/2007 5:16:25 AM
I'm just know basic SQL but not enough to write any complex queries. The problem I'm facing right now keeps me thinking to use a Cursor but I've seen a lot of posts on here saying Cursors are bad so I'm hoping there is a complex query that can give me the data I need. I have about 6 pages in w...more >>

Cluster IP address change and delay
Posted by aleu NO[at]SPAM vp.pl at 5/24/2007 4:20:37 PM
Hi all, I have recently changed IP addresses on my MS SQL cluster (the new IP addresses belongs to a different network). Both physical node's IP addresses and resource's IP addresses have been changed. Everything seems to work fine. The cluster is up and responding normally. The resource...more >>

Use CVS server with SQL Server
Posted by pipponec NO[at]SPAM libero.it at 5/24/2007 2:43:13 PM
Hi all! We are a little group of databases developers, we use SQL Server and we manage our source code with CVS. Actually, with enterprise manager we create the SQL script. This solution is very boring and error-friendly. Does anyone know of any tools available for manage easily databases ob...more >>

Query result sent via e-mail
Posted by Marco Garutti at 5/24/2007 9:22:42 AM
Hi all, I've a query running under MS SQLServer2000 (Stored Procedures). I'd like to send it's result via e-mail, formatting the output in txt form or html form. Someone knows how to do it ? Have you got examples of code ? Thanks for the advice Marco Garutti ...more >>

Any Input: Converting from Sybase to SQL
Posted by Monte Tiernan at 5/24/2007 9:22:39 AM

Remove neighbouring duplicates
Posted by mGracz at 5/24/2007 5:53:04 AM
Welcome, how can I alter following table in order to reduce neighbouring duplicates (symbol, position, quantity, price). Nr Symbol Position Quantity Price Date 1. wz9999b 1 1.0 2500.0 2007-05-09 08:09:42.653 2. ...more >>

Synchronous Bulk-Copy into two table
Posted by Khafancoder at 5/23/2007 7:03:07 PM
Hi guys, in my db i have these three tables 1.Stores 2.Products 3.Parts their structure is something like : Stores ----> Products ----> Parts Stores ---------------- StoreId, StoreName Products ---------------- ProductId, StoreId, ProductName Parts --------------...more >>

Question about Transaction isolation level="readCommitted"
Posted by D. at 5/23/2007 12:50:23 PM
I have a question about the "readCommitted" transaction isolation level. I have a client that is updating a record on a table. I suspend the execution after the UPDATE but before the commit statement. Than another client is trying to read the same record. As transaction isolation is set to...more >>

SUBSTRING in User Defined Function - Invalid column
Posted by jknaty at 5/23/2007 7:54:32 AM
I'm trying to create a function that splits up a column by spaces, and I thought creating a function that finds the spaces with CHARINDEX and then SUBSTRING on those values would an approach. I get an error saying that the I have an Invalid column 'Course_Number'. Not sure why but I am very ne...more >>

Finding values containing milli seconds!
Posted by Mohd Al Junaibi at 5/22/2007 11:49:33 PM
Hi all... I've got a group of tables and I wanted to first see which tables contained a fields containing the "Date/Time" data type. And I was successful in doing so...here's the query: ( select a.name tablename, b.name colname from sysobjects a, syscolumns b where a.name = object_...more >>

query on procedure
Posted by meendar at 5/22/2007 11:06:18 PM
Hi, Please see the below procedure. create procedure a1 as begin create table #table1 { empid int; empname varchar } insert into #table1 select empid,empname from employee where empcode='50' select e.* from employee e, #table1 as t1 where e.empid=t1.empid and e.empname=t1.em...more >>

Accessing SQL Server 2005 via Scheduled Task
Posted by Myster Edd at 5/22/2007 12:16:54 PM
I have a strange problem that I think deals with security on SQL 2005. I have a scheduled task that runs on a Windows 2000 machine. It calls a vb script which creates a connection to SQL Server. We migrated a database from SQL 2000 to 2005 which is on a different box. I changed the connection...more >>

Return data from multiple tables
Posted by Rafa³ Bielecki at 5/22/2007 11:03:59 AM
Hi there, I have tables with such structure transaction_YYMM (idx,date,company_id,value) where YYMM stands for 2digits year and month I want to define query (maybe view, procedure): select * from [???] where date>='2007-01-01' and date<='2007-04-30' which will grab data from transactio...more >>

Transaction log and tempdb
Posted by Kurt at 5/22/2007 9:20:31 AM
Hello I have questions about how works transaction log et the database tempdb in SQL Server and I hop you could help me - Is it possible to reduce the size of the transaction log fil during an execution ? Indeed, I have a script inserting a very large quantity of data (many Go) and during tha...more >>

constructing strings from table
Posted by Oonz at 5/22/2007 8:36:46 AM
Hi friends, please help me in selecting values from the table the record is as follows: Id HomePhone WorkPhone Mobile Email 20 2323223 323232232 test@test.com i have to select values as follows. Id DeviceType DeviceInfo ...more >>

Sql server 6.5 Enterprise Edtn Installation
Posted by Navshad Ali at 5/22/2007 7:41:44 AM
Dear friends, I am looking for step by step Process involved in installing Sql server 6.5 Enterprise Edition on Windows NT4.0 Enterprise Edition. Kindly please guide me towards the Correct Procedures involved. ...more >>

view of max values from many tables
Posted by M NO[at]SPAM at 5/22/2007 7:01:51 AM
I have about 14 tables that I am trying to tie together in a view to see a user's status in our company. Joe User: Email - Active ADP - Active Portal - Inactive etc. We need to track application access across the company, so we have tables for each application that contain user info(use...more >>

Getting Result of query inside another query
Posted by meendar at 5/22/2007 2:53:34 AM
Hi to all, I just need to get two fields from a table and manipulate the results in next query of a procedure.I planned to code like what you see below, create procedure marks1 as @ sql1 as varchar(50) @ sql1=select registerno ,subjectcode from mark; begin select * from marksett...more >>

Bulk insert, skip rows with duplicate key error?
Posted by nano at 5/21/2007 8:12:27 AM
Does sql server have a way to handle errors in a sproc which would allow one to insert rows, ignoring rows which would create a duplicate key violation? I know if one loops one can handle the error on a row by row basis. But is there a way to skip the loop and do it as a bulk insert? It's ea...more >>

SQL Query to insert data to a table
Posted by albertleng at 5/21/2007 8:03:20 AM
Hi all... Can anyone give clue in doing below? Let say i have a table A with the following 3 fields. 1)Date 2)Title 3)Status. i need to insert into table B (also have the same 3 fields) from this table A with the condition where Title is "Alarm" and Status is "ON". This can be done by...more >>

self referential database table
Posted by aakbar NO[at]SPAM gmail.com at 5/21/2007 5:28:14 AM
Hello every body, I need some clarification of concept regarding self referential tables. consider we have a "Person" table that stores data about employees of an organisation. in case a person change his name or any details we dont want to update our database by loosing old information an...more >>

Transaction log file size - does it do any harm?
Posted by Trevor Best at 5/21/2007 3:25:15 AM
I have a client with 150MB database, the transaction log file is nearly 23GB. It's a PITA for me to backup his data and restore it on my server as it takes about 30 minutes to restore as it re-creates a 23GB file with no transactions in it :-\ As well as the space taken up by it, does it do an...more >>

Trigger
Posted by Shane at 5/20/2007 2:55:20 PM
I have been instructed to write a trigger that effectively acts as a foreign key. The point (I think) is to get me used to writing triggers that dont use the primary key(s) I have created the following trigger create trigger chk_team on teams for insert as declare @chkCountry as char(2)...more >>

Moving SQL Server 2005 databases
Posted by bob66k88 NO[at]SPAM gmail.com at 5/19/2007 1:15:56 PM
What is the easiest way to move SQL Server 2005 databases from one old server to a new server? ...more >>

is there a way using sqlexpress to review the most recent set of sql commands submitted to a database?
Posted by Jeff Kish at 5/18/2007 4:23:44 PM
is there a way using sqlexpress to review the most recent set of sql commands submitted to a database? I remember something about setting up logging in sql server 2000, but don't see much about this on google or the news group for 2005. thanks Jeff Kish...more >>

Multiple values into single cell
Posted by NAJH at 5/18/2007 9:03:39 AM
Taking the Northwind database as an example, I have an order table: 'Orders' a order details table: 'Order Details' and a products table: 'Products' For reasons best ignored, I want to produce a query which has columns: Orders.OrderID, Products which has results like: 10248, 'Queso ...more >>

Server Hardware
Posted by John.Adams111 NO[at]SPAM gmail.com at 5/17/2007 2:10:41 PM
Just wondering, which server hardware do you guys use for SQL Servers - we use Dell, curious to know what you are using - John Adams ...more >>

SQL Server 2005 - > = 0 is not the same as > 0?
Posted by Hermes at 5/17/2007 9:25:49 AM
I have a statement in my code; Sum(CASE WHEN Rcv > 0 and Rcv < 100 THEN Rcv ELSE 0 END) as D100 It gives me a different number if I just add an "=" sign regarding the 0; Sum(CASE WHEN Rcv > = 0 and Rcv < 100 THEN Rcv ELSE 0 END) as D100 Does anyone know why this would happen? ...more >>

Optimalization - SELECT tatement
Posted by marianowic at 5/17/2007 3:50:01 AM
Hello everyone. I have got a simple question, but very important for me. I making a quite big report and I have a lot of conditions to compare. And I wonder, what is faster: One SELECT statement with three comparing conditions OR Three SELECTS, each with one comparing condition All the condit...more >>

SQL server 2000 - database problem
Posted by Jaros³aw Kozik at 5/16/2007 10:26:51 PM
my database status is suspect - what can I do to rebuilt it ( using enterprise manager or something else ) ? regards IJKK ...more >>

SqlServer 2005: How *best* to copy one database to another
Posted by Steve at 5/16/2007 10:09:34 AM
Hi; I thought I would rephrase a question I asked in another post to more quickly get to the heart of the matter. My apologies for anyone who is offended by what appears to be a repetition. My company has two identical web sites. One copy is for our customer, and one copy is for us to tes...more >>

SqlServer 2005: Importing Data: Idenitity fields getting made into non-identities
Posted by Steve at 5/16/2007 9:34:58 AM
Hi; We just migrated to SqlServer 2005. When I import tables from from SqlServer database into another the identity fields get switched off from being identities. How can I prevent that from happening? Thanks in advance for any information Steve ---------------------------...more >>

create constraint error
Posted by Jeff Kish at 5/16/2007 8:41:50 AM
Hi. I have a procedure with this in it (there are no other references to asset_number_bak_tmp_pk in the procedure and it calls nothing else written by me, just system calls or normal dml). create table #asset_bak( asset_number varchar(60) not null, asset_desc varchar(100) null, locatio...more >>

how to if needed recover from mistake
Posted by Jeff Kish at 5/16/2007 8:27:43 AM
Hi. I deleted a stored procedure (one I had written) out of the master database. I thought I had accidentally put it there, then I got to thinking.. what if it is normally reflected there, and maybe I should not of deleted it. So.. my question.. is it normal for procedures in other databases t...more >>


DevelopmentNow Blog