Groups | Blog | Home


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 2004 > threads for may 1 - 7, 2004

Filter by week: 1 2 3 4 5

sql server certifcation website wanted
Posted by surajfrommumbai NO[at]SPAM yahoo.com at 5/7/2004 8:05:51 PM
I am looking for sql server certifcation questions any one has any.like dumps or some thing...more >>

Disabilitazione trigger [DISABLE TRIGGER]
Posted by Pecos Bill at 5/7/2004 6:01:11 PM
Salve, non riesco a disabilitare un trigger su sqlserver nè da query analyzer, nè da enterprise manager. In pratica tal cosa riuscivo a farla in Oracle con TOAD, mentre qui non riesco. Mi interessa disattivarlo senza cancellarlo per poi riattivarlo al bisogno senza rilanciare lo script di creaz...more >>

Update query
Posted by Mansoor Azam at 5/7/2004 6:00:36 PM
I have 2 tables Create Table Orders ( OrderNo Long, Amount Double ) Create Table OrderDetails ( OrderNo Long, Item varchar(20), ItemAmount Double ) the sum of ItemAmount for all items in an order in OrderDetails should be equal to the Amount in Orders tab...more >>

floating point calculation
Posted by nevermind NO[at]SPAM iname.com at 5/7/2004 4:34:21 PM
I'm trying to perform a calculation on a field in SQL Server that should return a value with a decimal point. My problem is that the value returned is truncated without the decimal point. Is there a setting that needs to be turned on in SQL server to allow this? for example Select 20/3 ...more >>

PRIMARY file group is full
Posted by m3ckon at 5/7/2004 2:16:51 PM
Hi there, I've just run some DTS packages on my test sqlserver (Which has limited hard disk space and memory) and all the tasks have failed, due to 'PRIMARY' file group is full Is there a query or script I can run to resolve this problem?? M3ckon *** Sent via Developersdex http:/...more >>

System catalog tables?
Posted by newtophp2000 NO[at]SPAM yahoo.com at 5/7/2004 2:03:37 PM
Hello, I am relatively new to SQL Server, although I have used Oracle extensively. In Oracle, there are system tables that you can query in order to get a list of all schemas and all the tables in them. Is there a similar concept in SQLServer? How would I find about the system dictionary ...more >>

converting datetime int
Posted by androidsun NO[at]SPAM yahoo.com at 5/7/2004 1:42:04 PM
I have tables with columns that stores datetime data in int format on SQL server 2000. For example, the datetime for '4/5/2004 00:00:00.000am' is stored as 1081180800. "4/4/2004 11:59:59.000pm' is 1081180799. I need to generate reports that display datetime columns in "mm/dd/yyyy hh:mn:ss" fo...more >>

