By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
428,978 Members | 1,467 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 428,978 IT Pros & Developers. It's quick & easy.

Query Log in Access

P: n/a
Hi,

I have an app (lost the source code) that performs many different
queries in order to achieve the results I'm looking for. Re-developing
the app isn't really a big issue...but what would be is trying to
figure out how I did the original database queries (SQL Syntax I used)

I was wondering if there was a way in Access to log all queries made to
a database...or alternatively, was there any app that you guys new of
that can monitor an access database and somehow view any queries made
to it?

By queries, I mean Inserts, Updates, Deletes AND Read
queries...especially READ queries.

Thanks for your time.

Mary.

Nov 13 '05 #1
Share this Question
Share on Google+
11 Replies


P: n/a
<ma************@hotmail.com> wrote
I have an app (lost the source code) that
performs many different queries in order
to achieve the results I'm looking for. Re-
developing the app isn't really a big issue...
but what would be is trying to figure out
how I did the original database queries
(SQL Syntax I used)


In what form is the Access application you have?

You can see the Queries in either an .MDB or an .MDE (the "compiled" MDE
simply tokenizes VBA code and locks design view on Access objects which can
have a code module). It may be that simply holding down the Shift key as you
start the application, or once it is executing, pressing F11 to see the
database window will let you view your Queries, in the Query Builder which
has an option to display the SQL.

If you cannot, then it is possibly a problem that you have Access security
applied and do not have the appropriate permissions. There are so many
third-party security cracks for Access databases that breaking security
should not be insurmountable. Although it may cost you, most of the
"password recovery" packages I have heard about cost US$150 or less.

Unlike C and other "programming languages", Access does not have a way to
compile to executable. And since the only "compilation" (usually called
"preparation") of Queries would be by the database engine, those are not
affected by "compiling" the Access application to MDE.

Larry Linson
Microsoft Access MVP

Nov 13 '05 #2

P: n/a
Hi Larry,

Thanks for the reply. I'm sorry, I guess I wasn't too specific in
outlining my problem. Let me clarify...

The App is a compiled VB6 program that makes use of an Access 2000
Database. All the queries are generated on-the-fly by this program...ie
they are not stored in the database.

I have the .exe file and the .mdb file. What I don't have is the source
code I used to generate the .exe (result of HD crash).

So, I have the app that works fine, but now I need to make
modifications to it.
When I wrote the app I remember that I used some pretty wicked SQL
statements to get the results I needed. It took a long time to get them
working right. I'm not looking forward to going through that drama
again.

This is why I was wanting to know if I could set the database to log
any queries (especially "read"), or if there was an app I could run
that could moniitor a specified DB, then I could run my app and
hey-presto, I'd have my SQL queries back.

I hope this helps.

Regards,

Mary.


Larry Linson wrote:
<ma************@hotmail.com> wrote
> I have an app (lost the source code) that
> performs many different queries in order
> to achieve the results I'm looking for. Re-
> developing the app isn't really a big issue...
> but what would be is trying to figure out
> how I did the original database queries
> (SQL Syntax I used)
In what form is the Access application you have?

You can see the Queries in either an .MDB or an .MDE (the "compiled"

MDE simply tokenizes VBA code and locks design view on Access objects which can have a code module). It may be that simply holding down the Shift key as you start the application, or once it is executing, pressing F11 to see the database window will let you view your Queries, in the Query Builder which has an option to display the SQL.

If you cannot, then it is possibly a problem that you have Access security applied and do not have the appropriate permissions. There are so many third-party security cracks for Access databases that breaking security should not be insurmountable. Although it may cost you, most of the
"password recovery" packages I have heard about cost US$150 or less.

Unlike C and other "programming languages", Access does not have a way to compile to executable. And since the only "compilation" (usually called "preparation") of Queries would be by the database engine, those are not affected by "compiling" the Access application to MDE.

Larry Linson
Microsoft Access MVP


Nov 13 '05 #3

P: n/a
I worked on some Access client to server DB projects with a DBA who had a
package that recorded the SQL that was transmitted from the ODBC drivers to
the server DB. I don't know that I ever knew the name of the package he
used.

