473,405 Members | 2,154 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

Synchronizing two forms?

Hello all,

I have two forms, which are already synchronized, however, everytime I page to the next set of data both queries run again. This slows down my database to a point of unreponsiveness. Is there a way to speed up these forms from running over and over?
Mar 24 '08 #1
12 1811
FishVal
2,653 Expert 2GB
Hello all,

I have two forms, which are already synchronized, however, everytime I page to the next set of data both queries run again. This slows down my database to a point of unreponsiveness. Is there a way to speed up these forms from running over and over?
Hi, eskelies.

You definitely should provide some more information.
  • What does "synchronized" means?
  • What queries run?
  • Any additional information you consider to help others to understand your situation.

Regards,
Fish
Mar 24 '08 #2
Fish,

Sorry...Let me try and explain better. I have two queries below, which I know are large:

I am doing analysis on the data that is represented in the two queries. I do not use all of the data when I build forms around them, instead I use certain fields which populate within the appropriate form. For instance, I use Account Number, prior contribution yield, est contribution yield, etc. in query 1. The same thing goes for query 2, however, my goal is to synchronize form 1 (ie. query 1) with Form 2 (query 2), so that when I select a certain account number the information in form 1 and form 2 shows up under account number in the "new" form. I started doing this by taking an unbound form (ie. Form 3) and bringing in Form 1. Then from there I linked form 1's account number with form 2's account number. In this instance it works, however, everytime I try to bring up a new account number it seems as if Access is requesting query 1 and query 2 to run again. I was hoping there is a way to get this to run smoother and faster.

I hope there is enough information here to help me. Thank you.

QUERY 1:
Expand|Select|Wrap|Line Numbers
  1. SELECT [Current Accrual Yield Summary].[Account Number ], [Current Accrual Yield Summary].[Account Description ], [Prior Accrual Yield Summary].[SumOfContribution (Accr) Yield (Prior)], [Accrual Yield Impact of Lost Positions (Summary)].[SumOfYield Impact of Change in EI & EA on Lost Positions], [Accrual Yield Impact of New Positions (Summary)].[SumOfYield Impact of Change in EI & EA on New Positions], [AYCC No Position Changes With RC (Summary)].[AYCC NO Pos With RC], [AYCC No Position Change and No RC (Summary)].[AYCC No Pos & No RC], [AYCC With Position Changes & W/O RC (Summary)].[AYCC With Position Changes & W/O RC], [AYCC With Position Changes and With RC (Summary)].[AYCC With Pos Changes and With RC], [Accrual Yield Impact of Existing Swap Positions (Summary)].[SumOfYield Impact of Change in EI & EA] AS SWAPs, [Accrual Yield Impact of Pref Divs on Existing Pos (Summary)].[SumOfYield Impact of Change in EI & EA] AS [Preferred Dividends], [Accrual Yield Capstock Impact].[Yield Impact of Capstock], [Current Accrual Yield Summary].[SumOfCurrent Contribution (Accr) Yield]-[Est Current Day Accrual Yield] AS [Unexplained Difference], [Current Accrual Yield Summary].[SumOfCurrent Contribution (Accr) Yield], NZ([Prior accrual Yield Summary].[SumOfContribution (Accr) Yield (Prior)])+NZ([SumOfYield Impact of Change in EI & EA on Lost Positions])+NZ([SumOfYield Impact of Change in EI & EA on New Positions])+NZ([AYCC NO Pos With RC])+NZ([AYCC No Pos & No RC])+NZ([AYCC With Position Changes & W/O RC])+NZ([AYCC With Pos Changes and With RC])+NZ([SWAPs])+NZ([Preferred Dividends])+NZ([Yield Impact of Capstock]) AS [Est Current Day Accrual Yield]
  2. FROM ((((((((([Current Accrual Yield Summary] LEFT JOIN [Prior Accrual Yield Summary] ON [Current Accrual Yield Summary].[Account Number ] = [Prior Accrual Yield Summary].[Account Number ]) LEFT JOIN [Accrual Yield Impact of Lost Positions (Summary)] ON [Current Accrual Yield Summary].[Account Number ] = [Accrual Yield Impact of Lost Positions (Summary)].[Account Number ]) LEFT JOIN [Accrual Yield Impact of New Positions (Summary)] ON [Current Accrual Yield Summary].[Account Number ] = [Accrual Yield Impact of New Positions (Summary)].[Account Number ]) LEFT JOIN [AYCC No Position Changes With RC (Summary)] ON [Current Accrual Yield Summary].[Account Number ] = [AYCC No Position Changes With RC (Summary)].[Account Number ]) LEFT JOIN [AYCC With Position Changes & W/O RC (Summary)] ON [Current Accrual Yield Summary].[Account Number ] = [AYCC With Position Changes & W/O RC (Summary)].[Account Number ]) LEFT JOIN [AYCC No Position Change and No RC (Summary)] ON [Current Accrual Yield Summary].[Account Number ] = [AYCC No Position Change and No RC (Summary)].[Account Number ]) LEFT JOIN [AYCC With Position Changes and With RC (Summary)] ON [Current Accrual Yield Summary].[Account Number ] = [AYCC With Position Changes and With RC (Summary)].[Account Number ]) LEFT JOIN [Accrual Yield Capstock Impact] ON [Current Accrual Yield Summary].[Account Number ] = [Accrual Yield Capstock Impact].[Account Number ]) LEFT JOIN [Accrual Yield Impact of Existing Swap Positions (Summary)] ON [Current Accrual Yield Summary].[Account Number ] = [Accrual Yield Impact of Existing Swap Positions (Summary)].[Account Number ]) LEFT JOIN [Accrual Yield Impact of Pref Divs on Existing Pos (Summary)] ON [Current Accrual Yield Summary].[Account Number ] = [Accrual Yield Impact of Pref Divs on Existing Pos (Summary)].[Account Number ]
  3. WHERE ((([Current Accrual Yield Summary].[Account Number ])<>9817 And ([Current Accrual Yield Summary].[Account Number ])<>9818 And ([Current Accrual Yield Summary].[Account Number ])<>9819));
