all groups > sql server (alternate) > august 2007 > threads for august 15 - 21, 2007
Filter by week: 1 2 3 4 5
Accessing one db by two sql server installations (eg. native vs vmware)
Posted by HP at 8/21/2007 11:58:52 PM
Hi there
As many people nowadays, I have 2 XP installations on my laptop - one
running natively and one in vmware box running on ubuntu (situation
even more common with osx on intelmacs).
Since I would like to be able to work on same development projects in
both these environments, dependin... more >>
Need to find instances of duplicates within a column; joining 2 tables.
Posted by aknoch NO[at]SPAM gmail.com at 8/21/2007 4:33:31 PM
My basic situation is this - I ONLY want duplicates, so the opposite
of DISTINCT:
I have two tables. Ordinarily, Table1ColumnA corresponds in a one to
one ratio with Table2ColumnB through a shared variable. So if I query
TableB using the shared variable, there really should only be on
record ... more >>
Need help w/ a script
Posted by click37 NO[at]SPAM gmail.com at 8/21/2007 9:28:07 AM
Is there a query that will let me see what SQL users has what access
to which DBs and what lvl access they have?
... more >>
ssis EXEC command
Posted by gelangov NO[at]SPAM hotmail.com at 8/21/2007 8:38:27 AM
I have 2 variables, one is the column name of the table and the other
one is the table name and I need to write this in the "Execute SQL
task" of a "For each loop" container in a ssis package like this:
Truncate table <tableName>
Insert into <tableName>
Exec (' select [' + ?+ '] from '+ ?)
... more >>
Problem with DB_OWNER role..
Posted by monty at 8/21/2007 7:13:20 AM
Hi All,
I am facing a problem while executing a statement through C++ code
using OLEDB API of Sql server.
There is a problem with DB_OWNER role. If I will enable the DB_OWNER
everything is going fine but if I will remove this role than I am
getting error "DB_E_ERRORSINCOMMAND".
But if I w... more >>
MS SQL dealing with duplicate columns in rows?
Posted by Yas at 8/21/2007 2:04:21 AM
Hello,
Suppose I have the following table...
name employeeId email
--------------------------------------------
Tom 12345 tom@localhost.com
Hary 54321
Hary 54321 hary@localhost.com
I only want unique employeeIds return. If I use Distinct it will still
return all of the above as... more >>
A floating point exception occurred in the user process
Posted by Massa Batheli at 8/20/2007 6:55:24 PM
sql server 2000 sp4 build 2184
runs stats with maintenance plan
sp_msforeachtable
stored procedure updating full stats for each table and the results
are identical
A floating point exception occurred in the user process. Current
transaction is canceled.
all pointers are to move to late... more >>
SQL Server error
Posted by Leisses Loud at 8/20/2007 5:45:52 PM
Hi,
I was trying to restore my database and received the error described
in image.
http://img404.imageshack.us/my.php?image=errorestorebibliosescdb3.jpg
I just search for a solution but didn't found yet.
If someone could help me I'd be grateful.
... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
An expression of non-boolean type specified in a context where a condition is expected, near ')'.
Posted by pbd22 at 8/20/2007 1:10:56 PM
Hi,
I am trying to create an update statement
on a table with a foreign key to the Users
table (userid).
I am getting the error:
An expression of non-boolean type specified in a context where a
condition is expected, near ')'.
Below is the Update statement.
UPDATE LastLogin SET
... more >>
Dinamyc Function
Posted by aCe at 8/20/2007 10:27:41 AM
Hi all,
i wanna ask about dinamyc Function (FN).
This is my table :
CREATE TABLE [dbo].[unit](
[unitid] [int] IDENTITY(1,1) NOT NULL,
[unitname] [varchar](20) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[description] [varchar](50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT
NULL,
[date_creat... more >>
Copy data from one table to another table with change in identity column values
Posted by satish at 8/20/2007 9:21:30 AM
HI,
I have a table
Create table test(a int identity(1,1), b int)
insert into test(b) values(12)
insert into test(b) values(30)
insert into test(b) values(65)
insert into test(b) values(78)
insert into test(b) values(36)
o/p
a b
1 12
2 30
3 65
4 78
5 36
i need to copy the ta... more >>
SQL Profiler - SPID
Posted by wesleym312 NO[at]SPAM gmail.com at 8/20/2007 12:28:04 AM
Hi,
What is the SPID column for in SQL Profiler?
I have many databases but I only want to view the transactions on one
particular database. What changes should I make to the filters inorder
to achieve this. I have tried database name but that doesnt work.
Thanks in advance
Wes
... more >>
How to check if a Table is <empty> ie doesnt contain any rows
Posted by Yas at 8/18/2007 7:52:35 AM
Hi, is there a way I can check if a table is empty and contains no
rows?
I have a Table1 which being dynamic can sometimes end up with now
columns what so ever. I'm using Table1 in one of my views along with 2
other tables and I would like put a condition at the...something like
AND Table1 IS... more >>
Inconsistent identity values
Posted by at 8/17/2007 7:04:36 PM
SQL Server 2005
We have a table where the current identity value is lower than the
maximum value. This is the first time I've seen such a thing. How
can this occur? I see postings about this problem but they seem to
concern older versions of SQL Server.
I did some tests on another table ... more >>
Combine record
Posted by dede at 8/17/2007 5:05:15 PM
Hi guys..
is there any query to do this action:
i want to combine view record into a single record.
exm.
table 1
Name A B
Jack 10 22
jack 12 21
jack ... ....
jack 1 11
ben 12 2
ben 3 2
ben ... ... more >>
TABLESAMPLE question
Posted by WhytheQ at 8/17/2007 3:31:13 PM
I have been using NewID but was advised to use TABLESAMPLE as it would
be more efficient - unfortunately I can get it to work properly.
This comes up with nothing:
'=====================
USE myDatabase
SELECT *
FROM myTable
TABLESAMPLE (1 ROWS)
'====================
....whereas this w... more >>
Unaccountable jump in Identity column value
Posted by teddysnips NO[at]SPAM hotmail.com at 8/17/2007 2:18:23 AM
And here's another thing that's gives me pause for thought (for other
information see the thread entitled "ODBC Timeout problems but very
hard to pin down")
In APP 1 (Access front end, SQL Server 2000 backend) there is an
operation to generate a discrepancy report. These are numbered
sequent... more >>
How to create an admin with some limitations?
Posted by bertainafederico NO[at]SPAM gmail.com at 8/16/2007 11:54:53 PM
I've a SQL 2005 with a certain number of db.
Until today i was the only admin of all dbs.
Now i need to give to another admin permission to manage one specific
db (but only that).
Ho censito un utente di sql con accessi abilitati solo a quel db.
If i connect to Enterprise manager with that limi... more >>
WHERE question
Posted by ceconix at 8/16/2007 9:19:02 PM
Hello all, I am still learning about SQL, and have a question. I have
two tables. I want to update table 2 with data from table 1. Table 1
has two columns. ID and NUM. In Table 2, I have an ID column and a
bunch more columns plus another NUM column. Table 1 was pulled in
from excel. I nee... more >>
Problem performing remote queries
Posted by rhaazy at 8/16/2007 12:14:22 PM
I am trying to a simple insert statement from a remote application
against a sql server 2005 database. To fix the problem I was having,
I had to grant the Login I was using the role of sysadmin. However I
don't want this user to have that kind of control, what would be the
best role to allow t... more >>
Blindare utente SQL amministratore
Posted by bertainafederico NO[at]SPAM gmail.com at 8/16/2007 8:31:57 AM
Ho un server SQL 2005 con N db.
Al momento ho sempre amministrato tutti i db autonomamente e dunque
con un singolo amministratore.
Ora mi =E8 sorta la necessit=E0 di dare a Tizio i permessi per
amministrare un certo db sul mio server, chiaramente facendo in modo
che possa solo vedere (e lavorar... more >>
Knowledgeable yet simple book for database modelling or database design
Posted by vicky at 8/16/2007 8:18:13 AM
Hi All,
Can u please suggest me some books for relational database design or
database modelling(Knowledgeable yet simple) i.e. from which we could
learn database relationships(one to many,many to one
etc.....),building ER diagrams,proper usage of ER diagrams in our
database(Primary key foreign ... more >>
ODBC Timeout problems but very hard to pin down
Posted by teddysnips NO[at]SPAM hotmail.com at 8/16/2007 5:51:29 AM
One of our clients has reported a problem. Everything was working
fine on Monday, but since Tuesday all is going wrong. The sysadmin
assures me that there have been no changes to the network, or the
servers.
Three applications, one back-end database server (SQL Server 2000 with
all service ... more >>
MS SQL copy new and modified rows from TABLE1 to TABLE2
Posted by Yas at 8/16/2007 5:15:46 AM
Hello,
I have 2 tables, Table1 and Table2. I have copied all data from Table1
to Table2.
However Table1 is dynamic it has new rows added and some old rows
modified everyday or every other day...
How can I continue to keep Table2 up to date without always having to
copy everything from Table1... more >>
data transfer from .csv file to sql server 2000
Posted by sachin shah at 8/16/2007 4:35:51 AM
Hi All,
1. i want to transfer the .csv file data into sql server table, i
tried with the DTS but while creating DSN it not prompt to attech
the .csv file. give me the proper steps to perform the data
transfer...
2. i want result of my query into excel or text file by using the sql
query(... more >>
wants sql query
Posted by sachin shah at 8/16/2007 3:46:13 AM
hi
my table having record
cust_name
sachin's
vishal's
sumeet
rajesh
i want the query which having ' (single quote)character....
result
sachin's
vishal's
... more >>
SELECT a random 10 records from table....easy newbie question
Posted by WhytheQ at 8/16/2007 3:39:49 AM
This doesn't work:
--****************************************
USE myDatabase
SELECT TOP 10 *
FROM myTable
WHERE NEWID()
--****************************************
...I know I need to use the function newID() to find random records -
just don't know where it fits in the query (suspect t... more >>
Creating database from stored proc with variable holding the database name
Posted by gancy26 NO[at]SPAM gmail.com at 8/16/2007 2:57:03 AM
Here is my code
ALTER PROCEDURE Test
AS
BEGIN
-- SET NOCOUNT ON added to prevent extra result sets from
-- interfering with SELECT statements.
SET NOCOUNT ON;
DECLARE @From varchar(10)
DECLARE @To varchar(10)
DECLARE @DBName varchar
SELECT TOP 1 @From = CONVERT(char,CreateDate... more >>
month name from the sql query
Posted by sachin shah at 8/15/2007 11:48:37 PM
Hi all
i want result as month name from my query
i tried with the following query but it give result as month number
like (8)
select (month(getdate())) as expr
i want result as month name (Augest)..
give me the proper query...
from Sachin
... more >>
Create script to insert 200 rows into table
Posted by rhaazy at 8/15/2007 2:42:21 PM
I have to create a script to install a database, and one of the tables
has about 200 rows of static data... I dont want to have to manually
type in 200 insert statements, so is there a better way to do this? I
thought about maybe exporting the data into a CSV file and using some
sort of proced... more >>
Limit query execution time
Posted by rcamarda at 8/15/2007 6:58:12 AM
Hello,
I ran a query that I thought would take an hour, but instead took 14
hours to run. The consequence was it bogged down our data warehouse
and the overnight build was adversely impacted.
Is there a local setting I can set to limit the execution time my
query will take? I dont want to have ... more >>
standard and easy way to do schema design
Posted by Summercoolness NO[at]SPAM gmail.com at 8/15/2007 4:08:40 AM
I wonder instead of just brainstorming, there probably is
a very standard and a simple way to do database schema design.
let's say we are doing a website. the user can go over
and type in the movie name and zipcode, and the website
will return all the theaters showing that movie and at what
... more >>
Backup plan reccomendations for user with ZERO experience.
Posted by scott s at 8/15/2007 2:49:17 AM
Hello all, I was just awarded the job of maintaing the database server
for our company. I have basically ZERO experience using MS SQL Server
2000. Can anyone point me in the direction of a good resource for
creating backups of our database? I would love something that comes
with a gui that reall... more >>
|