Home All Groups Group Topic Archive Search About

SQL Server database programming

microsoft.public.sqlserver.programming
Score Get Windows NT/XP Logon ID in SQL Server
RonL - 8 Apr 2006 10:50 PM - 6 messages
Is there a way to get the Windows NT/XP Logon ID in SQL Server if the user logs on as "sa"? SUSER_SNAME () returns "sa" Thanks Ron ...
Score Where is Bookmark Lookup?!
Leila - 8 Apr 2006 8:44 PM - 3 messages
Hi, In the graphical view of execution plan (in QA), a bookmark lookup was quite easy to find. But in SSMS, it is displayed as a inner join. Although the logic is the same, but in exec plan of complicated queries, it is much ...
Score Inserting Specific Value in Query Result
DK13 - 8 Apr 2006 7:33 PM - 5 messages
I have a table where I need to insert a unique USERID based on the USERNAME.  Seems pretty simple to me, however I am a novice writing SQL statements. My knowledge is very limited, so when responding please do not assume I ...
Score temp table in external stored proc
helmut woess - 8 Apr 2006 5:04 PM - 3 messages
Hi, i want to write an external stored proc which works with data created and stored in a temp table by the calling stored proc. When i use a global temp table (ie ##temp1) then i can use this table in the external stored proc, ...
Score SELECT top 1 for each ID
simon - 8 Apr 2006 3:40 PM - 12 messages
I would like to get only the top 1 row from view for each productID order by date,type,quality for example: productID    quantity            date            quality        type ...
Score How can i update my dataSet to SQL Server Databse in c# ???
< g n d z k d r > - 8 Apr 2006 2:02 PM - 1 message
Hi all, information about database is below database name  BAP table name is KULLANICI table columns are                            ID                // primary index ...
Score Multiple Join Query Problem
Wayne Wengert - 8 Apr 2006 9:45 AM - 4 messages
I am trying to update a field in TblA based on the contents of a field in TblB where 4 conditions match but I can't get it to work. ere is what I tried: Update TblA t Set [Show Name] = ...
Score PATINDEX and CHARINDEX
mukki_neo - 8 Apr 2006 4:48 AM - 5 messages
Hello I have a table in my database , in one field i have data like this (230+365+651+695) varchar(100) I want to use the any SQL function to return the data in form of rows from the above field. ...
Score File size is growing fast
SF - 8 Apr 2006 2:30 AM - 7 messages
Hi, My SQL database is about 90MB and start growing very fast to 1000MB over a week time. I try to shrink from the EM with no success. I notice that only the size of the log file is reduced. Is there a way to do shrink the ...
Score getdate() format problem
Michael - 7 Apr 2006 11:50 PM - 4 messages
Hello, I am just trying to do a simple time stamp. When I do the following SQL command SELECT getdate()  my book and Microsoft say I should get the format like this:     3/22/2002 6:08:08 AM ...
Score Compairing Date Ranges with time
LvBohemian - 7 Apr 2006 10:43 PM - 12 messages
I am considering the following snippet to compare a date range... DECLARE     @CurDate VARCHAR(14) SET @CurDate = SELECT CONVERT(VARCHAR, GETDATE(),112) + CONVERT(VARCHAR,DATEPART(HOUR, GETDATE())) + CONVERT(VARCHAR,DATEPART(MINUTE, GETDATE())) + CONVERT(VARCHAR,DATEPART(SECOND, GETDATE())) ...
Score Query to display a field based on a parameter
KatMagic - 7 Apr 2006 10:29 PM - 2 messages
I have a client table, with 8 fields, all of which contain a phone number. Bad design, I know, but let's not get into that here.  My problem now is that in addition to those fields, we have a "Preferred" field, which simply ...
Score Updating new column with part of another
JR - 7 Apr 2006 10:18 PM - 6 messages
I have a column that for now is text data however are really decimal numeric values.  I want to take everything on the left of the decimal and stick it in a new column, same row, called whole_number and stick ...
Score Max Value in Column Other than Return Value Column
John Walker - 7 Apr 2006 8:46 PM - 5 messages
Hi, This may be a very simple query but I couldn't figure out how to do it.  I have a table with two columns, COL1 and COL2.  I need to write a query that will return the value of COL1 from the row where COL2 has the greatest value. ...
Score Re: Selecting min from duplicate records
mkarnofel - 7 Apr 2006 8:30 PM - 1 message
Thanks...  worked great. -Matt ...
Score User Define Database
Naana via SQLMonster.com - 7 Apr 2006 7:55 PM - 8 messages
Hi All, I need a script that will give table names, number of rows, szie of data and indexes, clustered or non-clustered, and filegroup name. Can any one point me to the right direction. Thanks. ...
Score Re: Is primar key/foreign key evil in SQL Server?
David Portas - 7 Apr 2006 7:51 PM - 3 messages
--CELKO-- wrote: Didn't it take 7.5 million years to arrive at that answer? Pretty good going at consulting rates :-) ...
Score Re: SSIS -- Copy object from SQL 2000 to SQL 2005
MT - 7 Apr 2006 7:36 PM - 2 messages
I need to correct myself...The object created was actually a Transfer SQL Server Objects Task.  Sorry for the mis-communication. ...
Score Insert / Update Statement
Nizham - 7 Apr 2006 7:24 PM - 2 messages
Hi The table have the row as A, 1, 5 B, 10, 13 I need to insert the vales to other table as A, 1 A, 2 A, 3 A, 4 A, 5 B, 10 B, 11 B, 12 B, 13 ...
Score Full Text Setup
Rob T - 7 Apr 2006 7:23 PM - 19 messages
I'm trying to set up Full-text indexing.  I installed the module, the service shows up in control panel\services, but the option in EM is still grayed out.  Any suggestions? FYI:  SQL2000 on XP pro, rebooted machine... ...
Score PLS HELP! Problem with column width
MuZZy - 7 Apr 2006 7:19 PM - 2 messages
Hi, We have a "bad" table in our database - sum of all 30 field widths exceeds 8000 bytes. It still works fine unless all fields are filled completely, and that's what happened to one of our clients. Now he can't ...
Score Archiving data to a seperate database.
MarkieMark - 7 Apr 2006 6:43 PM - 4 messages
Hi all, Would appreciate some thoughts on the best way to do this scenario. This is not a large database in the number of tables, but has about 100,000 new rows per day. Data is inserted only, and no queries / SPs are being run ...
Score use variable in where statement
Helen - 7 Apr 2006 6:38 PM - 6 messages
This piece of code doesn't work. Any idea? declare @id varchar(20) set @id = '(12,13)' select * from appusers where id in @id ...
Score Selecting Fields not to include in SELECT statement
Kevin - 7 Apr 2006 6:25 PM - 4 messages
Hi. Is there a way to select all fields in a table but exclude one or more? For example if I want to get all fields in a table called Names except the BirthDate field a query might be: SELECT FirstName, LastName, Height, Weight, FavoriteColor ...
Score Convert Date to String
Pancho - 7 Apr 2006 6:13 PM - 5 messages
Hello, I have a date field in a table.  I don't need the time part.  I want the result to be in the format YYYYMMDD.  Consulted BOL and it gave me:  SELECT CONVERT (char, fieldname, 8).  Tried that and I get the time hours.  ...
Score Trigger logic question - using If with AND and OR
Rich - 7 Apr 2006 5:30 PM - 7 messages
Hello, I have a trigger - which works if I set the body up as follows: .... If ((select count(*) from inserted) < 2)   Begin     If ((select uniqueSubscrID from inserted) Is Null) Or ((select uniqueSubscrID from inserted) = '')   Begin ...
Score SSIS Required for Programming?
Austin Summers - 7 Apr 2006 5:30 PM - 1 message
Is it required to have Integration Services installed on a target server in order for a .NET application to create and run an SSIS Package on it?  Can a ..NET app run create and run SSIS packages on SQL Server Express? ...
Score appending data to a text column
kw_uh97 - 7 Apr 2006 5:29 PM - 3 messages
Hello everyone, I'm a newbie so have some mercy please. Please feel free to make some best practice suggestions. Here we go, I am importing data into a table within my database. I'll use some DDL for clarity. ...
Score Performance question
Ashhad Syed - 7 Apr 2006 5:29 PM - 8 messages
I have written a stored procedure to obtain businesses in a given zipcode radius(eg: Get all chinese restaurants in 10 miles from 94568 zipcode). All the fields being used in the main stored procedure query are indexed. When I ...
Score How to restore tables dropped from logs in sql server?
Marco Napoli - 7 Apr 2006 5:12 PM - 2 messages
How to restore tables dropped from logs in sql server 2000? ...
Score sp_executesql and datetime
ina - 7 Apr 2006 4:45 PM - 4 messages
Hello all, I have this code and I do not know why I have this error. EXECUTE sp_executesql     N'SELECT * FROM TABLE     WHERE T_ID = @level and timestamp = @timestamp',      N'@timestamp datetime', ...
Score Trigger question
Jchick - 7 Apr 2006 4:32 PM - 2 messages
This outta be an easy one for someone. I have the following code in my trigger. I am trying to connect to a DSN that is pointing to an Access database (.mdb). However, I am not sure how to actually write the ...
Score SQL/CLR books
Craig Berntson - 7 Apr 2006 4:10 PM - 12 messages
I have a new assignment to rewrite some Extended Stored Procedures using ..Net integrated into the CLR. Are there any good books that can help me with CLR integration in SQL Server 2005? ...
Score HELP WITH TRIGGER
APHILLEY@WATSONFURNITURE.COM - 7 Apr 2006 4:09 PM - 3 messages
Hi I am trying to write a trigger that will prevent anyonr from changin a closed customer order.  This is what I have so far.. SET QUOTED_IDENTIFIER ON GO SET ANSI_NULLS ON GO CREATE  TRIGGER can_not_change_a_released_order on CUSTOMER_ORDER for ...
Score Vbscript in a stored procedure
Zrod - 7 Apr 2006 3:50 PM - 4 messages
hi, IS there a way to write vbscript , or call an execultable within a stored procedure? ...
Score SQL eating all memory
Darren Woodbrey - 7 Apr 2006 3:44 PM - 6 messages
I have sql 2000 installed on a Dell Poweredge dual Zeon 3.2 Ghz with 2 GB of RAM.  It has a database that runs an asp website and it also hase a database for our accounting package, Microsoft Great Plains. ...
Score how to back up and restore Integration Services stuff?
=== Steve L === - 7 Apr 2006 3:27 PM - 1 message
in sql2k, all dts packages were kept in msdb and it can be backed up and restored. also, the dts package can be saved as a file, moved and imported to another server. how will that work for ETL stuff created in Integration Services? ...
Score Invalid Column Names?
Darrell - 7 Apr 2006 3:25 PM - 6 messages
Here is my code: DECLARE curCAED1 CURSOR FAST_FORWARD FOR    SELECT * FROM okc_contr_license    WHERE CONTR_TYPE = 'ME'    ORDER BY CONTRACTOR_NUMBER OPEN curCAED1 FETCH NEXT FROM curCAED1 INTO    @pContrType, @pContractorNumber,    @pCityLicType, @pCityLicNumber, @pCityLicRenDate, ...
Score Why am I missing rows in my result set?
arch0041 - 7 Apr 2006 3:22 PM - 8 messages
I have a table with 90,000 rows.  Each row has 2 latitude and 2 longitude values for two different locations (lat1,lat2,lon1,lon2).  I have a calculation that will give me the difference between the two locations.  When ...
Score Unexpected NOT IN results
David D Webb - 7 Apr 2006 2:41 PM - 7 messages
Is there any difference between these 2 statements.  The first one returns no rows, yet the second returns 137 rows.  137 is the correct results.  I must be missing something.  ssn is a varchar in both tables. ...
Score Advanced T-SQL Question: Produce Backup Window Gantt Chart
Kael_Sidhe - 7 Apr 2006 1:51 PM - 7 messages
I'm an Oracle DBA who inherited 100 or so SQL Databases.  I know how I would accomplish this task in Oracle but I have no clue how to do it in T-SQL.  In short, I want to produce a comma delimited gantt type ...
Score [OT] There should be a law...
Mike Labosh - 7 Apr 2006 1:04 PM - 12 messages
....against wives sneaking up behind their husbands asking about coffee in the morning, after the husband had been playing Doom for several hours. If that had been a REAL shotgun, she would have been splattered all over the wall.  I'm going to go change my underwear now. ...
Score how to get back image from table?
supriya - 7 Apr 2006 11:56 AM - 6 messages
Hi all,     i have one image column in my table. i inserted one image in that.when i select that value it is giving hex value.How can i get my image back.   Thnx. ...
Score SQL Performance difference
resist - 7 Apr 2006 11:40 AM - 4 messages
Hi, During som performance optimization I ran into the following strange performance difference. I performed a query basically counting 10 different tings from a set of tables. Thus I had 10 different joins and where clauses giving me 10 different counts. ...
Score Prioritise the execution of a specific Stored Procedure
D Johnson - 7 Apr 2006 11:32 AM - 10 messages
Hi I wondered if SQL Server 2005 would allow some sort of option to be set that would allow a specific Stored Procedure to receive a higher execution priority. Thanks in advance. David ...
Score Stored Procedure Name
S Chapman - 7 Apr 2006 11:21 AM - 4 messages
Is there any performance overhead if a stored procedure name starts with 'sp_'? I have heard that if the name starts with 'sp_', Sql Server checks for the SP first in the master database. Is this correct? Thanks ...
Score XLS from DTS
Enric - 7 Apr 2006 11:03 AM - 1 message
Dear all, We have dts which take .XLS data and then load them into sql tables.We facing up problems such as "Microsoft Jet can't open the file, it is opened by another user or process". We'd like to redefine this behaviour in order to be able to execute these ...
Score Registering by massive way sql servers
Enric - 7 Apr 2006 11:02 AM - 4 messages
hi everyone, Imagine you have 20 workstations and for each of them you've got to register by MMC around 30 sql servers. It's stupid to imagine do a registered one by one if you know that all of them have the same password and overall, you have ...
Score sql gathering data from Internet?
Enric - 7 Apr 2006 10:22 AM - 4 messages
Dear all, I am just struggling myself and pulling out my hair trying to think how to obtain online data from a site and load them into Sql Server. I've thought to use a DTS, which at a specific hour might open a URL and ...
Score ROLLUP and summarazing values
simonZ - 7 Apr 2006 9:48 AM - 3 messages
I have query: SELECT column4,column5,sum(column1)as sum1,sum(column2) as sum2,sum(column3) as sum3, result=case when sum(column1)<(sum(column2)+sum(column3)) then 0 else sum(column1)-sum(column2)-sum(column3) end FROM testTable GROUP BY column4,column5 WITH ROLLUP HAVING column4 is not ...
Score assign a table to a path and filename?
Markus Zingg - 7 Apr 2006 9:42 AM - 16 messages
Hi group I'm a newbee, so please bear with me if this is a stupid question. I would like to have a one to one relationship on the server with regard to tables created in a database and the file(s) the data ist ...
Score What are new featuture of vs 2005
rakesh - 7 Apr 2006 9:02 AM - 3 messages
I want to know about the new feature in c# , .net and Sql 2005 as compare to previous version. Like difference between SQL Server 2000 and 2005. ...
Score Storing text files in a column
Gabriel Lacatus - 7 Apr 2006 8:56 AM - 4 messages
Hello, I'm trying to store an HTML page inside a table column (for debugging purposes). I tried the varchar type but 8000 chars are way to few for this. Then I turned to the text datatype and I learnt that while in a stored procedure ...
Score xp_sendmail error
Sevugan - 7 Apr 2006 6:51 AM - 6 messages
Hi, I am getting an error - 'Could not resolve recipient' while using xp_sendmail stored procedure. What is the reason for this. How can I resolve this. ...
Score database diagrams in SQL 2000 + VS.NET 2005
Graham Charles - 7 Apr 2006 6:42 AM - 3 messages
I've recently upgraded to VS.NET 2005 (still using SQL Server 2000), and I'm no longer able to edit database diagrams from with VS.NET as I could with VS.NET 2003. Am I missing a setting somewhere, or is this no ...
Score BOL BCP example
GH - 7 Apr 2006 5:54 AM - 5 messages
When I run the following BOL example: bcp AdventureWorks.Sales.Currency out Currency.dat -T -c I get the following error message:    Msg 102, Level 15, State 1, Line 2    Incorrect syntax near '.'. I have tried multiple variations ... still get the same error ... ...
Score query?
js - 7 Apr 2006 4:17 AM - 3 messages
Hi, i have several Paragraphs in one table, how to do this: Can I regroup Paragraphs base on a  number? For example, I have 3 Paragraphs: 1. Test1 2. Test2 3. Test3 if I pass 2,  will regroup as: ...
Score query timeout expired
Tlink - 7 Apr 2006 2:30 AM - 11 messages
I am performing a update to 2m+ records, when it reaches 200 records it times out ? rsobj = db.execute("select * from Somefile where t2 is null;") do while     db.commantimeout = 0     ******** newexp & newfactor are calculated ***** ...
Score CREATE ASSEMBLY failed because it could not open the physical file
AJang - 7 Apr 2006 1:58 AM - 11 messages
Scenario: Server: windows server 2003 with sqlexpress installed,named serverA. Client: windows xp, named clientB problem:Want to create assembly from a assembly dll file located in client machine. I use statement Create assembly foo from '<PATHFILE>' to create assembly in database. ...
Score Graphics
Ravi Persaud - 7 Apr 2006 1:35 AM - 3 messages
I have created a table (SQL Server 2005) with 2 columns. One is a reference (int) number and the other (image) for storing images. I will display the graphics in a DetailsView on an asp.net web page, created with Visual Studio ...
Score System catalog - defaults
lh - 7 Apr 2006 1:25 AM - 3 messages
How can I check for the default value of a column? I can get to sysobjects where type='D' but I want to find what the value of the default is. TIA - LH ...
Score nested queries
Fairy239 - 7 Apr 2006 1:12 AM - 4 messages
i got a question of how to use a result you achieve from a query in table form and use the result to find other stuff form the other tables for example SELECT Omim_No FROM av WHERE Description LIKE '%LIVER%' ...
Score View to show lowest value only
Mike - 6 Apr 2006 10:45 PM - 4 messages
I have a table that contains product prices. The problem is that sometimes it will have two prices for the same product. For example: Part    Price 1        10 2        25 ...
Score sequential file and Parent ID's
Jim - 6 Apr 2006 9:35 PM - 3 messages
I have a sequential file that has header records and below it its detail records. When I hit a new header know I know that that row-1 is the details for the previous header (FYI: Header ID is ALWAYS unique) ...
Score Help with a SQL Join statement
James Juno - 6 Apr 2006 9:34 PM - 7 messages
I have a question with a join.  As a new developer, I see that there may be issues with the join in the query.  Can someone please tell me what you think?  Thank you. SELECT DISTINCT CaseNo, Amount, DTaxID, DZip, DLastName, ...
Score Stored Procedure call using MSSQL::DBLIB
newbie24 - 6 Apr 2006 9:06 PM - 2 messages
I'm trying to call a stored procedure from a perl script using the MSSQL::DBLIB module.  My stored procedure requires three parameters (date, id #, current timestamp).  Can anybody help me with the syntax for this?  I would consider using a different module, but I am trying ...
Score Network I/O error in SQL 2000 with SP4 ?
DGreg - 6 Apr 2006 8:25 PM - 2 messages
Can anyone explain this NETWORK I/O error I received using SP4, SQL 2K. "spid85 Process ID 90 killed by hostname tester, host process ID 23328" ...
Score can't seem to get my GROUP BY ordering right
Kevin Blount - 6 Apr 2006 7:49 PM - 9 messages
I have the following query, which works, but the ordering isn't quite right, can anyone help? SELECT   to_char(date_created,'DD-MON-YYYY') as date_joined,   COUNT(user_id) AS user_count FROM   project_users GROUP BY   to_char(date_created,'DD-MON-YYYY') ...
Score What is the build number of SQL Server 2005 Express
austinajit@gmail.com - 6 Apr 2006 7:24 PM - 4 messages
Hi, Can anyone tell me the (build) version number of SQL Server 2005 Express? Thanks, Austin. ...
Score selecting records based on details in related tables
KBuser - 6 Apr 2006 6:45 PM - 3 messages
The important schema: TBL: ISSUE PK:  IssueID One to many relation to: TBL: PAGE PK:  PageID FK:  IssueID One to many relation to the table with values I'm checking: TBL: PAGEDETAILS PK:  PageDetailsID FK:  PageID ...
Score Performance of EM
Leila - 6 Apr 2006 5:38 PM - 10 messages
Hi, I have no large database on my notebook. The only databases that I use for my tests are Northwind and Pubs. Each time I install Windows and SQL Server, I notice that EM considerably becomes slow after 1 or 2 months. This is what ...
Score Smart, multiple rows based query
Oscar - 6 Apr 2006 5:28 PM - 5 messages
I want to find a sql query for the following case : ID    ID_client    ID_prodnr    1    2                6 ...
Score What T-SQL statement am I looking for?
mahalie - 6 Apr 2006 5:27 PM - 4 messages
Hi, Just hoping for a hint here...I've got a query that returns names and project roles, like this: MarkW    Project Designer MarkW    Project Manager MarkW    Project Architect MarkW    Architect ...
Score Check Constraint
Steve Zimmelman - 6 Apr 2006 5:15 PM - 13 messages
I'm having a little trouble enforcing a unique record rule.  The problem is a DateTime field is used in the unique value, but I only need to the DatePart (not the time), otherwise I would use a standard unique constraint. ...
Score Convert Char data type to number
Chris - 6 Apr 2006 4:27 PM - 5 messages
I need to covert Char data type to number I am running a query and I am getting the following error can some one help with this ERROR Server: Msg 409, Level 16, State 2, Line 1 The sum or average aggregate operation cannot take a char data type as an ...
Score Passing multiple record sets from one procedure to another
sdwebguy - 6 Apr 2006 4:07 PM - 9 messages
I am not having any luck getting this to work. I am using SQL 2000/2005 (we have both at the moment). I am writing a stored procedure with the intent of creating a temp table and inserting records into it. This procedure gets its records ...
Score Calling External Program from SQL Server 2000
Greg Busby - 6 Apr 2006 4:04 PM - 2 messages
I want to create a file folder on a server when a new record is Inserted into a SQL Server 2000 table.  I was thinking that I would create a simple windows console application in C# to handle the folder creation.  I want to ...
Score How to do ...?
Bpk. Adi Wira Kusuma - 6 Apr 2006 4:00 PM - 2 messages
When I install SQL Server 2000, I wanna make a server have "Latin1_General_CI_AS" Collation.What Must I set on Collation setting? If I install in Win2000 server and when on Collation setting, I choose option "SQL Collations...", and select "Dictionary order, ...
Score Event Notification question
Codesmith - 6 Apr 2006 3:56 PM - 5 messages
I am working on a c# app that utilizes Event Notification. So far I have been able to get it to work with pretty simplistic SQL statements but I have run into a problem. The query that I need the application to use relies on a view as part of an ...
Score More on querying remote server
Ian Boyd - 6 Apr 2006 3:55 PM - 33 messages
i'll just keep posting the problems, as my own archive. SELECT TransactionNumber FROM servertest.CMSArchiveTraining.dbo.Transactions_90 WHERE transactionGUID = '4956E240-8B6E-437E-B9B0-5E83FC25E3F0' Issues the remote query: SOURCE:(servertest), QUERY:(     SELECT Tbl1001."TransactionGUID"         Col1003,Tbl1001."TransactionNumber" Col1004 ...
Score help with case
Giscar Paiva - 6 Apr 2006 3:41 PM - 6 messages
Good afternoon... I look for a forum which one I can as for queries. If this isn't the one, sorry. Please say me where I can find it. My problem: I have a table where ParentID is foreign key to ID in the same table. ...
Score 3 months after the layoff...
Mike Labosh - 6 Apr 2006 2:48 PM - 11 messages
I spent 2 years of my life working on a successful migration from Access 97 to SQL Server 2000. Redesign of the schemas.  Redesign & rewrites of all their applications, from VBA to .NET.  All successful and ontime. ...
Score "Colescing" values in a field?
Arthur Dent - 6 Apr 2006 2:42 PM - 8 messages
Hello all, i am wondering if i can do the following with simple TSQL statements without needing to resort to using cursors.... i am having a hard time trying to think of a way, but TSQL isnt my 'native' sql programming ...
Score Distributed transaction
checcouno - 6 Apr 2006 2:01 PM - 1 message
Could be a user's permission problem? And how i should configure the DTC service and MSSQLSERVER service? What kinf of users these services sholud use to run? My configuration: My local pc with WINXP SP2 (firewall disabled) and SQL Server 2005 with ...
Score many small queries vs one large query
Allan Ebdrup - 6 Apr 2006 1:06 PM - 29 messages
I just had a discussion with my boss, we are running a query that fetches about 5000 objects from the database using MSSQL and DotNet 2.0. My boss thinks that the recommendation of keeping the connections open for as short a time as possible means that one shoule open a connection, fetch ...
Score Plz help me! I want to use SQL Server2000 DTS Import/Export Wizard functionality from C# application
Adnan - 6 Apr 2006 12:55 PM - 11 messages
hello actually i have to import a text file into SQLServer2000 database table. i can do it from Enterprise manager of SQLServer2000 using DTS Import/Export Wizard. But i want to use SQL Server's DTS Import/Export Wizard's functionality thorugh C# application without using DTS wizard ...
Score @@ROWCOUNT
McHenry - 6 Apr 2006 12:05 PM - 3 messages
How can I return the number of rows returned by a select statement such as the following one that returns zero in @Qty ? Alter Procedure GetMonitors ( @Qty INT OUTPUT ) As SELECT a.Suburb, a.State FROM ( SELECT Suburb, State FROM Monitors ...
Score exporting data excel
Pedro - 6 Apr 2006 12:01 PM - 2 messages
Hi, I have a problem concerning to exporting data to an excel sheet. I use 2 stored procedures (spStockReport1, spStockReport2): one to pasta date to sheet 1, and other to paste dat to sheet 2. The problem is that the first sp gets the result with no problem but ...
Score Table/Querry
Chris - 6 Apr 2006 11:57 AM - 2 messages
I have created a querry and would like the result of this querry be stored in a table -- Can someone tell me how I can accomplish this task Here is the querry SELECT   dbo.Copy_AFS.[CORP-NUM],     dbo.Copy_AFS.[GL-ACCT-NUM-II-PRIN], ...
Score Partition switching
vsr - 6 Apr 2006 11:52 AM - 3 messages
Hello, I've encountered with a problem trying to switch the unpartitioned table to the partition of partitioned table. Here is an example. Let's create partition function and partition scheme in some database: CREATE PARTITION FUNCTION [pf1](int) AS RANGE LEFT ...
Score business process logic in stored procedures
Will - 6 Apr 2006 11:52 AM - 2 messages
Hi All, I've always tried to think of and use sql as being a tool to quickly retrieve / update relevant data, and let other parts of a system handle the decisions as to what needs to be done to the data. However I keep ...
Score Any help would be welcomed!!
Enric - 6 Apr 2006 11:05 AM - 4 messages
I'm using DMO library. I'm struggling and pulling out my hair trying to find the f*ck.. property for the Recovery Model (simple, full, Server.Databases.Item1..... Does anyone here have ...
Score Regarding filegroups
Enric - 6 Apr 2006 10:45 AM - 6 messages
Dear all, I was just wondering myself how could I do for to obtain to which filegroup belong a specific table. Imagine that you have primary, primary_history, secondary_history, index_history, bla,bla Any idea or though would be very appreciated. ...
Score Default Values for a Column
CJM - 6 Apr 2006 10:21 AM - 14 messages
I have table where I want one column (EquivNo) to default to the primary key column (PartID) when the row is inserted. This value may be updated later, but at the point where the row is created, I want the values to be the same. ...
Score Problem saving text to DB
Griff - 6 Apr 2006 10:07 AM - 4 messages
Hi I have a table that has a field of type TEXT [text, length=16, allow nulls] I have a stored procedure that receives a parameter of type text and simply inserts this data [insert myTable (myField) value (myTextData)] Now the whole thing works fine, except when the data (which happens to be ...
Score select specific child tables based on parent record
Robert Bravery - 6 Apr 2006 10:00 AM - 2 messages
HI all, I have a claim table in or database. I have seperated uncommon data from the claims table into different class tables. So all data that pertains to motor only type claims are removed into a motor table, like vehicle driver make model etc. Same with other claim classes ...
Score No Rows returned in Enterprise Manager
web.reports - 6 Apr 2006 9:59 AM - 2 messages
Hi All, The following query returns one row when run in Query Analyzer: DECLARE @IntCnt AS integer SET              @IntCnt = 0                           SELECT     @IntCnt = @IntCnt + COUNT(DISTINCT ...
Score Export Stored procedure to Access Error
vsiat - 6 Apr 2006 9:20 AM - 3 messages
When trying to export the output of a stored procedure to an Access database, I get the error    "Syntax Error in field definition" at the first step of the process (output table creation) The procedure runs fine in QA, and has the following general structure: ...
Score How to see is other process running?
Nikola Milic - 6 Apr 2006 9:07 AM - 1 message
Hi, I don't want to start a job, if Internet Exporer is running on SQL server. Is there easy way to see from T-SQL if other process running? I use SS2000, SP4, Win 2000 Advance, SP4. Thanks in advance ...
Next »