Gasman
Enthusiastic Amateur
- Local time
- Today, 08:37
- Joined
- Sep 21, 2011
- Messages
- 17,499
You need a few more posts before you can post an actual link.Link: (for some reason forums will not accept a link).
You can break it up with spaces.
You need a few more posts before you can post an actual link.Link: (for some reason forums will not accept a link).
There, FTFY!You need afewlot more posts before you can post an actual link.
It is, but I did not want to dishearten them.There, FTFY!
(Currently I think the post count required before being able to post links is 100)
This all sounds very confused - mainly you are using terminology that most here would understand to be something different from what you are trying to describe.AFAIK: Stored Procedures, I believe are compiled so should be early bound objects. This may be the reason M$
distinquishes between non-Stored and Stored, since all code (Symbols in my case) are embedded in the stored procedure.
Whether using TempVar would change a Stored Procedure to late bound, I don't know.
All of that is done using other languages with mostly API calls.Given that forms and reports are Access objects, and given that those objects exist ONLY inside an Access database, this statement begs further explanation. What are you calling "forms and reports?" How do you produce them? How do you use them? Thank you.
So, you still use both terms here - Stored Procedures and Stored Queries - so I'm still not quite clear.Unless I'm WRONG, M$ forces STORED procedures in the SELECT clause to be hardcoded with table field names.
Other SQL clauses (e.g BETWEEN) can be parameratized.
If I recall correctly, -- M$ docs -- STORED Queries are compiled.
Being compiled they should be early bound, and HENCE M$ requirement that the SELECT clause be hardcoded with table field names.
IF STORED Queries are complied, if makes sense, UNSTORED queries would be late bound, AS the fields and the variables in the query are filled prior to the query being called (executed) -- those fields and values would NOT be known to the compiler at compile time.
Either that, or that you can't create the SELECT'ed fields dynamically in a stored query.Suspect the OP is confusing compiled with query plans
Only by modifying the querydefyou can't create the SELECT'ed fields dynamically in a stored query.
believe VBA does Not have a compiler
Where I think a lot of the disconnect is coming from is my view of ACCESS.
I look at ACCESS as being a database (JET), with a RAD attached.
If I recall correctly, -- M$ docs -- STORED Queries are compiled.
Being compiled they should be early bound, and HENCE M$ requirement that the SELECT clause be hardcoded with table field names.
When I stated stored / unstored procedure, I was referring to stored/unstored ACCESS queries. IMHO they are really the same. A query is a procedure. AND unless you know otherwise, ACCESS STORED queries (procedures) require table field names in the SELECT clause to be hardcoded (no variables allowed). .I *think* you are solely talking about Access Stored Queries. Is that correct?
SQL Server doesn't factor in to your setup, or does it?
IF I recall correctly, going back to around 1984/5 timeframe, Access was ONLY a database. I can't recall if M$ bought PARADOX and thenActually, that DOES clarify the confusion. You are looking at Access totally backwards from the way most of us look at it
Per one of my posts -don't reecall which -- that was one of my two options I'm considering.It is entirely possible, maybe even probable, that you are at a point where a different back-end will be your only solution.
I can't recall if M$ bought PARADOX
There have been contradictions between -- and even within -- posts about what tools the OP actually uses or doesn't use, or how they are used, if at all.Access does NOT use stored procedures. Stored procedures are a construct specific to actual RDBMS' such as SQL Server and Oracle. At the moment we are not speaking the same language. Access uses embedded SQL - which means queries that you create on the fly using VBA code. OR it uses QueryDefs which are a construct specific to and limited to MS Access the RAD tool. Since Access treats querydefs and tables as the same type of object for most purposes, other front ends such as Excel can "see" querydefs provided they are SELECT queries and do not use any VBA.
I don't believe any of us have any idea what you are using as a front end - platform which runs your queries and produces your forms and reports. What are you using as the user interface to show/edit your data since you are not using Access. In your mind you have confused Access the RAD tool with Jet and ACE the desktop database engines.
Access the RAD tool is dependent on Jet (.mdb format databases) or ACE (.accdb format databases) to hold object such as forms, reports, querydefs, macros, and code modules. Access is completely independent from Jet and ACE when it comes to storing actual data. Access can use ODBC to link to ANY RDBMS that supports ODBC. You are using Jet to store your data but are calling it Access which is a fairly typical misconception. But you are not using Access and Access doesn't even need to be installed on your computer to use Jet. Looking at it from the other direction, Jet and ACE have their own .exe and Jet can exist without Access at all. ACE is more tightly bound to Access the rad tool. Jet is still an independent desktop database engine and is managed by the SQL Server team. The Access team wanted more control so with A2007, the Access team took a copy of Jet and made it into ACE which gives them independence from the SQL Server team and the ability to deviate if necessary. But Jet and ACE can be used via DAO or ADO from any platform that supports DAO or ADO and you would never have to open MS Access at all. In this case, Access functions as the equivalent of SSMS (SQL Server Management Studio) and gives you a GUI to manipulate table objects so you don't have to use code to define or modify them.
So, please clarify your platform because you need to think about how much of your infrastructure you want to rebuild if you switch from Jet to SQL Server. You could rebuild your application interface using Access the RAD tool and either stick with ACE or switch to SQL Server.
Specificallylearn.microsoft.com/en-us/office/client-developer/access/desktop-database-reference/querydef-object-dao
You can also create temporary QueryDef objects. Unlike permanent QueryDef objects (HERE M$ HAS ADDRESSED BOTH UNSTORED (Temporary) AND STORED (Permanent) QUERIES/PROCEDURES) , temporary QueryDef objects are not saved to disk or appended to the QueryDefs collection ...
You can think of a permanent QueryDef object in a Microsoft Access workspace as a compiled SQL statement. If you execute a query from a permanent QueryDef object,, (NOTE THE WORDING -- PERMANENT and COMPILED)
An SQL can use IFs, ANDs. ORs, NOTs, and SubQueries, which IMHO is programming logic.For example a SP actually supports programming logic and can work with multiple recordsets at one time whereas a querydef is a declarative object limited to the SQL language
An object does NOT have to reside in a library. One can create an object in code, and then use it.. Office is just one library. There are thousands.Early vs Late binding
still don't know if your code is actually running in Access or in a web page or some Python program.
Arrggh. Substituting one term for another in a statement is not an argument about the meaning of those terms.Personally we are beyond the point of this thread and in a debate over whether one calls a "toma'to" a "to'mato".
Since I am unable to post a link, hopefully putting it in quotes will work. ERRORED even as a quote.
I'm deleting the internet prefix in the hopes that works. It does.
This addresses stored and unstored queries (procedures).
Specifically
LASTLY, As Ive addressed above, a compiled object can be early or late bound depending on how it is declared.
As far as the front end, I believe I've addressed this. I use various languages to create objects (e.g. Pictureboxes, Textboxes, Treeviews, etc).
and Reports, mostly using API calls.
HTH