QUERY 2:
Expand|Select|Wrap|Line Numbers
  1. SELECT [Prior Day Fund Data].[Account Number ], [Prior Day Fund Data].[Account Description ], [Prior Day Fund Data].[Account Class ], [Prior Day Fund Data].[Prior 5-Place NAV], [Earned Income and Amort NAV Impact Summary].[SumOfEarned Income NAV Impact ($)] AS [Earned Income], [Earned Income and Amort NAV Impact Summary].[SumOfEarned Amort NAV Impact ($)] AS [Earned Amort], [Expense NAV Impacts].[Expense NAV Impact ($)] AS Expense, [Income Distribution NAV Impact Summary].[SumOfIncome Distribution NAV Impact ($)] AS [Income Distribution], [Non-Futures Transaction NAV Impact Summary].[SumOfNet Gain/Loss NAV Impact ($)] AS [Net Gain/Loss (NF)], [Futures Transaction NAV Impact Summary].[SumOfNet Gain/Loss NAV Impact ($)] AS [Net Gain/Loss (F)], [Preferred Transactions NAV Impact Summary].[SumOfNet Gain/Loss NAV Impact ($)] AS [Preferred Transactions], [Distributed Gain Loss NAV Impact Summary].[SumOfDistributed Gain Loss NAV Impact ($)] AS [Distributed Gain Loss], [Capstock NAV Impact Summary].[SumOfCapstock NAV Impact ($)] AS Capstock, FValNAVImpactSum.[SumOfFair Value NAV Impact ($)] AS [Fair Value], [Prior 5-Place NAV]+NZ([SumOfEarned Income NAV Impact ($)])+NZ([SumOfEarned Amort NAV Impact ($)])+NZ([Expense NAV Impact ($)])+NZ([SumOfIncome Distribution NAV Impact ($)])+NZ([Non-Futures Transaction NAV Impact Summary].[SumOfnet Gain/Loss NAV Impact ($)])+NZ([Futures Transaction NAV Impact Summary].[SumOfnet Gain/Loss NAV Impact ($)])+NZ([SumOfDistributed Gain Loss NAV Impact ($)])+NZ([SumOfCapstock NAV Impact ($)])+NZ([Preferred Transactions NAV Impact Summary].[SumOfNet Gain/Loss NAV Impact ($)])+nz([sumoffair value nav impact ($)]) AS [Pre Pricing NAV Impact], [Non-Futures Security Price NAV Impact Summary].[SumOfNon-Futures Security Price NAV Impact($)] AS [Non-Futures Security Price (NF)], [Futures Security Price NAV Impact Summary].[SumOfFutures Security Price NAV Impact($)] AS [Futures Security Price (F)], [Amort/Accret adj to NAV].[Amort/Accret NAV Impact Adjustment ($)] AS [Amort/Accret Adjustment], [Preferred Security Price NAV Impact Summary].[SumOfPreferred Security Price NAV Impact($)] AS [Preferred Security Price], [Swap Mark to Market Transaction NAV Impact Summary].[SumOfSwap NAV Impact by Class ($)] AS [Swap by Class], [Pre Pricing NAV Impact]+NZ([SumOfNon-Futures Security Price NAV Impact($)])+NZ([SumOfFutures Security Price NAV Impact($)])+NZ([Amort/Accret NAV Impact Adjustment ($)])+NZ([SumOfPreferred Security Price NAV Impact($)])+NZ([SumOfSwap NAV Impact by Class ($)]) AS [Final Pricing NAV Impact], [Amort/Accret adj to NAV].[Current 5 Place NAV], [Final Pricing NAV Impact]-[Amort/Accret adj to NAV].[Current 5 Place NAV] AS [Unexplained Variance], [Prior Day Fund Data].Benchmark, [Prior Day Fund Data].[Investment Desk], [Prior Day Fund Data].Objective
  2. FROM ((((FundClassList INNER JOIN (((((((((([Prior Day Fund Data] LEFT JOIN [Expense NAV Impacts] ON ([Prior Day Fund Data].[Account Class ] = [Expense NAV Impacts].[Account Class ]) AND ([Prior Day Fund Data].[Account Number ] = [Expense NAV Impacts].[Account Number ])) LEFT JOIN [Income Distribution NAV Impact Summary] ON ([Prior Day Fund Data].[Account Class ] = [Income Distribution NAV Impact Summary].[Account Class ]) AND ([Prior Day Fund Data].[Account Number ] = [Income Distribution NAV Impact Summary].[Account Number ])) LEFT JOIN [Swap Mark to Market Transaction NAV Impact Summary] ON ([Prior Day Fund Data].[Account Class ] = [Swap Mark to Market Transaction NAV Impact Summary].[Account Class ]) AND ([Prior Day Fund Data].[Account Number ] = [Swap Mark to Market Transaction NAV Impact Summary].[Account Number ])) LEFT JOIN [Earned Income and Amort NAV Impact Summary] ON ([Prior Day Fund Data].[Account Class ] = [Earned Income and Amort NAV Impact Summary].[Account Class ]) AND ([Prior Day Fund Data].[Account Number ] = [Earned Income and Amort NAV Impact Summary].[Account Number ])) LEFT JOIN [Distributed Gain Loss NAV Impact Summary] ON ([Prior Day Fund Data].[Account Class ] = [Distributed Gain Loss NAV Impact Summary].[Account Class ]) AND ([Prior Day Fund Data].[Account Number ] = [Distributed Gain Loss NAV Impact Summary].[Account Number ])) LEFT JOIN [Futures Transaction NAV Impact Summary] ON ([Prior Day Fund Data].[Account Class ] = [Futures Transaction NAV Impact Summary].[Account Class ]) AND ([Prior Day Fund Data].[Account Number ] = [Futures Transaction NAV Impact Summary].[Account Number ])) LEFT JOIN [Futures Security Price NAV Impact Summary] ON ([Prior Day Fund Data].[Account Class ] = [Futures Security Price NAV Impact Summary].[Account Class ]) AND ([Prior Day Fund Data].[Account Number ] = [Futures Security Price NAV Impact Summary].[Account Number ])) LEFT JOIN [Non-Futures Transaction NAV Impact Summary] ON ([Prior Day Fund Data].[Account Class ] = [Non-Futures Transaction NAV Impact Summary].[Account Class ]) AND ([Prior Day Fund Data].[Account Number ] = [Non-Futures Transaction NAV Impact Summary].[Account Number ])) LEFT JOIN [Non-Futures Security Price NAV Impact Summary] ON ([Prior Day Fund Data].[Account Class ] = [Non-Futures Security Price NAV Impact Summary].[Account Class ]) AND ([Prior Day Fund Data].[Account Number ] = [Non-Futures Security Price NAV Impact Summary].[Account Number ])) LEFT JOIN [Preferred Security Price NAV Impact Summary] ON ([Prior Day Fund Data].[Account Class ] = [Preferred Security Price NAV Impact Summary].[Account Class ]) AND ([Prior Day Fund Data].[Account Number ] = [Preferred Security Price NAV Impact Summary].[Account Number ])) ON (FundClassList.NewClass = [Prior Day Fund Data].[Account Class ]) AND (FundClassList.[Account Number ] = [Prior Day Fund Data].[Account Number ])) LEFT JOIN [Preferred Transactions NAV Impact Summary] ON ([Prior Day Fund Data].[Account Number ] = [Preferred Transactions NAV Impact Summary].[Account Number ]) AND ([Prior Day Fund Data].[Account Class ] = [Preferred Transactions NAV Impact Summary].[Account Class ])) LEFT JOIN [Capstock NAV Impact Summary] ON ([Prior Day Fund Data].[Account Class ] = [Capstock NAV Impact Summary].[Account Class ]) AND ([Prior Day Fund Data].[Account Number ] = [Capstock NAV Impact Summary].[Account Number ])) LEFT JOIN [Amort/Accret adj to NAV] ON ([Prior Day Fund Data].[Account Class ] = [Amort/Accret adj to NAV].[Account Class ]) AND ([Prior Day Fund Data].[Account Number ] = [Amort/Accret adj to NAV].[Account Number ])) LEFT JOIN FValNAVImpactSum ON (FundClassList.[Account Number ] = FValNAVImpactSum.[Fund Number]) AND (FundClassList.NewClass = FValNAVImpactSum.[Account Class ])
  3. WHERE ((([Prior Day Fund Data].[Account Number ])<>9817 And ([Prior Day Fund Data].[Account Number ])<>9818 And ([Prior Day Fund Data].[Account Number ])<>9819 And ([Prior Day Fund Data].[Account Number ])<>9898));
