|
 |
asp_ado_rds thread: Setting Prepared Property to True...
Message #1 by "Vikas Sethi" <emailtovikas@r...> on Sat, 17 Feb 2001 16:32:51
|
|
Hi,
If we set the value of the Prepared property of the Command Object to True
then the Server first compiles the SQL Statement given within the
CommandText property and then executes the CommandText.
My Question is:
Does the compiled version of the SQL statement created by the Server is
persistent in nature ?? i.e whether the Server permanently stores the
compiled version for future references or is it of temporary nature.
In case it is of Persistent nature then is there any performance issue
between Stored procedures and setting this property to True.
Thanks...
Message #2 by James De Los Santos <JamesDLS@B...> on Tue, 20 Feb 2001 10:18:15 -0600
|
|
From what I have read, setting the Prepared property to True causes SQL
Server to store a compiled version of the command for the duration of the
connection. Once the connection is closed, the compiled command is
destroyed. Now that connections can be pooled automatically, closing
connections as soon as they are no longer needed is advantageous. Unless
you are issuing a complex command, I believe that closing and reopening the
connection would be better than issuing a Prepared command and leaving the
connection open.
James
-----Original Message-----
From: Vikas Sethi [mailto:emailtovikas@r...]
Sent: Saturday, February 17, 2001 10:33 AM
To: ASP_ADO_RDS
Subject: [asp_ado_rds] Setting Prepared Property to True...
Hi,
If we set the value of the Prepared property of the Command Object to True
then the Server first compiles the SQL Statement given within the
CommandText property and then executes the CommandText.
My Question is:
Does the compiled version of the SQL statement created by the Server is
persistent in nature ?? i.e whether the Server permanently stores the
compiled version for future references or is it of temporary nature.
In case it is of Persistent nature then is there any performance issue
between Stored procedures and setting this property to True.
Thanks...
|
|
 |