Archived Months
January 2003
March 2003
April 2003
May 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
November 2007
April 2008


all groups > sql server programming > july 2007 > threads for thursday july 5

Filter by Day: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31

How to duplicate record fast?
Posted by Bpk. Adi Wira Kusuma at 7/5/2007 11:14:45 PM
i've structure of table like it CREATE TABLE [dbo].[TDAV] ( [THN] [smallint] NOT NULL , [NOID] [varchar] (6) COLLATE Latin1_General_CI_AS NOT NULL , [KODECV] [char] (1) COLLATE Latin1_General_CI_AS NULL , [NAMA] [varchar] (25) COLLATE Latin1_General_CI_AS NOT NULL , [BAGIAN] [varchar] (...more >>

Index
Posted by Bpk. Adi Wira Kusuma at 7/5/2007 10:50:18 PM
If i make a table which field A, B is indexed primary key. So to make best performance,when I execute SELECT * from TB1 Where A=.... do i need to make index again for field 'A'? and when I execute SELECT * from TB1 Where B=.... do i need to make index again for field 'B'? ...more >>

Ask
Posted by Bpk. Adi Wira Kusuma at 7/5/2007 10:40:02 PM
If i make a view/function (the name is V1) which the result is SELECT * FROM TB1 Now, I try to compare 2 statements 1) SELECT NME FROM V1 2) SELECT NME FROM TB1 Do the both statemnts have same best performance? Or Statement 2 has best performance than Statement 1? ...more >>

make function as table
Posted by Bpk. Adi Wira Kusuma at 7/5/2007 10:27:02 PM
I wanna make a function as table. But become the problem is If i give parameter (@THN) with value =0 so will do sql: SELECT * FROM TB1 where THN in (SELECT THN FROM TB2) But If i give parameter (@THN) with value >0 so will do sql: SELECT * FROM TB1 where THN = @THN how make a function l...more >>

SSMS - getting timeout terminated even with Execution time-out of 0?
Posted by M Bourgon at 7/5/2007 7:54:27 PM
On SSMS 9.00.3042.00, any query that runs longer than 10 minutes gets the following error message: The statement has been terminated. Msg -2, Level 11, State 0, Line 0 Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding. I hav...more >>

Need a query...
Posted by GB at 7/5/2007 5:43:15 PM
Hello, I have the following 3 tables: 1. SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO CREATE TABLE [dbo].[tblT1]( [ID] [int] NULL, [AD] [datetime] NULL, [RD] [datetime] NULL, [MYVALUE] [int] NULL ) ON [PRIMARY] INSERT INTO tblT1 VALUES ( 1,'2000-01-08','2000-01-11', 3) INSERT...more >>

createting one recordset with many select statements
Posted by .nLL at 7/5/2007 4:48:05 PM
i am not sure if i can be clear enough buthere it is. i have a stored procedure does some stat counts with 7 selects, normaly that outputs 7 recordsets and i get them with .nextrecordset my question is can i output only one recordset with all those outputs in it? here is my sp create PRO...more >>

Relations across databases
Posted by Ahmed Mostafa at 7/5/2007 4:08:00 PM
Is it possible to make relations across SQL Server 2005 databases? i.e. between tables of different databases? If yes, how? and if possible from the database diagram how too? Thanks -- Ahmed Mostafa...more >>



Looking for example of queries combining Group by and left outer join
Posted by bbcrock NO[at]SPAM gmail.com at 7/5/2007 3:38:01 PM
I have a complicated query involving three left outer joins on a variety of tables. The query consists of SQL Server meta data such as tables, columns, etc. I need to only display the table name once and then leave that column blank in all following columns until the next table comes up in the...more >>

sql server performance problem
Posted by Michael Reyes at 7/5/2007 2:08:03 PM
Hello, I'm having a problem with my network, i'm running a domain based network with one domain controller and a database server running windows server 2003 standard edition, the database server has sql server 2005 standard, the problem that i have is that the performance in the serve...more >>

Can't figure this out.....
Posted by SQLdba at 7/5/2007 12:20:01 PM
Trying to figure out why this isn't working with the following error message: Server: Msg 457, Level 16, State 1, Line 1 Implicit conversion of varchar value to varchar cannot be performed because the collation of the value is unresolved due to a collation conflict. select * from ...more >>

Convert 4 INTs to NUMERIC or UNIQUEIDENTIFIER
Posted by JonOfAllTrades at 7/5/2007 11:44:00 AM
Good afternoon, all. I am currently joining two tables on up to four 32-bit integer keys, and I'm considering creating a new column that concatenates these into a single 128-bit integer to simplify the join. It seems that a UNIQUEIDENTIFIER would be the simplest choice, but maybe NUMERIC or ...more >>

Excel Column
Posted by nkg at 7/5/2007 11:18:18 AM
I have sql2005. I have a linked excel server with a column value as 1/1/2001 when i retrieve the value i get as Jan 1 2001 12:00AM, this breaks up my validation logic for date. I tried to change the column to type general,text but still had the same issue. How can i retrieve value as 1/1/200...more >>

Get Identity field value returned upon INSERT statement
Posted by Hidarisei at 7/5/2007 11:08:03 AM
Hi all, I have a table as follows: if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[Products]') and OBJECTPROPERTY(id, N'IsUserTable') = 1) drop table [dbo].[Products] GO CREATE TABLE [dbo].[Products] ( [ID] [bigint] IDENTITY (1, 1) NOT NULL , [Name] [varchar] (...more >>