Mar 24 '08 #3
FishVal
2,653 Expert 2GB
Ok.

Quite impressive.
Could you post more details of how do you populate Form3.
Is it bound to any of the recordsets (or to both of them)?
What does it mean "bringing in Form 1"?
Is Form3 expected to be read-only?
If any code is used, then please post it.

Regards,
Fish.

P.S. You may also find interesting the article about How to Optimize Queries and Recordsets
Mar 24 '08 #4
Form 3 can be either bound or unbounded. In this case, I have it being unbound.

I have some code in form 2, which is:
Expand|Select|Wrap|Line Numbers
  1. Private Sub Form_Current()
  2. If Not Me.NewRecord Then
  3.     RequeryAccount Number
  4. End If
  5. End Sub
The subform control (form 2) has link master fields which is below. This protects my database from manual updated records.

My source Object is: query 2

Link child Fields: Account Number

Link master fields: txtaccount number

Form 2 and Form 1 are both bound to query 1 and query 2.

I would expect form 3 to be read-only with form 1 and 2's data changing together.

The issue I am having reminds me of dynamically synchronizing combo boxes. The difference being they are specific forms working together and populating different data based on account numbers.

Hope this helps!!
Mar 24 '08 #5
FishVal
2,653 Expert 2GB
Hi, eskelies.

