• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 270
  • Last Modified:

NTILE problem

When I use NTILE in a query inside of SQL server management studio it stops working. I can use NTILE in the SQL Query ANalyzer with no problem.

I do not see any entries in the Server Log about a problem.

Any ideas? Thanks.
0
mfony
Asked:
mfony
  • 4
  • 4
1 Solution
 
Anthony PerkinsCommented:
When I use NTILE in a query inside of SQL server management studio it stops working.
Care to elaborate?  
Where specifically does it "stop working"? Query Window?  Designer (ug!), somewhere else?
How does it "stop working"?
        1. Error message, if so what was the error message?
        2. Wrong results, if so what are they and what was the expected output?
        3. Something else?

I can use NTILE in the SQL Query ANalyzer with no problem.
SQL Query Analyzer was a tool that came with SQL Server 2000, so you cannot be using that as SQL Server 2000 did not support NTILE.
0
 
mfonyAuthor Commented:
I get a window that says the  management studio stopped working. Like the program had a glitch.

SQL query analyzer can connect to a 2005 database and NTILE works fine.
0
 
Anthony PerkinsCommented:
I get a window that says the  management studio stopped working. Like the program had a glitch.
SQL query analyzer can connect to a 2005 database and NTILE works fine.

I am confused what are you using?  SSMS or SQL Query Analyzer?  If you are using SSMS are you using the Query window or the Query Designer?
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
mfonyAuthor Commented:
I'm executing an NTILE query on a table using SSMS. Open table and use SQL pane then write the NTILE query.

SELECT TICKER, performance, NTILE(4) OVER (ORDER BY performance) FROM LOAD_Performance_Peers
WHERE (Performance IS NOT NULL)
ORDER BY performance
0
 
Anthony PerkinsCommented:
I am afraid I have no idea what is going on.  I tested your query and there was no error message.   Have you checked the integrity of your database recently (DBCC CHECKDB) ?
0
 
mfonyAuthor Commented:
CHECKDB found 0 allocation errors and 0 consistency errors in database
0
 
Anthony PerkinsCommented:
Then I am afraid I have no idea.  Hopefully someone will step up to the plate.
0
 
mfonyAuthor Commented:
Thanks for your help.
0

Featured Post

Receive 1:1 tech help

Solve your biggest tech problems alongside global tech experts with 1:1 help.

  • 4
  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now