Hyperthreading
Posted by CLM at 7/5/2007 11:02:05 AM
I've got a 8 or 16 cpu box with Sql Server 2000 on it. Someone responded to another post I had and said, "Also, are those 16 processors all physical CPU cores? If there is hyperthreading involved, stick with 8 for MAXDOP, turn off HT altogether." Why would you turn off hyperthreading? I'v...more >>

Newbie here, how to retrieve image fields from SQL Server 2005
Posted by maespe63 NO[at]SPAM msn.com at 7/5/2007 10:02:18 AM
Please, I need help on this one, Looks like it's something very simple but I got little experience on this and I am paying for it, worked all night and made little advance. I have a sql db that includes a table with a few image fields to save pdf files. I use Access as a front-end and have no pr...more >>

Scheduling the creation of long stored procedures??
Posted by MittyKom at 7/5/2007 8:08:00 AM
I have several long stored procedures that i would like to create every morning on a new database that's gets restored every morning. I have tried to create a job but the stored procedures are too big to fit in in the steps dialogue box. Is there any way i can schedule a job to do this? Thank ...more >>

constraint
Posted by zino at 7/5/2007 8:06:01 AM
Having the following tables in sql 2005: create table tPrimary( key1 varchar(4) NOT NULL, foreignKey1 varchar(10) not null, foreignKey2 varchar(10) not null, foreignKey3 varchar(10) not null constraint PK_ primary key clustered (key1) ) create table tForeign( id varchar(10) primary ...more >>

Making SQL multilingual
Posted by Taras_96 at 7/5/2007 7:41:22 AM
Hi everyone, Currently I have a software product that allows users to build filters through a quite high level interface to search for data. For example, the user can select what fields he wishes to be included in the filter, and conditions on those fields, and the builder will take care of t...more >>

How to start a Job on SQL2000 from a website.
Posted by geir at 7/5/2007 7:08:01 AM
Hi all. All I want to do i one button on a webpage that "fires" a SQL Server Agent job as if I was in rightclicking it an selected "Start now". Any ideas? -- Thanks all Regards Geir...more >>

Syntax error converting from a character string to uniqueidentifier - help needed
Posted by Learner at 7/5/2007 7:05:19 AM
Hello, I have stored proce that used to run pretty well before a week ago ************************************Stored proc*********************************** set ANSI_NULLS ON set QUOTED_IDENTIFIER ON go ALTER PROCEDURE [dbo].[procGetXMLSessionState] @SessionGUID UNIQUEIDENTIFIER ...more >>

Date picker in Reporting Services 2005: DateFormat
Posted by MarkusJNZ NO[at]SPAM gmail.com at 7/5/2007 6:44:02 AM
Hi, we have an installation of MSSQL reporting services where users can select data based on date ranges. Since upgrading to 2005 we now have a nice new Date picker control alongside textareas which accept MSSQL datetime values. This is all very nice but the date picker automatically formats t...more >>

Certification
Posted by Bals at 7/5/2007 6:17:27 AM
Hi , I am into SQL Developing .. I want to know details about the microsoft certification exams in SQL 2005 . . I am Confident in SQL 200 and learning 2005 ... I dont have any certification ... Pls Note : I dont't want to do in SQL administration part or in SQL 2000 Thanks in Advance...more >>

How to filter unwanted events from Profiler Trace (Sql Server 2005)?
Posted by Piotrek at 7/5/2007 6:02:28 AM
Hello. I recorded a Profiler Trace on production machine. Now I would like to filter unwanted events from it. I know that I can do it manually in SQL Profiler, but I would like to do it in some more automatic way. So the scenario would be as follows: 1. I record Trace on production. 2. Tra...more >>

ssis 2005
Posted by farshad at 7/5/2007 5:26:07 AM
Is it possible is SSIS to get the contents of an xml file and pass it on to a stored procedure? Thanks...more >>

Restore Database doesn't work
Posted by andreas.wrzaszczyk NO[at]SPAM tripol.de at 7/5/2007 2:56:18 AM
Hi Group, I'm running a MS SQL Server 2000, SP4, Enterprise Edition, on a MS Server 2003, 4GB Memory, 2x1 TB HDD. Running Backups is no problem, at a very good speed of 80 MB/s. The Problem is to restore a database. When I start a restore procedure of a small db (say pubs) it is working fine...more >>

Checking different inserted table
Posted by Ant at 7/5/2007 2:54:01 AM
Hi, (SQL2000) I want to create a trigger on tbl 1 but need to check the inserted table on tbl2 in order to determine an action to take for the tbl1 trigger. Is this possible? Many thanks in advance for any answers on this Ant ...more >>

Newbie sql question
Posted by fluffskuff NO[at]SPAM yahoo.com at 7/5/2007 2:29:55 AM
Hi folks, If anybody knows how I would write this SQL I would be grateful :) The scenario, table 'Owner_Car' contains the following: Id OwnerId CarId 1 10 12 2 10 18 3 10 17 4 12 12 5 13 15 I would like to know which owners that owns all of the cars in a given list, for exa...more >>

NULLIF
Posted by Hariramsait at 7/5/2007 12:42:01 AM
what is the use of NullIF statement can any one help me?...more >>


DevelopmentNow Blog