Maximum Date in a group of records
Posted by Rashid at 5/7/2004 11:59:52 AM
hi all, i got is table: Id StartDate EndDate a 19/03/2001 18/03/2002 a 19/03/2002 18/04/2002* b 13/08/2000 12/08/2001 b 13/08/2001 12/08/2002 b 13/08/2002 10/07/2002* Sort command and groupins i am ok but i need to select only the records that has the latest enddate. (...more >>



1-multiple to string
Posted by Yannick Turgeon at 5/7/2004 10:55:49 AM
Hello all, I'm using SS 2000 and NT4. Say I've got three tables: T1, T2 and T3. T3 contains the 1-to-multiple data of the relation between T1 and T2: ------------------------------------------------ CREATE TABLE #T1( T1PK INTEGER NOT NULL PRIMARY KEY, Name VARCHAR(3) NOT NULL )...more >>

Update in SQL Server 2000 slow?
Posted by dberlin NO[at]SPAM alum.rpi.edu at 5/7/2004 10:38:19 AM
I have two tables: T1 : Key as bigint, Data as char(20) - size: 61M records T2 : Key as bigint, Data as char(20) - size: 5M records T2 is the smaller, with 5 million records. They both have clustered indexes on Key. I want to do: update T1 set Data = T2.Data from T2 where T2.Key = ...more >>

UPDATE query problem
Posted by Chris Michael at 5/7/2004 10:34:35 AM
I've only just started using update queries and have a problem with the following query in that it comes back with this error: "Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression." Query: UP...more >>

Thoughts about the smart way to a task
Posted by stevesusenet NO[at]SPAM yahoo.com at 5/7/2004 9:52:43 AM
I'm still a database newbie so I would like to solicit thoughts about the smartest way to do something in sqlserver. My company has a web application that we customize for each client. We can do this because everything is database driven. We have database tables that contain our HTML and da...more >>

Coding in standard SQL ?
Posted by stevesusenet NO[at]SPAM yahoo.com at 5/7/2004 9:35:01 AM
Hi; Is there an **easy** way to tell tsql apart from standard sql? Will sqlserver run scripts written only in standard sql? What about variable definitions? Thanks in advance Steve...more >>

displaying related data from a table
Posted by mharshareddy NO[at]SPAM yahoo.com at 5/7/2004 7:58:26 AM
Dear All, I am using a SQL server database with around 20 columns,all the columns have numeric values, I want to write an SQL statement which does the following: compare each row of the table with all other rows in the table and return all the rows that have a difference of + or - 0.5...more >>

Recursive Query
Posted by boblotz2001 NO[at]SPAM yahoo.com at 5/7/2004 7:14:42 AM
Hi there, Need a little help with a certain query that's causing a lot of acid in my stomach... Have a table that stores sales measures for a given client. The sales measures are stored per year and there could be multiple sales measures every year per client. There is another field calle...more >>

Can There be a single Index
Posted by vinay bhushan at 5/7/2004 4:16:44 AM
Can we make a Index on 2 or more tables Table a: Col1 int col2 varchar Table b: Col1 int col2 varchar can you have a single index for two tables a and b on the column Col1. Is this possible in SQL-Server. As far as i know you can make an index only on one Table. can the index b...more >>

Returning database schemas
Posted by sailent NO[at]SPAM hotmail.com at 5/6/2004 10:01:16 PM
Hi, I am storing information being sent to me weekly into a ms sql database. The one twist I am running into is that later down the line the information I recieve may require more columns, or columns might be renamed so having a static database call is out of the question. I was using mysql but ...more >>

How to ensure data is no longer on disk
Posted by sandell NO[at]SPAM pacbell.net at 5/6/2004 4:12:37 PM
I have a table with some sensitive customer data in it. I am now keeping all the data in another table, and encrypting it. I want to get rid of the original unencrypted data and be sure that it is no longer anywhere on disk. Should I drop the table, or first delete the rows and then do a dump...more >>

Hiding a SP in Access under Query, but retain Execute on SP
Posted by noloader NO[at]SPAM yahoo.com at 5/6/2004 3:31:59 PM
Hello, Access XP, SQL Server 2000 Is it possible to hide a SP under Queries in Access, yet still be able to Execute it from Access? We hooked up a custom form to accept the input parameters (MS Feature Request!) for the Stored Procedure. We had two problems with MS's 'Input Parameter' di...more >>

INSERT ... SELECT PROBLEM
Posted by m3ckon at 5/6/2004 3:26:50 PM
Hi there I have a stored procedure which uses an INSERT ... SELECT statement to transfer records from one table to another. However, I also need to insert an extra field to the table which is from a parameter @orderid ( the field is called orderid) Can someone tell me how this can be acheiv...more >>

Adding comments to TEXT field...
Posted by A. Nonymous at 5/6/2004 3:09:45 PM
Newbie question: Aside from the single quote (i.e. chr(39)) what other characters can cause MS-SQL server to cough-up the insertion / update back in your face? TIA ...more >>

Inserts failed sometimes ...
Posted by reisrf NO[at]SPAM yahoo.com at 5/6/2004 11:45:30 AM
We have installed a package developed by another company and sometimes (when the server is with a big rate of transactions), we are seeing the following messages in package debug file: 2004-04-22 14:23:27 3056: ------------------------------------------------------------ 2004-04-22 14:23:...more >>

DTS w/dynamic source & query
Posted by znelson NO[at]SPAM hpis.net at 5/6/2004 7:27:48 AM
I'm looking for a way to transform the contents of n source tables into a single destination table. This by itself is no problem. However, the name of the source tables change, so I'll need to base the transform task on a global variable that I can update via external code. Not sure how to do ...more >>

re-indexing job takes more time
Posted by soal6570 NO[at]SPAM yahoo.com at 5/5/2004 10:43:59 PM
We have a re-indexing all DBs schedule job in our SQL 2000 box, normally it took 7 hours to complete but all of the sudden now it takes more than 20 hours. What do you think it cause this problem? We have no clue....more >>

Column Count from Stored Procedure
Posted by rolandobarberis NO[at]SPAM hotmail.com at 5/5/2004 6:40:27 PM
I am trying to determine the number of columns that are returned from a stored procedure using TSQL. I have a situation where users will be creating their own procedures of which I need to call and place those results in a temp table. I will not be able to modify those users procedures. I figure...more >>

About MDF file
Posted by laurent leroy at 5/5/2004 5:25:36 PM
Hello, I want to open a mdf file but i don't no the database manager to do it. I suppose that solution is with vb and msde But i'm newbie thanks ...more >>

SS 2000 Backup programatically
Posted by Dirk McCormick at 5/5/2004 5:12:26 PM
Hi, I am writing a remote update app, and I'd like to programmatically backup the SQL Server 2000 database before running the SQL files over it. Can anyone tell me a command that does a hot backup of the DB and puts it somewhere, which I would shell exec from my program. eg ShellExec("hotbac...more >>

problema con la funzione except
Posted by alidicera at 5/5/2004 12:40:07 PM
qualcuno sa dirmi cosa c'è di sbagliata in questa query: EXCEPT ({ SELECT idAttach FROM tbAttachs }, { SELECT idAttach FROM tbAttachsForPages WHERE (idPage = 2) }) gr...more >>

Data/Transaction log files for two databases have same file name
Posted by kattukuyil NO[at]SPAM hotmail.com at 5/5/2004 11:42:18 AM
We have two db's. One live and one test. When I right click on the live one in SQL Enterprise Manager and select properties -> Data Files -> File Name is LIVE.MDF Location is F:\Data\LIVE.MDF When I right click on the test one in SQL Enterprise Manager and select properties -> Data Files ...more >>

Cannot set job alerts on Notifications tab if a non-sysadmin user
Posted by dipak99 NO[at]SPAM hotmail.com at 5/5/2004 9:47:46 AM
Platform: Win2000 SP3, SQL 7.00 - 7.00.1063 I have a SQL-authenticated user with the following permissions: "Process Administrators" server role "db_owner" and "TargetServersRole" for msdb database "db_owner" for master database. The problem is that when this user opens up any job (i.e. own...more >>

Restore puts copy of user tables in master
Posted by dishonty NO[at]SPAM seidata.com at 5/5/2004 7:50:28 AM
Environment is SQL Server 2000 64 bit. I restore from a script 'my' database, this works fine. However, all the tables are also found in master, no data though. Anyone experienced this?...more >>

Quale tipo di indice sulla tabella? Wich kind of index on table..??
Posted by s.borgia NO[at]SPAM tin.it at 5/5/2004 3:41:28 AM
ciao a tutti... ci risono... devo migliorare delle performance di accesso ad una tabella... la tabella non ha indice primario, ne altri indici... sulla tabella ci accedo con select di questo tipo.. select @ExistInOAG = count(*) FROM caprs05dev.dbo.OAG WHERE Air_Ca...more >>

Round funtion on entire columns in MSSQL?
Posted by stefan.van.den.steen NO[at]SPAM exact.be at 5/5/2004 2:40:15 AM
Hi, I'd like to round all amounts in a certain column to 2 decimals. I tried the following query, but eventhough the syntax is correct, it doesn't give any result: update gbkmut set bdr_hfl = round(bdr_hfl,2) can anyone help me? cheers, steve...more >>

Cant create database with > 4 GB log
Posted by pongthai NO[at]SPAM msn.com at 5/4/2004 9:08:00 PM
Hi, I got a backup file from my friend which needs 11 GB to hold the transaction log. I tried to restore this database but an error message: "MODIFY FILE encountered operating system error 112(error not found) while attempting to expand the physical file." appeared. The free space is mo...more >>

Equivalent of "Startswith", "Endswith", "Contains" string comparisons in t-sql?
Posted by Robin Tucker at 5/4/2004 4:55:33 PM
Hi, I would like to select records from a table where the following criteria hold: SELECT * from Mytable where field x "contains" string @X or field x "starts with" string @X or field x "ends with" string @X What would the syntax for the "LIKE" predicate be in each of these ...more >>

Export & import DTS Packages
Posted by Hans de Korte at 5/4/2004 3:06:55 PM
Hello, I have a problem with exporting and importing a DTS package from one server to an other. Saving a package like a VB-file is an option I have seen, but how can I import a VB-file on the new server. Do I need a separate program? Is there a possibility like exporting and importing a Job (...more >>

What so special about PostgreSQL and other RDBMS?
Posted by Sarah Tanembaum at 5/4/2004 1:21:51 PM
Beside its an opensource and supported by community, what's the fundamental differences between PostgreSQL and those high-price commercial database (and some are bloated such as Oracle) from software giant such as Microsoft SQL Server, Oracle, and Sybase? Is PostgreSQL reliable enough to be us...more >>

Update multiple records
Posted by smarkestate NO[at]SPAM yahoo.com at 5/4/2004 1:18:14 PM
Hi, I have a weird UPDATE sequence I want to perform. The customer does not want to use INSERT and DELETE. My issue is that there are multiple Mat_Class, but I do not wish to hard code each one individually. Originally I was thinking of using a select statement and creating a loop to sub in e...more >>

Extended SP Questions
Posted by sandell NO[at]SPAM pacbell.net at 5/4/2004 12:52:32 PM
I would like to know if I can determine the calling user from within an extended stored procedure. I assume it's accessible in the SRV_PROC structure somewhere. Also, does anyone know of a comprehensive list of what is included in the SRV_PROC structure? This is for SQL Server 2000. Tha...more >>

xp_Sendmail does everything but actually sending the message
Posted by jjmilano NO[at]SPAM comcast.net at 5/4/2004 12:30:24 PM
I have everything set up with SQL Server 2000 and Outlook 2000 and the procedure works fine but the message sits in my inbox. When it open the e-mail it says this message has not been sent. I just click send and the e-mail sends. Is there any reason I have to manually sent the e-mail after th...more >>

ODBC Connect from MS Access to SQL Server 2000-Viable?
Posted by Paul Stanial at 5/4/2004 10:41:17 AM
How viable is it to use MS Access as a front end (via ODBC) to a SQL Server 2000 database? The users would access via the internet using a netgear vpn setup. Thanks, Paul S ...more >>

third party sql tool
Posted by Mtcc at 5/4/2004 10:09:04 AM
I prefer to write SQL code, without graphical tools. Have third party Query Analyzer that has filter and sort abilities? Also I looking for SQL editor with Completion ability (like we know for programming lang), for assist me write more quickly. ...more >>

Non trovo il link
Posted by d NO[at]SPAM h.t at 5/4/2004 9:17:05 AM
Scusatemi , avrei bisogno di lavorare su SQL SERVER 2000 Analysis Services potreste indicarmi un link per il download della Demo o Trial che sia. Purtroppo ho cercato, ma visto che sono qui a chidere aiuto il risutato della mia ricerca penso sia ovvio, :P Analysis Services è integrato in Sql Se...more >>

Importare dati con bcp in sql server 2000
Posted by s.borgia NO[at]SPAM tin.it at 5/4/2004 12:48:30 AM
Salve Ragazzi!!! ho un problema che non riesco a risolvere e spero di riuscirci con il vostro aiuto... dunque.. ho un file csv tipo questo Date,Aircarrier,CallSign,ComFltNbr,AcReg,AIPTDep,AIPTDst,STD,STA,AOBT,ATA,CancellationDate 01/2004,AZ,,0735,IDATD ,SKG,MXP,01/01/04 04:20,01/01/04 06:45,...more >>

Torn page error
Posted by thakwani NO[at]SPAM rediffmail.com at 5/3/2004 10:29:26 PM
I am getting the following error message while attaching my DB in SQL Server 2000. "Error 823:I/O error ( torn page) detected during read at offset 0x000000000026000 in file 'C:\TestFile.MDF.' I basically, detach the DB from my server and copy that MDF and LDF to another server. Then I F...more >>

Add Keywords to Query Analyzer's Syntax
Posted by Bryan Bullard at 5/3/2004 9:13:03 PM
Does anyone know of a way to add *key words* to Query Analyzer's syntax highlighting feature? I would think that there would be a text/xml file that could be modified. This certainly can't be hard coded. Thanks, Bryan ...more >>

Dirty Read ?
Posted by rsmeiner NO[at]SPAM aol.comcrap at 5/3/2004 7:46:29 PM
I'm having a little problem with using Select Not Exists between 2 tables. I get the infamous Primary key "Cannot insert duplicate key" error. This is on MS Sql 2000. I'm trying to create a temp table with distinct values from another table. Heres a small snippet of the code. Create table...more >>

Can not install Reporting Services, Help!
Posted by SD at 5/3/2004 7:01:23 PM
Hi, I'm running Windows XP and SQL Server Developer Edition (sp3) and I'm trying to install the MS SQL Server Reporting Services that is in the MSDN of April 2004. I also have Visual studio.net installed. So when I run the CD all goes well until you specify the database for the reporting se...more >>

Compressed Drive Support in Yukon (SQL2005)?
Posted by Jack Victor at 5/3/2004 2:12:05 PM
Hi, Can anyone please tell me if there will be support in SQL2005 - Yukon for datafiles to be placed on Compressed volumes or if there will be compression of the data that is transparent to the user. Thanks! <Keeps fingers crossed> Jack...more >>

Merge Replication + Structure Changes
Posted by mcnally_martin NO[at]SPAM hotmail.com at 5/3/2004 11:52:21 AM
My company maintains 40 replicated Sybase databases using a merge replication approach. It's difficult to update all 40 databases when a structure change occurs. Structure changes are minor, usually adding fields. We are considering moving to SQL Server 2000 in the hope that these updates wil...more >>

Retrieve a list of db roles from within T-SQL????
Posted by chris.grabowy NO[at]SPAM lmco.com at 5/3/2004 9:26:42 AM
How do you retrieve a list of db roles from within T-SQL??? I can't find a sys table that returns a list of roles. sysobjects does not list roles as a object type. I found sp_helprole, but I can't get the sp to return it's output into a cursor or variable. Help?? Regards, CxG...more >>

Compare 2 DateValues -> maxvalue in transact sql
Posted by lvpaul NO[at]SPAM gmx.net at 5/3/2004 8:36:18 AM
I need the maxvalue of 2 colums for each row Select date1, date2, maximum(date1,dat2) as datemax. Is this simple to realize ? date1 and date2 can be NULL. something like this: select date1,date2, maxdate = CASE when date1 is null then date2 when date2 is null then date1 else...more >>

Data Structure -- It's been a while
Posted by Jake Jessup at 5/3/2004 3:56:19 AM
Ok, I haven't been doing too much database work lately and my brain has gone soft. I need some help with proper structure. My database is being used to track television shows. Any given show will be associated with at least one production company (call it ProdCo) but possibly up to 3 prod...more >>

Using results of query in a query
Posted by stanwalters NO[at]SPAM hotmail.com at 5/2/2004 9:57:20 PM
Hello all, I'm looking for some hints as to how to use the results of a query in another query. I assume I'm 'thinking' wrong in how to solve this, so I'm hoping someone can clobber me and send me in the right direction. My question is best illustrated by simplified example. I have one tabl...more >>

storage snapshot
Posted by bernhard.krautschneider NO[at]SPAM acp.at at 5/2/2004 12:35:09 PM
hello group, is it possible to do a storage snapshot of a running ms-sql database without losing transactions? What tasks must be done before such a snapshot. thanks in advance, Bernhard...more >>

alter identity property of a column to NOT FOR REPLICATION
Posted by reedmb89 NO[at]SPAM yahoo.com at 5/2/2004 7:34:17 AM
i need to alter all foreign keys in my database and uncheck the "Enforce relationship for replication" check box. Using the EM, I extracted the code snippet below. unfortunately, when i run this test from query analyzer, then go back into the EM, the box is still checked. can anyone tell me...more >>

problem passing UDF scalar result to UDF table function
Posted by rogerr NO[at]SPAM softix.com at 5/1/2004 11:57:19 PM
I'm having difficulties invoking a user defined table function, when passing to it a parameter that is the result of another user defined function. My functions are defined like so: drop function dbo.scalar_func go create function dbo.scalar_func() returns int begin return 1...more >>


DevelopmentNow Blog