Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 hi

Author  Topic 

sadbjp
INNER JOIN

41 Posts

Posted - 2007-05-15 : 10:36:12
Hi,


I tried coding the following step:

Set the values of GoalMet comparing the LocalPerf value and SppTarget.Target value with the CompareMethod. If CompareMethod = 1, then LocalPerf >= Target means GoalMet = 1; othwerwise, LocalPerf <= Target means GoalMet = 1.

This is what I have, got error as Incorrect syntax near "=". Can anyone help me with this? Thanks
F (CompareMethod = 1) AND (LocalPerf >= Target)
BEGIN
SET GoalMet = 1
END
ELSE
IF (LocalPerf <= Target)

SET GoalMet = 1

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2007-05-15 : 10:44:06
sadbjp -- why do you think they are asking you to answer these interview questions?

- Jeff
http://weblogs.sqlteam.com/JeffS
Go to Top of Page

sadbjp
INNER JOIN

41 Posts

Posted - 2007-05-15 : 10:45:06
Sorry about that.
Go to Top of Page

sadbjp
INNER JOIN

41 Posts

Posted - 2007-05-15 : 10:45:48
i DON'T KNOW.
Go to Top of Page

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2007-05-15 : 10:53:12
You don't know why they are giving you questions to answer? Perhaps they are asking you these questions to find out if you are qualified for the job? That makes sense, right? Do YOU feel that you are qualified for the job?

- Jeff
http://weblogs.sqlteam.com/JeffS
Go to Top of Page

sadbjp
INNER JOIN

41 Posts

Posted - 2007-05-15 : 10:57:11
These are the questions that appeared in recent years and I am trying solving these questions for a walk in interview to be held this year in july.
Go to Top of Page

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2007-05-15 : 11:00:51
You are going about things the wrong way. Put all these questions into a folder and forget about them. Go to the library. Take out a book on SQL Server. Read it. Download SQL Express. Go through examples, test things, learn about it, ask specific questions here and refer to the on-line Help (Books On Line) as necessary. Google for some SQL Server tutorials or articles for beginners on-line and follow them. Finally, after doing all that and feeling confident and comfortable with SQL, go back to your folder with the interview questions and go through them. They'll make a LOT more sense!

The wrong approach is to post specific questions and ask people to answer them for you; you'll never truly learn the basics if you do it that way. Start with a book. You can read it at home, on the train, on the beach, at the park -- it's very relaxing and you'll cover all the basics. THAT's how you can learn SQL and prepare for an interview.

And, by the way -- don't tell the interviewer that you "hate inner joins". I don't think you'll get hired.

- Jeff
http://weblogs.sqlteam.com/JeffS
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2007-05-15 : 11:04:05
sadbjp, as I told you in other thread you need to Learn SQL

http://www.sql-tutorial.net/
http://www.firstsql.com/tutor.htm
http://www.w3schools.com/sql/default.asp

Also, it is not neccessary that the same question will be asked in all the interviews

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page
   

- Advertisement -