You are here: Re: what are cursors in sql??? « MsSQL Server « IT news, forums, messages
Re: what are cursors in sql???

Posted by David Portas on 03/02/06 22:21

Doug wrote:
> the jump where sql can be categorized as "primitive recursive
> functions" lost me.
>
> Is there a practical limit on how levels of recursion SQL supports?
> Does the SQL spec guarantee that recursion has to be available for say
> 1000 layers?
>
> As I understand your logic, you are stating you can use declarative SQL
> recursively to fulfill the looping role. I am questioning whether the
> SQL spec guarantees say a million levels of recursion.
>
> Am I understanding your premise correctly?

Of course there are practical limits to everything in finite state
machines and real hardware. What is your point? That the resource
constraints on cursors are inherently less onerous than on recursive
queries? If we are talking at the logical level then that is
irrelevant. If we are talking about real implementations then I think
any of the major SQL databases demonstrate otherwise. Those systems are
designed and optimized to perform with set-based operations and more
often than not the set-based operations perform best.

--
David Portas, SQL Server MVP

Whenever possible please post enough code to reproduce your problem.
Including CREATE TABLE and INSERT statements usually helps.
State what version of SQL Server you are using and specify the content
of any error messages.

SQL Server Books Online:
http://msdn2.microsoft.com/library/ms130214(en-US,SQL.90).aspx
--

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация