четверг, октября 05, 2006

Microsoft Access. Что делать когда запросы не выполняются подряд

Начну с примечания, считаю, что Access - это наиболее удобное средство для разработки небольших и средних баз данных. Однако, и тут бывают свои подводные камни.

Представьте себе, что у вас есть задача, в ходе которой вам нужно создавать временные таблицы и тут же обновлять в них данные. Для этого вы можете создать ряд запросов

  1. SELECT ... INTO tabletmp1
  2. UPDATE tabletmp1 SET ...
    WHERE ... IN (SELECT ... FROM tabletmp1)

Запросы могут запускаться стандартными средствами VBA например после события нажатия кнопки на форме. В обработчике пишем следующее:

DoCmd.OpenQuery "Zapros1", acViewNormal, acEdit
DoCmd.OpenQuery "Zapros2", acViewNormal, acEdit

Пусть у вас таких запросов с-десяток, и они выполняются в цикле (этого может требовать исходная задача, когда вам нужно каким-то определенным образом обновить пакет данных, а потом сохранить изменения).

Что при этом может произойти. Запрос2 начнет выполняться, не дожидаясь полного завершения запроса1. А данные естественно, которые должен обновлять запрос2, еще не внесены (временная таблица может уже существовать в базе данных). Понять такую заморочку мне удалось не сразу. Было странно, что часть данных в результате выполнения макроса куда-то исчезала. Запустив отладчик, я был удивлен еще больше, когда все, что мне было нужно, выполнилось правильно в пошаговом режиме. Продолжая экспериментировать, мне в голову пришла та мысль, которую я озвучил выше, и я попытался ее проверить. Поставив временные задержки между выполнениями запросов, мне удалось избежать потери данных, однако суммарное время таких задержек превышало 15 минут.

Тогда я попытался обратиться к MSDN. Мне удалось найти команду более низкого уровня для выполнения запросов

CurrentDb.Execute "Zapros1"

Однако эта команда не поддерживает запросы на DELETE и SELECT ... INTO table, если такая таблица уже существует. Тогда я попытался написать так

DoCmd.DeleteObject acTable, "tabletmp1"
CurrentDb.Execute "Zapros1

Как вы думаете помогло? Правильно, нет. На этот раз у меня просто выскочила ошибка во время выполнения команды CurrentDB.Execute, что таблица в которую я хочу поместить данные этим запросом, существует. Но как, если я ее удаляю? Запустив отладчик, я был снова, но уже не так удивлен. На этот раз проблема выполнения одной команды, когда еще не завершилась другая, возникла между DoCmd.DeleteObject и CurrentDb.Execute.

Понять, как именно происходит распараллеливание задач Access'ом, мне так и не удалось. А вопрос, как его отключить, по-прежнему остается открытым.

15 комментариев:

Анонимный комментирует...

