Re: Modelers / code generators

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: Frans Bouma [C# MVP] (perseus.usenetNOSPAM_at_xs4all.nl)
Date: 05/22/04


Date: Sat, 22 May 2004 04:32:41 -0700

Mark Goldin wrote:

> Well, I don't think anybody has a definitive answer about
> dynamic SQL versus stored procs.
> I am personally just not ready to give up on SPs.

        I'm not saying you should, at least not for specialized programs, like
extensive calculations on a lot of data, often this is done better in the
database to avoid pulling millions of rows into .NET. I'm more referring to
CRUD operations on rows using stored procedures, the vast majority of actions.

        What I'm interested in is your reasoning behind holding on to stored
procedures. Could you please elaborate on that decision a bit? thanks :)

                Frans.

>
> "Frans Bouma [C# MVP]" <perseus.usenetNOSPAM@xs4all.nl> wrote in message
> news:xn0diko3c57f23001@msnews.microsoft.com...
> > Mark wrote:
> >
> > > Are there good modelers / code generators for C#?
> > > I looked into Deklarit. The only problem I have with it
> > > Is that it uses dynamic SQL, no stored procs.
> > > Don't know if that is the best way to architect n-tier application.
> > > I am looking for something similar to that program but capable of
> creating
> > > stored procs.
> >
> > Why are you focussed on Stored procedures? I mean: generating stored
> > procedures is the same, semantically, as generating Dynamic sql on the
> fly,
> > with bigger disadvantages: the maintenance of the procs is killing
> (replacing
> > a proc with another one, requires you to remove the old proc, however that
> > may break an app etc.)
> >
> > Dynamic SQL is in the long run more efficient, both in
> > maintenance/development and in processing speed.

-- 
Get LLBLGen Pro, the new O/R mapper for .NET: http://www.llblgen.com
My .NET Blog: http://weblogs.asp.net/fbouma
Microsoft C# MVP


Relevant Pages

  • Re: Identical database w/ identical stored procedures?
    ... scripting the proc out and running it on all your DB's how may db's are ... Running straigh sp's over dynamic sql is alway better ... Defragmentation leads to downtime...Downtime leads ... INDEXDEFRAG and DBCC DBREINDEX are the force...May the force be with ...
    (comp.databases.ms-sqlserver)
  • Re: Pass SQL function as stored procedure param?
    ... Build a dynamic SQL statement in the proc and execute via sp_executesql ... Build the SQL statement in your application rather than use a proc. ... WHERE ItemID = @ItemID ...
    (microsoft.public.sqlserver.programming)
  • Re: Variable-named database in a proc
    ... dynamic SQL has been the best method. ... Back in they day, when commodity HW boasted 2GB HDDs and PI 133 MHz CPUs, I used a similar method for linked server queries across a set of sub-servers where the names were only known at run time based on the value of a partial logical key referencing a partition table - giving the query reasonable performance for PK entity select & update across a multi-TB database. ... But we need something to replace the old dbname ... your proc is. ...
    (microsoft.public.sqlserver.programming)
  • Re: create/using type dynamically
    ... Now i am looping thru the keys in a proc .Now for a key, ... values of that key want to use dynamic SQL and FORALL to update that ... In engineering the hardest part ... Please state the business case or business problem you are trying ...
    (comp.databases.oracle.misc)
  • Dynamic SQL in Stored Proc
    ... I have a database setup so that NO users have READ, ... Dynamic SQL and they have stopped working. ... error message when executing one of the stored procs. ...
    (microsoft.public.sqlserver.security)