Viewing 15 posts - 4,906 through 4,920 (of 6,036 total)
Jeff, I see nothing was dealt here.
Key words:
We have been asked to add some additonal calculations into the database which have been specified in Excel.
Guys just copied Excel tables...
October 19, 2006 at 7:05 pm
Nice tries, my friends.
But I would fire a database designer who puts same meaning values in different columns of the same table. Immediately. Without any discussions.
You should not compare values...
October 19, 2006 at 2:47 pm
@ShipmentStatus is varchar(10)
What is datatype of column ShipmentStatus?
October 19, 2006 at 1:37 pm
You should not have data solutions based on human knowledge.
Application should not rely on your memory.
You've no categories unless you've got them in database.
Create table "Category" and insert 3...
October 18, 2006 at 8:55 pm
> The categories are not stored in the database
They should be. You cannot report something what does not exist.
> but if they matches some conditions they fall into that category
So,...
October 18, 2006 at 7:21 pm
Welcome to the club! ![]()
Have been there, so can probably explain.
Trigger is a transaction. It waits utill all its commands completed to commit or,...
October 18, 2006 at 4:40 pm
cls, did you hear about ISNULL system function?
October 18, 2006 at 3:24 pm
Can you explain what exactly do you mean by the last sentence?
If you have "deleted" row with the same Client_id and Code_id as you are trying to insert you must...
October 18, 2006 at 3:17 pm
Both solutions are wrong.
If you use TOP you must specify ORDER BY. Otherwise your result depends on occasional physical order of rows in table.
Try this:
--create temp table and populate values
create...
October 18, 2006 at 2:50 pm
If some body has depression and gonna commit suicide, please try to help them out and then start giving big big lectures!
October 18, 2006 at 2:28 pm
You must LEFT join table to itself on JT.Effective_Date > T.Effective_Date
October 18, 2006 at 1:35 pm
If you want to "undelete" "deleted" row you must change status on existing row, not create duplicates.
October 18, 2006 at 1:32 pm
Wrong table design again.
People, relational database IS NOT EXCEL SPREADSHEET!!!
Table must look like this:
Row# DataRange DatValue
1 ColA 5
1 ColB 10
1 ColB 12
1 ColD 0
2 ColA 4
2 ColB 2
2 ColB ...
October 18, 2006 at 1:20 pm
But I would do just this:
IF EXISTS(SELECT * FROM MASTER..SYSDATABASES WHERE NAME = 'myTESTdb')
EXEC ('exec myTESTdb.dbo.SomeMoreTsqlProcedure')
October 17, 2006 at 5:54 pm
Yes, you are right, but I prefer to use NULLIF. It provides better performance.
ISNULL(SUM(correct)*100 /NULLIF(SUM(answered ), 0), 0)
And if you need not integer percentage you need to use...
October 17, 2006 at 4:02 pm
Viewing 15 posts - 4,906 through 4,920 (of 6,036 total)