|
code
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
open db questiondoes not need a sql command and it only open "ShowActivies"; is it a store procedure? strSQL = "Select Description, ActivityId from Activity where ActivityName = '" + cmbActivities.Text + "'" With rst .CursorLocation = adUseClient .Open strSQL, conn.ConnectionString, adOpenStatic, adLockBatchOptimistic End With ---------------------------------------------------- With rst .CursorLocation = adUseClient .Open "ShowActivities", conn.ConnectionString, adOpenStatic, adLockBatchOptimistic End With Cheers! Claudi *** Sent via Developersdex http://www.developersdex.com *** No, it is a view built based on a table Activity or it is a table. If
you want to run sp using this particular syntax it should look like this: ..Open "exec <StoreProcedureName> [parm1, [parm n]]", conn, adOpenStatic, adLockBatchOptimistic so if you have a following sp: CREATE PROCEDURE spShowActivities @ActivityName varchar(100) SET NOCOUNT ON SELECT Descripion, ActivityID FROM Activity WHERE ActivityName = @ActivityName SET NOCOUNT OFF your Open statement would look: ..Open "exec spShowActivities " & cmbActivities,Text, conn, adOpenStatic, adLockBatchOptimistic It's not a table.. but if is a built view.. what is a built view ?
Cheers! Claudi *** Sent via Developersdex http://www.developersdex.com *** On Nov 15, 10:33 am, Claudia Fong <cdolphi***@yahoo.co.uk> wrote:
> It's not a table.. but if is a built view.. what is a built view ? A View or Built View the same thing, just allows you to persist any> SELECT statement (query) in database. In short it is a logical table based on one or more tables or views. Depends which database you are using the naming will differ, in MS SQL Server and Oracle use Views, Access uses Queries, etc. Since we don't know what database you are using it is hard to give you any specific information. In article <b9d9ddd3-4d11-4d1c-a65f-cd2a0ef5f334
@a28g2000hsc.googlegroups.com>, naj***@hotmail.com says... > On Nov 15, 10:33 am, Claudia Fong <cdolphi***@yahoo.co.uk> wrote: And then there are "materialized views", which are a different variation > > It's not a table.. but if is a built view.. what is a built view ? > > > A View or Built View the same thing, just allows you to persist any > SELECT statement (query) in database. In short it is a logical table > based on one or more tables or views. Depends which database you are > using the naming will differ, in MS SQL Server and Oracle use Views, > Access uses Queries, etc. Since we don't know what database you are > using it is hard to give you any specific information. on the theme, in that they are not generated at call time like regular views are, but are created and stored in the .db as the tables they are built on change. -- Remove the ns_ from if replying by e-mail (but keep posts in the newsgroups if possible). |
|||||||||||||||||||||||