I am not aware of a similar product for catching and recording what is sent
between VB and the Jet database engine -- but that does not mean there isn't
one.

Larry Linson
Microsoft Access MVP
<ma************@hotmail.com> wrote in message
news:11**********************@z14g2000cwz.googlegr oups.com...
Hi Larry,

Thanks for the reply. I'm sorry, I guess I wasn't too specific in
outlining my problem. Let me clarify...

The App is a compiled VB6 program that makes use of an Access 2000
Database. All the queries are generated on-the-fly by this program...ie
they are not stored in the database.

I have the .exe file and the .mdb file. What I don't have is the source
code I used to generate the .exe (result of HD crash).

So, I have the app that works fine, but now I need to make
modifications to it.
When I wrote the app I remember that I used some pretty wicked SQL
statements to get the results I needed. It took a long time to get them
working right. I'm not looking forward to going through that drama
again.

This is why I was wanting to know if I could set the database to log
any queries (especially "read"), or if there was an app I could run
that could moniitor a specified DB, then I could run my app and
hey-presto, I'd have my SQL queries back.

I hope this helps.

Regards,

Mary.


Larry Linson wrote:
<ma************@hotmail.com> wrote
> I have an app (lost the source code) that
> performs many different queries in order
> to achieve the results I'm looking for. Re-
> developing the app isn't really a big issue...
> but what would be is trying to figure out
> how I did the original database queries
> (SQL Syntax I used)


In what form is the Access application you have?

You can see the Queries in either an .MDB or an .MDE (the "compiled"

MDE
simply tokenizes VBA code and locks design view on Access objects

which can
have a code module). It may be that simply holding down the Shift key

as you
start the application, or once it is executing, pressing F11 to see

the
database window will let you view your Queries, in the Query Builder

which
has an option to display the SQL.

If you cannot, then it is possibly a problem that you have Access

security
applied and do not have the appropriate permissions. There are so

many
third-party security cracks for Access databases that breaking

security
should not be insurmountable. Although it may cost you, most of the
"password recovery" packages I have heard about cost US$150 or less.

Unlike C and other "programming languages", Access does not have a

way to
compile to executable. And since the only "compilation" (usually

called
"preparation") of Queries would be by the database engine, those are

not
affected by "compiling" the Access application to MDE.

Larry Linson
Microsoft Access MVP

Nov 13 '05 #4

P: n/a
Larry Linson wrote:
I worked on some Access client to server DB projects with a DBA who had a
package that recorded the SQL that was transmitted from the ODBC drivers to
the server DB. I don't know that I ever knew the name of the package he
used.

I am not aware of a similar product for catching and recording what is sent
between VB and the Jet database engine -- but that does not mean there isn't
one.

Larry Linson
Microsoft Access MVP


I believe you can turn on the Trace facility in ODBC (most likely
through the Control Panel applet, Administrative tools, Data Sources,
Tracing tab in XP) and that log may have the SQL statement in it.

Beware that the log grows very big very fast on an active db.
--
'---------------
'John Mishefske
'---------------
Nov 13 '05 #5

P: n/a
Thanks Larry and John...

The app does not use an ODBC connection to access the database, so I
can't use the tracing facility.

However, I had a thought that if it did use an odbc connection, then
perhaps this tracing facility is just what I need.

So, with that in mind, I tried placing the tables in another mdb
database and linking the tables into the db the app uses via an odbc
connection. I soon discovered the linking facility in Access does not
let you link to another mdb database through odbc (which I thought was
odd).

Not to be put off, I moved the tables to an informix database and
linked the mdb database the app uses to point to these tables. This
worked ok and the app runs fine, but when I turn on the tracing for
odbc connections, nothing gets populated in the log file.

I can't figure out why it's empty. Either I've done something wrong
(most likely) or perhaps it's because I'm not accessing the database
directly through odbc so nothing is written to the log.

I guess I'm back to square one and have to try re-building the queries
from scratch...groan...

Thanks for your feed back though, I appreciate it.

Mary.

Nov 13 '05 #6

P: n/a
Mary,

I specialize in adding more functionality to existing applications,
modifying existing applications and fixing problems in existing
applications. I am very good at this and could rebuild your queries from
scratch for you. If you are interested in having me help you, contact me at
my email address below.