I would like to clarify that the very nature of your question requires a complete understanding of the forms interactions. So far I couldn't give you a helpful advice just because I still have a little idea about what is going in your db.

Form 3 can be either bound or unbounded. In this case, I have it being unbound.

I have some code in form 2, which is:

Private Sub Form_Current()
If Not Me.NewRecord Then
RequeryAccount Number
End If
End Sub
Sorry, but the code makes so little sense .... )) Doesn't it?

The subform control (form 2) has link master fields which is below. This protects my database from manual updated records.

My source Object is: query 2

Link child Fields: Account Number

Link master fields: txtaccount number

Form 2 and Form 1 are both bound to query 1 and query 2.
Could you give a complete description of the forms interactions. If they are bound via form/subform relationships, then please specify form hierarchy. If they interacts via code, then please post it.

I would expect form 3 to be read-only with form 1 and 2's data changing together.

The issue I am having reminds me of dynamically synchronizing combo boxes. The difference being they are specific forms working together and populating different data based on account numbers.

Hope this helps!!
You may attach sanitized copy of your db.

Regards,

Fish
Mar 25 '08 #6
Fish,

Sorry if my information is unclear. I thank you for taking the time to help me even though I am a pain in the butt. :)

Does a moderator have to give me the ability to attach files?


Hi, eskelies.

I would like to clarify that the very nature of your question requires a complete understanding of the forms interactions. So far I couldn't give you a helpful advice just because I still have a little idea about what is going in your db.



Sorry, but the code makes so little sense .... )) Doesn't it?


Could you give a complete description of the forms interactions. If they are bound via form/subform relationships, then please specify form hierarchy. If they interacts via code, then please post it.



You may attach sanitized copy of your db.

Regards,

Fish
Mar 25 '08 #7
FishVal
2,653 Expert 2GB
Fish,

Sorry if my information is unclear. I thank you for taking the time to help me even though I am a pain in the butt. :)
Hi, eskelies.

Don't worry, that is not a problem.