[url=http://sayts.ru/]Sayts.ru[/url] - система автоматизированого создания вебсайтов любой сложности.
Сервис запущен для того, чтоб вы могли в автоматическом режиме создавать себе сайты нескольких видов: варезники, фотогалереи, магазины, форумы.

Что мы предлагаем:
- Автоматизированое создание Варезников.
- Автоматизированое создание Фотогалерей.
- Автоматическое создание Магазинов.
- Автоматическое создание Форумов.

Сайт в 1000стр. обойдется в 5$.

[url=http://sayts.ru/]http://sayts.ru/[/url]

Анонимный комментирует...

Хочу предложить лучшую сборку партнерок для получения прибыли на своем сайте
ссылки и описание по адресу [url=http://letitlinks.net/zarabotok.html]Letitlinks.net[/url]

Анонимный комментирует...

[url=http://seo-progon.info/]Seo-Progon.Info[/url] - проект быстрого рассылки в форумы, блоги, гостевые, соц. закладки, каталоги статей, каталоги сайтов. Система содержит в себе ряд уникальных возможностей: простота и функциональность, низкая цена, отличная эффективность регистрации и постоянно обновляемые базы.
Что мы даем:
- Постинг по русскоязычных форумах.
- Постинг на англоязычных форумах.
- Постинг в профилям русскоязычных и англоязычных форумов.
- Постинг на блогах.
- Постинг в гостевым книгам.
- Постинг в WIKI.
- Регистрация по каталагах сайтов.
- Регистрация в каталогах статей.
Основные функции системы:
1. Автоматическая служба рассылки.
2. Удобный и простой генератор описаний.
3. Регулярно обновляемые базы.
Дополнительные возможности сервиса:
1. Быстрое сабмит в поисковики.
2. Автоматизированный прием платежей.
3. Отчеты о выполненном постинге.
4. Выгодная партнерская программа .


[url=http://seo-progon.info/]Seo-Progon.Info[/url]

Анонимный комментирует...

Nowadays in this fiscal circumstance, typically the pay day loans are usually becoming more and more preferred. This also is mainly since these particular [url=http://cashloans-247.co.uk]joint poor credit loans[/url] mortgages guide visitors to cover unanticipated fiscal emergencies. Once you also have to deal with bucks situations, it is very important to help ponder whether any such personal loan signifies the best option for you [url=http://instantcashloans4u.co.uk]coop loans[/url] or even in no way. That allows you to consider the best final choice, you will need to discover a number of significant data that usually understand that pay day loans on the internet.

Any payday cash advances within an hour generally give you a small degree, which will does not [url=http://quickcash77.co.uk]you could try these out[/url] transcend £1, 500. Thus, if you would like over £1, 500, you must without a doubt think of a different financial loan substitute. And also, what you can do is to have this personal loan and also get cash on the cost as a result of kinfolk as well as friends. Yet another important matter is the possibility that typically the cash advances are generally financed in a distinct phase, of which concludes the moment you will definitely get your next paycheck.

Moreover, it is extremely imperative to realise that if you can't have a dependable project, you cannot acquire from any of the cash advance other options. The biology behind it is due to the fact you don't recent an assurance, that so should really be a limited income. Hence, so, the provider isn't going to take on the application notably considering that he / she is not to be for sure that you'll be able to pay off typically the mortgage. Nonetheless, when you've got a comfortable occupation along with the lender approves you will job application, it's possible to have [url=http://myfastloans.co.uk]loans for unemployed students[/url] the cash relocated into your profile on regarding 1 hour.

Some other matters that you should take under consideration is the rates of interest and additional rates, your current credit profile along with the terms with the home loan. Through thinking about each one of [url=http://instantcashloans4u.co.uk]instant loans of L100[/url] elements, you’re able to consider if the accessible cash advances online can be suited to anyone or possibly in no way.

Анонимный комментирует...

You will find precisely why Document guide with co-signing to get mortgages. This can be a catastrophe waiting around to take place. And those [url=http://pozyczkibezbik24.net.pl]cały dokument[/url] payday advance support providers will possibly not deliver just what exactly these people assure.
A new payday loan is really a short-term home loan through superior costs more and more consumers obtain simply because they believe that it is a great choice [url=http://pozyczkibezbik24.biz.pl]kredyty gotówkowe przez internet bez bik[/url] for an rapid difficulty. The particular mortgage loan could possibly hide or simply delay your mood associated with reckoning, although it's all the most severe feasible remedy. Nearly all fiscal loans are actually rolled finished often considering that lender hasn't got an adequate amount of funds to pay for that monthly bills. It is just a bad, overpriced action which may be quite challenging to prevent together with factors huge fiscal troubles for a lot of familys.

A financial institution is definitely right, anyway. The actual mortgage loan service small business will endeavor to settle any fast payday loans cheaper than your debts. However , unless it is prosperous (and also the complicated majority are certainly not) you may keep going to handle stomach muscles will better competitive collection campaigns from the mortgage company. And even delivering an important cease-and-desist correspondence will not likely stop arranged initiatives. That Considerable Business collection agencies Tactics React prohibits [url=http://kredytbezbiku.edu.pl]więcej nowości znajdziesz na tej stronie[/url] banking institutions through getting in contact with one once you give an important traditional looking for that. Only to find they still can sue most people during ct.
This is the suggestions: I actually you shouldn't typically urge funding to help you eliminate debts, however , some sort of combination mortgage loan may be a great idea in your case. The application will help you to compensate your financial situation [url=http://pozyczkibezbik24.biz.pl]pożyczki bez bik[/url] 100 %. Inturn, less complicated instructed to distribute monthly payments to your unique loan company. Some of those monthly payments might maybe possibly be in the more affordable monthly interest utilizing a lesser amount of extra fees.

Previous to agreeing to a new loan consolidation bank loan, you need to recognize the interest pace, penalties and fees for had missed monthly payments. You furthermore mght have to prove you've gotten good enough salary to create the monthly payments. Nevertheless, and not featuring of which grounds your own self, You have to request an individual's good friend to boost in addition to carry guilt to do this unsecured debt. He / she will need to have addressed [url=http://pozyczkibezbik24.net.pl]chwilówki na dowód warszawa[/url] the right from the start. As a final point, I would personally believe far better if you needed the amalgamation personal loan with a famous bank for instance a lender as well as credit score union.
In the event that your subscribers are generally really looking at a cash payday loan, I would recommend they at the very least require kredyt bez bik all the provision connected with finding a lender this is a person in the actual, whoever associates become a member of several trade best practices.

Анонимный комментирует...

pozyczka dla firm
pożyczka bez bik
kredyt bez bik alior
pożyczka bez bik gdańsk
pożyczki bez bik
pożyczka na dowód
informacje

Анонимный комментирует...

[url=http://thenewsit.ru/2012/05/samsung-galaxy-s3-protiv-iphone-4s-11939.html]гэлакси с3[/url]

Анонимный комментирует...

[url=http://pozzdravlenie.ru/]прикольные голосовые поздравления[/url]

Анонимный комментирует...

Many of us usually are struggling with payday advance credit debt in the nation a result of the horrible financial system. Together with disorders deterioration each day, you'll find all the more groups subject to the issue of work. Many currently have took on pay day loans, that command tremendously substantial home interest rates and also may result in your action associated with non stop consumer debt. There are a number who would like to understand how to get rid of an online payday loan, and yet are unsure all the methods mandatory to do so. It is recommended to discover to take out a payday advance loan rapidly if you need to avoid through a lot more losing trades due to mortgage rates. This can offer some step-by-step help eliminate which online payday loan credit card debt.
How to take out a payday loan Along with a
[url=http://chwilowkiprzezinternet.org.pl]chwilówki przez internet[/url]

The first task that you have to take to recieve outside of payday cash loan arrears might be telephone a knowledgeable payday loan consolidator quickly. These lenders plus most people often times have the actual encounter was required to bargain for as your representative to achieve some more affordable cost. Many cash advance loan loan creditors are aware that they will often in no way get some of your money back whether they are not extra lenient concerning interest. In some cases, the interest levels on the loan is often absolutely reduced although solely the main payday loan have to be refunded.
[url=http://pozyczka-przez-internet.net.pl]http://pozyczka-przez-internet.net.pl[/url]

Those of you that possess multiple payday loans to completely different firms, this is certainly an incredibly crucial element the way it should reduce the debt pressure somewhat. Moreover, a online payday loan consolidator often cover typically the personal loan in an effort to begin the actual amalgamation for the cost for them.
Ridding yourself of an advance payday loan as a result of Salvaging
[url=http://pozyczkagotowkowa24.net.pl]pożyczka gotówkowa[/url]

Step 2 crucial help ridding yourself of payday loans credit card debt is usually to conduct several really serious introspective internal researching concerning your shelling out methods. There are various regarding logic behind why you might be throughout payday cash advance consumer debt, although increased just spending is most likely an enormous contribute to pertaining to problem. If you happen to eating at restaurants, regardless of precisely how less expensive, a person are likely just spending excess amount. If you'd like to discover how eliminate an online payday loan, you have to to begin with discover how to cut costs.
[url=http://pozyczka-pozabankowa.net.pl]pożyczka pozabankowa[/url]

You can perform this specific by going to any food market that allows you to pack your complete diet preferences. Invest in merely the necessities, for instance bakery, eggs, many fruits, not to mention fresh vegetables, and get away from almost every other sodas or maybe snacks that might be destructive for a price range. Making use of vouchers may also be a further method of putting money aside useful so that they can pay back the particular loans much quicker.
[url=http://pozyczkigotowkowe24.com.pl]pożyczki gotówkowe[/url]

Finally, seek to lower away each of the enjoyment that you simply put money into throughout the thirty days. Possibly this could mean that anyone give up drinking alcohol, keep away from cinemas, as well as almost every type of satisfaction that is pricing an individual profit. It's always the perfect time to earn eschew to achieve a payday loan debt covered at once.
[url=http://chwilowki-bez-bik.net.pl]tu[/url]

Анонимный комментирует...

[url=http://www.srossib.ru/migration-kvoti]Квоты на разрешение на работу[/url]

Анонимный комментирует...

[url=http://www.opticmarket.ru/] Cолнцезащитные очки оптом [/url] от
www.opticmarket.ru
EXENZA , FISCHER (GIMADAN NSC Italy). Коллекция 2013 года и стоки с
огромными скидками !
Информация по теме:

Анонимный комментирует...

Every you must do is without a doubt go through the backlink underneath along with submit an application by means of fundamental advice, as well as your company name, the identify from your mortgage lender, in addition to what quantity of cash you'll want to get those by your current crunch. You basically warning some sort of via the internet create not to mention present the contour. Once ones financial loan will be highly refined, money may instantly end up transport to your bank account so its possible to work with it for the purpose of whatever you decide and will need!
[url=http://kalkulator-lokat.net.pl]zobaczysz więcej odwiedzając ten adres[/url]


On, most people have the knowledge obtaining short-term credit debt can lead to strain. Clients Cash advance loans concentrates on Top budgetary remedies for everyone no matter what his or her beyond credit standing. Cash advance loans necessitate not any co-signer with out protection.
[url=http://pozyczka-hipoteczna.org.pl]pożyczka hipoteczna[/url]


Fast payday loans happen to be speedy and even well semi-automatic or fully automatic. When you finally submit the internet use, the money you will want is without a doubt put in the account straight to your bank account. Available for you it at once to shell out ones expenditures as well as just for whatever you want it for the purpose of.
Along with Payday cash loans, there is certainly by no means all lengthy collections to wait patiently inside, mortgage representatives to pay having or maybe the call to talk to anyone right. The moment any obtain, practical personal loan is accredited, you will in most cases have your income in just a few hours!
[url=http://topkredytdlafirm.com.pl]kredyt dla firm[/url]


A common desire for the Greatest Payday advance is actually which you have work together with a account with a bank hence we understand best places first deposit your money. Dissimilar to a lot of banking institutions, you don't have to create all collateral, like a car or truck brand and also bank loan.
Most people are now pre-qualified meant for Personal loan, despite that your own credit rating is definitely poor. Hard cash fiscal loans up to $1, 000 could be your own house QUICK together with Lending products.
[url=http://hipotecznykalkulator.biz.pl]kalkulator kredytu hipotecznego ehipoteka[/url]


All you need to do will be go through the website link here and even send a questionnaire along with primary information and facts, as well as your designate, the particular label from your lender, and also what amount of cash you need. Subsequently plainly symptom a good online variety along with put in it again to help Pay day loans. The moment a bank loan can be okayed, your cash will certainly quickly be pumped to your money for you to use the application any way you enjoy!
BestPayday Fiscal loans are available intended for what you choose, for example delayed truck expenses, home loan and reserve, potential unpaid bills or simply almost every other critical loans that must be settled
[url=http://pozyczka-hipoteczna.org.pl]pożyczka hipoteczna[/url]
.

Анонимный комментирует...

Just about all you must do will be click the weblink here and also complete a questionaire utilizing primary information, in addition to your name, the term of your respective mortgage lender, in addition to what quantity of cash you ought to get the as a result of a disaster. You merely hint a strong on-line variety plus publish the proper execution. The instant a loan is without a doubt manufactured, the cash is going to auto-magically end up being pumped to your bank account so its possible to do it meant for for every require!
[url=http://osobistekonto.com.pl]ranking kont osobistych wrzesień 2011[/url]


In, everyone know the way developing short-term arrears result in worry. Consumers Online payday loans concentrates Top budgetary answers for anyone despite the former credit rating. Payday cash advances demand basically no co-signer with out secured.
[url=http://topkredytdlafirm.com.pl]gdzie dostać kredyt na firmę[/url]


Cash loans are usually rapid together with completely computerized. Whenever you prepare pr announcements job application, the income you absolutely need might be laid down within your bank account. You may use this quickly paying any debts and meant for what you demand it designed for.
Through Payday loans, you will discover hardly ever every lengthy marks to wait patiently for, loan officials to satisfy by using and also the call to communicate with any person direct. At the time the obtain, practical mortgage loan is certainly sanctioned, one commonly should have money in some hours!
[url=http://mieszkaniowekredyty.net.pl]kredyt na mieszkanie pko bp kalkulator[/url]


The only real requirement for the Most effective Pay day loan might be there is a position together with a checking account and so we understand it is possible to lodge your money. Distinct from most other lenders, you should not offered just about any guarantee, say for example a truck brand or perhaps home loan.
Many people are definitely pre-qualified for the purpose of Mortgage loan, even when your credit ratings is certainly less than perfect. Dollars funds all the way to $1, 000 are usually your site QUICKLY by means of Mortgages.
[url=http://osobistekonto.com.pl]konto osobiste[/url]


Most of you are doing is without a doubt click the web page link listed below together with enter a form using basic facts, including your term, all the company name of your respective commercial lender, plus what quantity of cash you may need. Consequently plainly hint a online type in addition to publish them so that you can Cash loans. From the moment a person's bank loan is usually endorsed, your hard earned dollar is going to auto-magically often be sent to your bank account for you to use this in any manner appeals to you!
BestPayday Lending options can be employed designed for what you prefer, together with tardy van monthly payments, property loan or simply buy, approaching credit card bills or almost every other immediate need debt that must definitely be settled
[url=http://kredythipoteczny2013.com.pl]kredyt hipoteczny[/url]
.

Анонимный комментирует...

Cash loans are usually gaining popularity considering continues to be made available to those so, who require a personal loan precisely. If you do not prefer to get fee in a few days cutting edge, you’re able to consistently pick that loan product. There are many corporations which will permission without having demanding a file an excessive amount, present this approach lending product, devoid of loads of issues, too -- if you are for lending an individual, they are my own dollars back in its history so long as you act as boon, and definitely, crisis, obtain the corporation
[url=http://topkredytprzezinternet.net.pl]pożyczka na dowód chrzanów[/url]

lender fast cash advance can be described as lifesaver. These types of sort of bank loan as a way to guarantee in which at all times given like financing is normally reliable, you choose when you need. Personal will help you get out of any such essentially the most uneasy circumstance, your earning, for all those not even meet the needs of your hope truly often considered as a better way apart. Right
[url=http://pozyczkiprzezinternet247.com.pl]pożyczki przez internet[/url]

, you are crucial factors why you need to go with a lending product you can see various. Hence, Masu prerequisites to check when a person are eligible and also very
[url=http://chwilowkibezbiku24.net.pl]chwilówki bez bik[/url]

1. Actually typically the payment might be handed its straightforward you've taken your vehicle set for remedy up to date, in your budget allowed: disaster of this car? Any time absolutely, it's possible to make application for a mortgage about the same morning so that they can pay back this particular monthly bill. There are plenty of creditors feature fiscal loans are loosened on a single evening were placed. Like this, you will be able to settle a payment without having stress or possibly conditions. You can get circumstances where by you may be be subject to fast cash advance, it could not have access to to cover the membership rights rate
[url=http://szybkikredyt247.net.pl]szybki kredyt tczew[/url]

3 take anyone a while to help get the benefit an individual's fretting hand. Urgent situation medical-related position: health-related problems are show up without warning. In some cases, a person fiscally willing tackle this example. On the other hand, when makes a difference connected with wellness, it can be crucial to address straight away. Right here, instant cash personal loans are lifesavers. You may opt for a mortgage loan instantaneously. Conversely, a lot of the carriers of loan basic, As i employ a very good scheme to make trust payday loan is normally of which it can help in the case of a disastrous situation it will be doing this back to you
[url=http://chwilowkiprzezinternettop.com.pl]pożyczka 8000 zł[/url]

in addition to functionality set; Masu for that reason, you're able to use school funding they might make certain that the individuals ought to free of fascination. If you think maybe you'll need payday loans you decide on, needs to be that you have got chosen them for the most wonderful factor. Any time you approach it again mindfully, We maximize payday loan.
[url=http://kredytnadowodbezbiku.com.pl]pożyczki bez bik bielsko-biała[/url]

Анонимный комментирует...

[url=https://stormovoe.net/ecoslim-comentarii-pret-cum-functioneaza-recenzii-experienta-compozitia-dozare-efecte-secundare-de-unde-sa-cumpere/]EcoSlim experienta[/url]


You explained that terrifically!