--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications
re******@pcdatasheet.com
www.pcdatasheet.com

<ma************@hotmail.com> wrote in message
news:11*********************@z14g2000cwz.googlegro ups.com...
Hi,

I have an app (lost the source code) that performs many different
queries in order to achieve the results I'm looking for. Re-developing
the app isn't really a big issue...but what would be is trying to
figure out how I did the original database queries (SQL Syntax I used)

I was wondering if there was a way in Access to log all queries made to
a database...or alternatively, was there any app that you guys new of
that can monitor an access database and somehow view any queries made
to it?

By queries, I mean Inserts, Updates, Deletes AND Read
queries...especially READ queries.

Thanks for your time.

Mary.

Nov 13 '05 #7

P: n/a

"PC Datasheet" <no****@nospam.spam> schreef in bericht
news:HO*****************@newsread3.news.atl.earthl ink.net...
Mary,

I specialize in adding more functionality to existing applications,
modifying existing applications and fixing problems in existing
applications. I am very good at this and could rebuild your queries from
scratch for you. If you are interested in having me help you, contact me at
my email address below.


You seem to just specialize in advertising and job-hunting in the groups here.
Check out:
http://www.google.com/groups?as_q=co...ng=d&lr=&hl=nl

Arno R

Nov 13 '05 #8

P: n/a
You're a jerk!!

I don't see you making a helpful suggestion to Mary. In fact, I don't recall
ever seeing a helpful suggestion to any poster from you. Why don't you go
fill up a large stein of your lousy lager, go out by the Danube and see how
fast you can gulp it down! Then go up to Berlin and see how long it takes
you to rebuild the wall one stone at a time.
"Arno R" <ar****************@tiscali.nl> wrote in message
news:42**********************@dreader2.news.tiscal i.nl...

"PC Datasheet" <no****@nospam.spam> schreef in bericht
news:HO*****************@newsread3.news.atl.earthl ink.net...
Mary,

I specialize in adding more functionality to existing applications,
modifying existing applications and fixing problems in existing
applications. I am very good at this and could rebuild your queries from
scratch for you. If you are interested in having me help you, contact me at my email address below.
You seem to just specialize in advertising and job-hunting in the groups

here. Check out:
http://www.google.com/groups?as_q=co...dress%20&as_ua
uthors=PC%20Datasheet%20&as_scoring=d&lr=&hl=nl
Arno R

Nov 13 '05 #9

P: n/a

"PC Datasheet" <no****@nospam.spam> schreef in bericht
news:za*****************@newsread3.news.atl.earthl ink.net...
You're a jerk!!
<other rather stupid and offensive lines to German people ? here >


Getting offensive again Steve?

-- You abuse this group and other groups for advertising and job-hunting over and over again:
http://www.google.com/groups?as_q=co...ng=d&lr=&hl=nl

-- You hide your identity while asking questions:
http://groups.google.com/groups?hl=n...eken%26meta%3D

As this 'Heather' you asked many questions. Even more as 'Kristine':
http://groups.google.com/groups?q=ks...sa=G&scoring=d

You are pathetic !
Need more examples ?
Arno R
Nov 13 '05 #10

P: n/a
PC Datasheet wrote:
You're a jerk!!

I don't see you making a helpful suggestion to Mary. In fact, I don't recall
ever seeing a helpful suggestion to any poster from you.


And you are, demonstrably, by what I've snipped from your post, a bigot.

Based on your previous disgraceful behaviour, I'm guessing "MAry JOnes"
is another one of your fradulent personae.
--
Tim http://www.ucs.mun.ca/~tmarshal/
^o<
/#) "Burp-beep, burp-beep, burp-beep?" - Quaker Jake
/^^ "Whatcha doin?" - Ditto "TIM-MAY!!" - Me
Nov 13 '05 #11

P: n/a
hmmm...I didn't expect my post for assistance to generate such a
commotion.

For the record, I can assure you that I am not an alias of "PC
Datasheet" nor have I ever heard of this person until now. My post was
an honest request for assistance from the people that frequent this
newsgroup.

Mary.

Nov 13 '05 #12

This discussion thread is closed

Replies have been disabled for this discussion.