web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Suggested Answer

sql: Can we cage connection after select, and if it will get a error or not?

(0) ShareShare
ReportReport
Posted on by

Description:

if we have two userconnection and we change the useconnection to another after select, i want to known whether it will get a error? is it reasonable? please give me suggestions, thanks!

For example:

bCon = new UserConnection();
cCon = new UserConnection();
table1.setConnection(bCon);
select * from table1 where table1.intfield==2;
table1.setConnection(cCon);

I have the same question (0)
  • Suggested answer
    nmaenpaa Profile Picture
    101,162 Moderator on at

    So you want to know if the code that you shared will cause an error?

    Here's the quickest way to find that out: test your code!

    Then please share the result with us. Thanks :)

  • Sergei Minozhenko Profile Picture
    23,093 on at

    Hi Apple,

    Would you mind sharing what are you trying to achieve with that approach?

  • Liya Cheng Profile Picture
    on at

    yeah, i want to know whether the error is reasonable?

    error refer to  the following info:

    <error>Cannot execute the required database operation.

    Cannot attach to connection since the buffer is in use. Use another buffer or clear the buffer by assigning NULL.<\error>

  • Suggested answer
    Martin Dráb Profile Picture
    237,976 Most Valuable Professional on at

    The error is reasonable. Trying to point a buffer to another DB connection is not.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 456 Super User 2025 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 429 Most Valuable Professional

#3
BillurSamdancioglu Profile Picture

BillurSamdancioglu 239 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans