all groups > sql server (alternate) > august 2003 > threads for august 15 - 21, 2003
Filter by week: 1 2 3 4 5
Creating a heirarchical output from SQL statement
Posted by Richard Rice at 8/21/2003 2:52:41 PM
This may be a basic question, but defining anything other than a cursor
is preffered.
I have, as an example, 2 tables. One with customer data (addresses,
phones, etc), the other is a listing of all 50 states (a cross reference
for short state alias to long state name, i.e. FL - Florida, etc...... more >>
Announce: Tips & Tricks book
Posted by Rob Verschoor at 8/21/2003 1:42:26 PM
I recently published a Tips & Tricks book aimed at Sybase ASE (see
www.sypron.nl/ttr). Although I originally didn't intend to cover
MS-SQL, I have received feedback from readers who found it highly
useful for MS SQL as well (see one of the comments at
www.sypron.nl/ttr).
Due to their common her... more >>
Using an Identity Field as Primary Key
Posted by amcniw NO[at]SPAM yahoo.com at 8/21/2003 12:16:34 PM
I want to use the Identity field (increment 1,1) as a primary key and
have a unique constraint on my other field which is of type char.
I am worried that related data in other tables may lose referntial
integrity if records in the ID table get messed up and need to be
re-entered.
Can you please... more >>
AIX Server Client Software
Posted by malfonso at 8/21/2003 11:43:26 AM
I will be deploying a Java application on AIX server. Is there a SQL
Server Client Software that I need to install on the AIX server to
enable the communication between the AIX box and SQL Server?
--
Posted via http://dbforums.com... more >>
Change SQL Server registration?
Posted by gala NO[at]SPAM sonic.net at 8/21/2003 11:43:07 AM
I am trying to set up my machine for replication and have recieved the
following message
"SQL Server replication does not support nicknames, such as "." or
"(local)" as server names.
Delete the SQL Server registration for this server and register it
using the actual server name"
Well, I ... more >>
Looking for db replication tool
Posted by bob NO[at]SPAM frieden.org at 8/21/2003 11:25:33 AM
I'd like to use log shipping to provide warm backup to some production
MSFT SQL 2000 servers. I know that I can write something to ship logs
but I'm looking for a complete solution that would take a while to
write. Prefer not to upgrade to SQL enterprise (too costly). Is
there a tool that pro... more >>
Problem with uploading data SQL
Posted by Robert K at 8/21/2003 8:59:50 AM
Hello,
I have problem:
My *.txt file is like it:
"
12345612345678123
abcdefabcdefghabc
" etc.
i want upload data into table (for example TEST) i want to sql read this
file and automatically upload to table.(as job for example)
but i have 3 columns and i dont know how to separate this... more >>
Timeout issue when connection to SQL Server in Wireless environment
Posted by ddnrg NO[at]SPAM hotmail.com at 8/21/2003 7:19:27 AM
I am having problems with long timeouts when connecting to
or executing commands in SQL Server 2000 SP3. I am
writing an application that will be used on laptops within
an environment that is wireless. The application is
written in VB.NET using the SQL Server managed provider.
I have se... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
Web based reporting - suggestions needed
Posted by ryanofford NO[at]SPAM hotmail.com at 8/21/2003 5:26:34 AM
I want to create a web browser based MIS suite to use our data held on
SQL 7. We have Dreamweaver and Crystal Reports available but I want to
know if these are suitable or if there are any recommendations for
something I can pick up quickly.
It will be simple reports based on complex queries (... more >>
Using Trigger to populate another table
Posted by jungewum NO[at]SPAM yahoo.com.au at 8/20/2003 9:51:51 PM
Hi all,
I have two tables tbl_A and tbl_B.
Table Definitions:
tbl_A (field_1, field_2, field_3)
tbl_B (field_1, field_2)
I would like to populate tbl_B when a record is inserted into tbl_A.
Note that tbl_A.field_1 = tbl_B.field_1 and tbl_A.field_2 =
tbl_B.field_2 .
How do I write a trigge... more >>
Why wouldn't this work?
Posted by Jeffrey Pratt at 8/20/2003 5:10:40 PM
INSERT INTO AD_Account (AcctName, AcctAddress, AcctCity, AcctState, AcctZIP,
AcctStart, ListID)
VALUES ([AcctNameVal], [AcctAddressVal], [AcctCityVal], [AcctStateVal],
[AcctZIPVal], [AcctStartVal], [ListIDVal])
INSERT INTO AD_AcctContact (ContactFName, ContactLName, ContactTitle,
ContactTel, ... more >>
Help with Deadlock
Posted by Steve Thorpe at 8/20/2003 4:33:26 PM
Hi
I have a deadlock situation and I am trying to debug my Trace Log. How do I
find out what is the cause ?
I can see from the trace I have an exclusive lock on a RID, but how can I
find out what/where 'RID: 7:1:431830:13 ' is ?
Regards
Steve
:TraceLog
2003-08-20 15:15:45.28 s... more >>
Giorni della settimana
Posted by Yachi at 8/20/2003 1:17:48 PM
devo passare all'SQL una stringa where che mi applichi delle modifiche
in un range di data ma soltanto il martedi e il venerdì per esempio,
opppure soltanto il giovedì e la domenica: Riporto un esempio:
......
......
......
WHERE DATA BETWEEN 'Datainizio' AND 'DataFine' AND
................... more >>
autonumbering question - newbie
Posted by ccrupper NO[at]SPAM hotmail.com at 8/20/2003 12:21:57 PM
I'm just getting into SQL server, so I apologize if this is a basic
question. Most of my experience with DBs comes from Oracle, so that's
the reference from which I'm working.
I'm trying to use the identity property in MS SQL Server to autonumber
a unique identifier field, and I'm wondering i... more >>
add and subract time to a date
Posted by billy_cormic NO[at]SPAM hotmail.com at 8/20/2003 11:02:01 AM
Hello all,
Lets say I have the current date and I would like to get the date
two weeks in advance. How would I do this in T-sql? The T-SQL should
take into account if the month changes. For example, if todays date
is 1/17/2003 the advanced date would be 2/17/2003.
Thanks,
Billy... more >>
Use getdate function in a own Function
Posted by raj_chins NO[at]SPAM rediffmail.com at 8/20/2003 9:46:32 AM
Hi,
I have written a stored proc with some temporary tables and also used
a getdate() in my stored proc. When i try to call the sproc the error
is that we can only use extended sprocs or function inside a sproc.
Now if try to write the stored proc directly inside a fuction ie copy
paste after c... more >>
Getting 0 padded values in the columns.
Posted by bschandramohan NO[at]SPAM yahoo.com at 8/20/2003 1:36:53 AM
Getting 0 padded values in the columns.
Hi All,
I have a requirement to convert a integer to string and display it in
Sql server with fixed length say 3 chars. (in c, we wud use %03d in
printf)
If the number is small say, 9 then it has to be displayed as 009,
56 -> 056, 897-> 897, 6786 ... more >>
nubee sql question.
Posted by nubee at 8/20/2003 12:39:23 AM
I have a table with first_name, last_name, salary, other_columns. I can
produce sql to print the max salary but only with the salary column. How
do I get first_name and last_name etc to show with the max(salary).
Thanks
... more >>
Sony laptop with AMD processor - Cannot install SQL
Posted by meh at 8/19/2003 11:55:11 PM
I have above server and I cannot install MS.SQL server on it.
I have WIN-xp professional.
I tried sql 2000 personal version as well as sql 2000 professional version,
it says "cannot install on this operating system "
I would appreciate if someone please help me.
Thanks.
... more >>
How to provide security to Stored Procedures
Posted by savindya NO[at]SPAM flashmail.com at 8/19/2003 7:28:41 PM
Hi all,
I know that it is possible to encrypt Stored Procedures using 'with
encyption'.But my problem is that when there are so many decripting
methods available how far will the encyption be secure.
Is there any other method to encrypt the stored procedures that are
residing on the custome... more >>
I am struggling through views
Posted by phantomtoe NO[at]SPAM yahoo.com at 8/19/2003 5:21:47 PM
Hi there, it's me again. I am having trouble with a view again. I am
trying to do a calculation, but there are some checks that need to be
taken into consideration. Maybe a view is not the right way to deal
with this. I don't know.
This is the beginning of my query.
SELECT coalesce(f.fil... more >>
opening cursor on result set from stored proc
Posted by rsood22 NO[at]SPAM yahoo.com at 8/19/2003 4:03:02 PM
In SQL how can a cursor be opened to iterate the result set returned
from a stored proc
-Rahul Sood
rsood22@yahoo.com... more >>
PATINDEX and '[' character
Posted by John Winterbottom at 8/19/2003 1:50:01 PM
Hi all
Using SQL Server 2000 SP3 on WIn2K Pro with SP2.
When I do this
SELECT PATINDEX('%[%', 'ABC[DEF')
GO
I get a result of 0, when I would expect a result of 4.
This works as I expect:
SELECT PATINDEX('%]%', 'ABC]DEF')
GO
I must be missing something re... more >>
DTSRUN: To multi-tier or not to multi-tier. that is the question...
Posted by jpollins NO[at]SPAM eqt.com at 8/19/2003 11:52:39 AM
Greetings,
We are trying to set up a set of "Leading Practices" for our
developers, as well as ourselves, and hope some gentle reader can
recommend some documentation in favor of what appears to be the right
position to take.
We do not allow third party applications to run on our SQL Server... more >>
Converting Oracle SQL to MS-SQLServer SQL
Posted by mike_arnold_landis NO[at]SPAM hotmail.com at 8/19/2003 10:22:33 AM
Hello,
Has anyone a small tool or somekind of document which could help me
to convert Oracle SQL scripts to SQL Server?
Scripts are not very Oracle specified.
Thanks,
Below is a Script that I would e.g convert to MS SQLServer:
SET SCAN ON
PROMPT Enter the password and TNS name... more >>
Copying data from SQL2000 to DB2 8.1
Posted by Jep at 8/18/2003 2:24:36 PM
I have to setup some scheduled tasks to copy 3-4 tables from an
SQL2000 database to DB2 v. 8.1.
The job must run every night replacing all data.
How can this be done - with standard utilities??
Please be exact - I'm new to this.
Thank for any help.
/Jep
... more >>
Replication - Changes to Server database's impact to local database
Posted by dipillama NO[at]SPAM nswccd.navy.mil at 8/18/2003 1:34:50 PM
We have a SQLSERVER database that is replicated to many users.
We are currently in an expansion phase where we need to make changes
to the server database. Each time we rollout a new release, we are
deleting the local replicating database and recreating.
Is there any way to automatically tran... more >>
stored procedure make string from table field
Posted by paul.kasparbauer NO[at]SPAM vit.linhardt.com at 8/18/2003 7:46:26 AM
Hallo !
I have a Table with a column "ordernumber"
ordernumber
A12
A45
A77
A88
Is it possible to create a stored procedure which makes a string of these column ?
Result: string = ('A12','A45','A77','A88')
Thanks !
aaapaul... more >>
SQL Question
Posted by ejones NO[at]SPAM perriergroup.com at 8/18/2003 7:29:27 AM
I have a stored procedure that is used to call on other
stored procedures and I want to post a record to a
"logging" table that I have created after each called stored procedure
is finished running. I thought I had the coding correct, but I
keep getting the following error message:
Server:... more >>
Stored procedure
Posted by Alan at 8/18/2003 12:47:01 AM
If I created a stored procedure such as aa_procedure, how the other user
refer to this procedure ?
... more >>
System tables
Posted by Alan at 8/18/2003 12:46:47 AM
Do you know where the system tables for a database are stored ? On which
file ?
... more >>
Local or global variable in an interaction session of the SQL analyzer
Posted by lluum NO[at]SPAM yahoo.com at 8/17/2003 12:58:59 PM
Hi,
I am new to SQL. Please bear with me and allow me to ask a dumb
question.
I am debugging a stored procedure (written in Trans-SQL), and I found
that the SQL analyzer that I use doesn't have a debugger. All I can
do it is execute a block of code and see what is going on in an
interac... more >>
ORACLE BEFORE INSERT EQUIVALENT IN SQL SERVER
Posted by macdtb NO[at]SPAM mac.com at 8/17/2003 6:52:34 AM
I am having trouble creating an INSTEAD OF trigger in SQL Server to
replicate a BEFORE UPDATE trigger from ORACLE.
Here is a sample of the ORACLE BEFORE UPDATE trigger:
CREATE TRIGGER myTRIGGER ON MYTABLE
begin
:new.DT := SYSDATE;
if :new.NM is NULL then
:new.NM := USER;
end i... more >>
Unable to ALTER a temporary table in TSQL
Posted by jsausten NO[at]SPAM hotmail.com at 8/17/2003 12:17:58 AM
Is it possible to ALTER a temporary table in TSQL (SQL2000)?
The following TSQL reports a syntax error at the ALTER TABLE line:
DECLARE @Test TABLE(
[Col1] [int] NOT NULL ,
[Col2] [int] NOT NULL
)
ALTER TABLE @Test
DROP COLUMN Col2
I was hoping this would work the same way a... more >>
Is It possible to disable drop database for sa or sysadmin also ?
Posted by masri NO[at]SPAM vsnl.com at 8/16/2003 1:08:59 AM
Hello,
I would like to know is it possible to disable drop database for sa
or sysadmin. If saor sysadmin needs to drop the database , he/she may
have to change status in one of the system tables (sysdatabases ?) and
then only database can be dropped . This is to avoid dropping the
database... more >>
SQL Server Space
Posted by rc NO[at]SPAM die NO[at]SPAM you NO[at]SPAM !spammers.sandworm.demon.co.uk at 8/15/2003 10:08:34 PM
I have a SQL server that is running out of log space.
I have several NAS box availabe to with lots of space, is there any I
can use maped drive to store the logs in.
I am not too concrned with speed
... more >>
SQL 2000 desktop
Posted by Doug at 8/15/2003 9:35:02 PM
Is it possible to install SQL 2000 desktop without installing a database
server? I need to have the interface to access my database servers, but
don't want the overhead of a server and the service on my laptop.
Possible?
Thanks
Doug
... more >>
SQL eqivalent to VB FIX or INT?
Posted by Peter Kaufman at 8/15/2003 6:31:35 PM
Hi,
Is there anyway with SQL to return just the portion to the left (or
right) of the decimal place like FIX or INT in VB?
Specifically, I am trying to return just the hh:mm of a datetime
field.
Thanks,
Peter
... more >>
creating an existing db schema baseline
Posted by wukie at 8/15/2003 4:40:41 PM
What is the best method of creating schema creation scripts that can be
stored into a version control system. The process of using em to
generate a script is not an appealing option. I am still learning the
MS Sql sys tables and have not found a useful list of all the codes &
types to join t... more >>
Treatment of Special Characters
Posted by qwert12345 NO[at]SPAM boxfrog.com at 8/15/2003 3:29:15 PM
Hi,
This is a generic question, but for arguement's sake, let's say, my
environment is SQL Server 2000.
It seems that setting quoted_identifier off is the best way to
accomodate all sort of data input/update especially for data set that
contains special characters like single quote as in O'... more >>
Upgrading from Sybase Sql Anywhere 5.5.04 to SQL Server 2000
Posted by john NO[at]SPAM jbrister.freeserve.co.uk at 8/15/2003 2:30:17 PM
Has anybody had any experience of this??
We have over 2000 stored procs to convert from Watcom SQL to SQL
Server 2000. Any automated tools would be much appreciated!!
Also any known issues.... more >>
DB Maintenance Plan - single user mode
Posted by Mark S at 8/15/2003 12:31:54 PM
I have a db maintenance plan which is set to backup (then truncate hopefully)
the transaction log. In order to backup a transaction log the db must be in
single user mode so the maint. plan fails. How do you automatically set the db,
in single user mode, for the transaction log to be backed u... more >>
Query Analyser 2000 vs 7.0
Posted by For example John Smith at 8/15/2003 11:15:18 AM
ISTR QA running in 7.0 would return print statements and messages as the
query ran (well, after a "GO" statement anyway). In 2000 it doesn't return
any messages until after the entire query batch has completed. In wanting to
keep an eye on progress on long batches, how can I make 2000 work more l... more >>
sql sub query question with count
Posted by spark NO[at]SPAM adsgroup.net at 8/15/2003 9:19:22 AM
Hi,
Situation:
Need a query to return number of ticket records by month of open in a
log table where the ticket open record is older than 24 hours then the
ticket pending or ticket closed record. Tickets can also only have a
closed record with no open record.
Sample data table:
ticket_id... more >>
Need a function
Posted by jennifer1970 NO[at]SPAM hotmail.com at 8/15/2003 9:15:41 AM
I'm looking for a string function that is similar to the INSTR
function in VB. I haven't seen anything in the help files that I can
use. Does anyone have any suggestions?
Here's what I'm trying to do:
There is a field in a table that will look something like this -
"XXXXXX - YY".
I want ... more >>
Table Scans - more rows brought back than in table
Posted by ryanofford NO[at]SPAM hotmail.com at 8/15/2003 7:08:28 AM
I have a query which is quite complex. It's based on a set of data in
a complex view which takes the data from several tables.
In this complex query, if I allow the various parts of the query to
work on the results of the view (MISView), it can take 15 minutes to
run (eek !), however, if I cre... more >>
Server Configuration Advice Requested
Posted by spoogebucket69 NO[at]SPAM yahoo.com at 8/15/2003 5:38:20 AM
I'm looking for configuration advice for a SQL Server. I have the
following hardware to work with:
1 Dell P4 2.66 GHz PC with 512 MB RAM and a 40GB IDE drive
2 Seagtate Barracuda 4.55GB SCSI drives (ST34572W) in an external bay
1 Adaptec 2940UW SCSI Controller
Windows 2000 Advanced Server
M... more >>
|