Does a moderator have to give me the ability to attach files?
No special permission is required to attach file.
  • Sanitize your db: remove all sensitive information and leave dummy records in relevant tables, remove unnecessary objects
  • Compact/repair
  • Pack to zip or rar
  • Having made a post, click on [Edit/Delete] button, then click on [Manage Attachments], upload your file and save the changes to the post

Regards,
Fish
Mar 25 '08 #8
trying to upload database file....
Attached Files
File Type: zip Sanitize DB.zip (262.3 KB, 68 views)
Mar 25 '08 #9
Fish,

what I want to happen is take query Accrual yield Impact Final and query NAV impact summary (r086) and synchronize them. When I say synchronize them I mean the following:
I would like the user to beable to go into frmselectfund. Once they select their fund they will then beable to run a button macro (which i have not built) that will pull up another form. Let's call it test. This form needs to have both queries built into the form. When you click forward both queries will change.

trying to upload database file....
Mar 25 '08 #10
NeoPa
32,556 Expert Mod 16PB
Please use the [ CODE ] tags in all your future posts (See How to Ask a Question). As a full member now, you need to be a bit more aware of the rules.

ADMIN.

PS. Also subscribing to the thread.

PPS. Don't feel you need to include the previous post in your reply. Unless there's anything particular you need to refer to explicitly, this text can be junked.
Mar 26 '08 #11
FishVal
2,653 Expert 2GB
Hi, eskelies.

Sorry for delay.
I looked at your db hoping I could help you optimize queries.
But ... :) ... queries based on several tenths another queries is somewhat I could not sort quickly and easily. So I will left them as they are so far.
Lets return to the form.
As far as I understand you just need a form with 2 subforms that will be affected by a single navigation bar.

That is quite simple. I would attach a sample db where [frmMain] has [frm1] and [frm2] subforms and navigation bar of [frmMain] points both subforms to a record with a same PK value.
Additions in forms are disabled because it will require additional coding. Not complicated, but I guess just for starters this enough.

The code (in [frmMain] module):

Expand|Select|Wrap|Line Numbers
  1. Private Sub Form_Current()
  2.     Me.frm2.Form.Recordset.FindFirst "keyID=" & Me.frm1.Form.keyID
  3. End Sub
  4.  
  5. Private Sub Form_Open(Cancel As Integer)
  6.     Set Me.Recordset = Me.frm1.Form.Recordset
  7. End Sub
  8.  
Does this look like what you are expecting for?

Regards,
Fish
Attached Files
File Type: zip SyncSbf.zip (15.8 KB, 61 views)
Mar 26 '08 #12
That is exactly what I am looking for. I actually did it another way. I don't know what is easier, so I will compare them both. I just made a make table of all the queries I used and linked master/child fields.

I apprecaite all your help.
Mar 27 '08 #13

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Keith Veleba | last post by:
Hello to all fellow c.l.p'ers! Long-time listener, first-time caller. Background: I'm working on a project where I have to do some serious multithreading. I've worked up a decorator in Python...
2
by: Tom | last post by:
The purpose of my form is to record multiple owners of businesses. The main form displays the business records. Subform1 is a continuous form consisting of only a combobox to select owners from a...
1
by: Jeff Smith | last post by:
Hi This is a repost due to no responses Here's a problem I've encountered with Access 2003 which has got me to redesign how I get the row source in a second combo box using the first combo...
0
by: John Phelan-Cummings | last post by:
What Works I have a subform (Events1) with a combo box field called “eventname”. The combo box displays the correct information from the second column of its lookup table, i.e., column #1:...
3
by: Shaldaman | last post by:
I have 2 forms that I'm trying to synchronize. I have an Access form called "Login". "Command10" is a button on the form and "Text5" is a text field on it. When a user enters a numeric value...
0
by: Bamse | last post by:
Hi, I want to synchronize (the Master-Details concept) 2 grids in 2 different forms by using BindingContext. is this possible?
2
by: Christopher D. Wiederspan | last post by:
We are getting ready to move an ASP.NET application off of a single development machine and onto a "webfarm". Basically our webfarm is a bunch of identical servers with the load-balancing provided...
4
by: Chris Ochs | last post by:
We have a number of tables in a CRM that is written in MS access that I need to be able to provide a web interface to. I can export the tables just fine using pgadmin II, but I cant' think of a...
4
by: MaxMax | last post by:
I'm using HttpWebRequest. It seems that all the callback called from HttpWebRequest are in another thread (not in the "original" thread). Now my problem is that the "original" thread is the thread...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.