Hot answers tagged

6 votes

Passing multiple parameters to an SQL query

Sub Module2 is a terrible name to use for a procedure. Not only it doesn't say anything about what it does, it looks like the [default] name of some standard code ...
Mathieu Guindon's user avatar
5 votes
Accepted

Materializing any ADODB Query

I want to focus on the SqlResult/SqlResultRow classes here. The way it is, it is analogous to having bought a huge expensive ...
this's user avatar
  • 2,019
4 votes

Secure ADODB: Unit of Work

I have been silently waiting for you to post this for a while. I was working on something nearly identical to this, and almost posted my stuff a couple of weeks ago, but I wasn't sure of how to hook ...
rickmanalexander's user avatar
3 votes

Secure ADODB: Unit of Work

Comment on Transaction DDL. While Microsoft does state that its presence indicates that the backend supports transactions, there is another reference (possibly ...
PChemGuy's user avatar
  • 425
3 votes

Creating ADODB Parameters on the fly

Waking this one up... ExecuteNonQuery Return value never assigned ExecuteNonQuery never has its return value assigned. Return value type You have an ...
ThunderFrame's user avatar
  • 1,959
3 votes
Accepted

Getting Windows User Info From The Active Directory

Very clean code, reads very nicely, well done! Watch for inconsistencies in indentation: Public Sub PrintToImmediateWindow() With this ...
Mathieu Guindon's user avatar
2 votes
Accepted

ADODB Wrapper Class (Revisited)

CommandTimeout: Allowing the client to specify a given command's execution time threshold by making it a read/write property is good improvement from the first post of this class, that you did not ...
rickmanalexander's user avatar
2 votes
Accepted

ADODB Wrapper Class

"The Properties ParameterNumericScale and ParameterPrecision are used for setting the total number of digits and number of digits to the right of the decimal point in a number respectively. I opted to ...
rickmanalexander's user avatar
2 votes
Accepted

Node.js DataBase class for adodb databases

Review From a first look your code is bloated with debug noise and due to poor language feature utilization. Looking deeper I see that poor encapsulation makes using the class ...
Blindman67's user avatar
  • 21.6k
2 votes

Executing arbitrary SQL statements using VBA in Excel

Everytime you pass something without ByVal you are passing it ByRef, which is general, isn't necessary. I also see you passing a Scripting.Dictionary around, ByRef....
Raystafarian's user avatar
  • 7,129
2 votes

One way Synchronize 2 Access Tables with VBA ADODB

Using nested while loops can easily turn into a time-sink. Rather, save the missing checkGUID values to an array using SQL, and only loop once to save time (and debugging headaches): ...
Erin B's user avatar
  • 21
2 votes

VBA-Sync code feedback

Private Function connectionSuccessful() As Boolean The name suggest that you are testing to see if the Connection has already been opened when in fact it is used to opening the Connection and test if ...
TinMan's user avatar
  • 4,133
2 votes

Creating a values only copy of an excel workbook without opening it

I was able to greatly simplify the code using ADOX.Catalog to pull sheets instead of trying to figure out what is or is not a sheet. I also added code that will ...
HackSlash's user avatar
  • 382
1 vote

SQL Group qry by codeProduct and Last(description)

I mistakenly mistaken CodeReview as an "adjustment" of our code, sorry. I was sure that the solution to my problem was with JOIN QUERY, I can't see the light because I needed two JOIN. below the ...
Fabrizio's user avatar
  • 307
1 vote

Secure ADODB: Unit of Work

I have noticed this interface IDbConnection_CreateCommand, which appears to be an unnecessary coupling between DbCommandBase and ...
PChemGuy's user avatar
  • 425
1 vote

Run a query for each value in a column

The solution above shows some very old coding practices that are no longer valid. In addition the code has some level of complexity that is not required - almost like a Rube Goldberg approach! The ...
AJD's user avatar
  • 2,346
1 vote

Materializing any ADODB Query

Is there any reason you don't use a disconnected record set and just close the connection in the function that opened it? I wouldn't keep a connection open any longer than you need. ...
Allen Mattson's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible