Showing posts with label half. Show all posts
Showing posts with label half. Show all posts

Thursday, March 22, 2012

calculated field in SQL 2000

I need a calculated field C with several CASES.
If (field A is 'daily' or 'half day' or 'hourly') and (field B is NULL) then C= D-50
If (field A is hourly and field B is NULL then C= 850
I don't know sql server 2000 well enough to create this query.
thanks
Milton

Are you trying to create a calculated column in a table or you need a SELECT query with this calculation?

|||

I need a SELECT query or view.

thanks
Milton

|||

Check out the CASE statement in Books On Line. Its pretty much self explanatory. They have illustrated it with some sample code too.

|||

I need to know the web site. I looked up books on line and found many sites with that URL. booksonline, books-on-line etc. none that I looked through were free and non had sql 2000.

|||

Here.. Its absolutely free..http://technet.microsoft.com/en-us/sqlserver/bb428874.aspx check the language you want to download it in on the right..

|||

miltonsnider:

I need a calculated field C with several CASES.
If (field A is 'daily' or 'half day' or 'hourly') and (field B is NULL) then C= D-50
If (field A is hourly and field B is NULL then C= 850
I don't know sql server 2000 well enough to create this query.
thanks
Milton

give it a try as start...

SELECT CASE WHEN (A LIKE 'hourly' AND B IS NULL) THEN 850 -- If (field A is hourly and field B is NULL then C= 850
WHEN (A LIKE 'daily' OR A LIKE 'half day' OR A LIKE 'hourly') AND (B IS NULL) THEN D - 50 END--If (field A is 'daily' or 'half day' or 'hourly') and (field B is NULL) then C= D-50
AS 'C'
FROM TBL_TABLE1

(without Comment)

SELECT CASE WHEN (A LIKE 'hourly' AND B IS NULL) THEN 850
WHEN (A LIKE 'daily' OR A LIKE 'half day' OR A LIKE 'hourly') AND (B IS NULL) THEN D - 50 END
AS 'C'
FROM TBL_TABLE1

hope you get some idea...

Sunday, February 12, 2012

Business Intelligence in SQL Express?

Hello,

I have spent about half an hour looking for an answer to this, so apologies if I have missed it.

Can you get Business Intelligence Development Studio together with SQL Server 2005 both in Express editions? There was mention of an Express toolkit which includes BIDS but it seemed to imply you couldn't combine it with SQL Server Express.

If not, what is the cheapest way for an individual to get Business Intelligence Development Studio? My evaluation edition is about to run out.

Thanks,

I'll answer this myself - searching this forum indicates BIDS is included in the Toolkit, so I will try that and close this thread.