all groups > sql server programming > february 2004 > threads for sunday february 22
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
Please help me with this query...thanks
Posted by Kim at 2/22/2004 8:55:45 PM
How can I do this in one query
I've got a table like this
ID RESOURCEID DATE QUANTITY
The Id is unique (but just a counter not of interest here), there may be one
resourceid for each date and then an asscoiated quantity.
I want to select all resourceid (distinct) and I just want just the
... more >>
'Parameters' question
Posted by Suzanne at 2/22/2004 7:18:01 PM
Hi...This is another problem that is eluding me.
Suggestions on how this should be coded in Sql 2000? I
receive 'incorrect syntax' for 'text' on line 1
and 'tblApTransInvoiceTax' on line 4.
PARAMETERS pTransId Text ( 255 );
DELETE DISTINCTROW tblApTransInvoiceTax.*,
tblApTransInvoice... more >>
Help needed with IIF syntax
Posted by Suzanne at 2/22/2004 7:12:41 PM
Hi...I'm converting this database to SQL Server 2000. I
have this query that is checking if a field contains a
value or not..if not, then set the value to zero.
However, Query Analyzer is giving me the error "syntax
error near the keyword Not'" on the first line (the
Select statement). ... more >>
BCP from a database that has a "." in the database name
Posted by Martin Zachs at 2/22/2004 4:56:14 PM
I'm trying to execute a BCP command against a database that has a "." in the
database name. In the statement below, 'somecompany.com' is the database
name. The statement is running on the same server as where SQL Server is
installed, so the -S, -U, -P flags aren't needed.
bcp [somecompan... more >>
use of INSERT with Dynamic SQL
Posted by Edi Fellmann at 2/22/2004 4:16:07 PM
I need to execute with INSERT to a table which name changes
I supose the only way is to use dynamic SQL.
First we create the MyTable table
The spInsertMyTable inserts the values, no problems
The spInsertMyTableDynamic does not work. I send the error message
Is there a way to execute an INSERT s... more >>
string in a query
Posted by Paul at 2/22/2004 2:41:06 PM
I have a table named a_Users_Portfolios
that has a
column named Portfolio_Symbols of type NVarChar 150
in which I've stored strings in the format 'a', 'c', 'f
that I'm returning in the WHERE clause belo
via the subquer
(SELECT Portfolio_Symbols FROM a_Users_Portfolios WHERE (UserID = @UserID) ... more >>
Problems with date and other countries
Posted by Greg at 2/22/2004 1:43:20 PM
How can I specify a date that will work every regional setting with MS SQL
Server 2000?
After searching I found the following code but it isn't doing it... the
problem still remains: CONVERT(datetime,'" & NOW & "',120)
... more >>
Truncating, Deleting or Shrinking Log File
Posted by martino rivaplata at 2/22/2004 12:35:26 PM
Hello There.
I have a SQL database whose log file has grown so big that
i cannot even perform a backup because error 112, lack of
space.
Problem is i do not have disk space anywhere else. I
really do not care about the log file since my database is
not a intensinve daily inserts tran... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
Pass SQL function as stored procedure param?
Posted by Jeremy Collins at 2/22/2004 11:35:43 AM
Hi all,
Is it possible to create a stored procedure where I can
pass "SUM" or "AVG" etc as a parameter?
Something like
CREATE PROCEDURE astp_summary @ItemID int, @Func varchar(3)
AS
SELECT ItemID, @Func(Score) AS TotalScore
FROM tb_table
WHERE ItemID = @ItemID
GROUP BY Item... more >>
Programming DDL
Posted by Morpheus at 2/22/2004 9:31:05 AM
I'm not sure that this is the right fourm, but here goes
I've written an application in Delphi that generatres SQL Statements quickly and easily
It is looking more and more like SQL Query Analyser, but it has more and different functionailty
I ma busy implementing an object browser similar to the... more >>
Top Caluse With Variables without SET ROWCOUNT
Posted by Muhammed Fawzy at 2/22/2004 2:44:28 AM
Hi,
I Want to use the top caluse with variables in a stored
procedure or UDF but in sql server 2000 this is not
allowed .
how can i do this without making dynamic sql using exec,
,using spexecquery or using SET ROWCOUNT
thanks alot
... more >>
|