recordset

  1. F

    Average recordeset field or worksheet column

    I have a database I use to fill a recordset used to fill several sheets in excel. How do I average an only numbers field of the recordset or the column it fills in excel worksheet? the registers number is not fixed. So the Range() method can't have arguments like "B1:B5". It's not previously...
  2. A

    Using ADO to add data to fields with similiar name.

    I have a table, name myTable in access database in desktop\jwb.accdb. the table has more then 50 fields. the name of the fields: answer1, answer2,....answer50. And I have data in excel column A1 to A50 that I want to add to these fields. data in A1 to answer1 data in A2 to answer2 data in A3 to...
  3. F

    Averaging a recordset column

    Hey there! I created a VBA application in my Acess database. This application generates lots of worksheets within lots of workbooks to calculate meteorological stuff. I am trying to calculate the average of a column in a recordset containing data retrieved from my access database. This...
  4. D

    recordset columns-operations and maximum value

    How can I do operations with recordset columns, for instance I have the following code rsR.Open "SELECT resistance FROM [compilation$B6:C32450]", con rsX.Open "SELECT reactance FROM [compilation$B6:C32450]", con how can i calculate the following new values: The minimum and maximum value of Z...
  5. F

    Recordset not updatable

    We have a database with a number of queries created. The person who handles our reporting uses Excel 2003 with pivot tables linked to those Access queries. She goes in weekly to refresh the Excel tables with the current data in Access. Last week it worked fine. Yesterday when she refreshed...
  6. I

    Master Detail Values display across right

    Dear VBA Guru I've a Master /Detail table as follows: Master Memb_No, MemberName, Surname 01, Paul, Smith 02, Richard, Gray Detail Memb_No, First_Name Surname Relation Dob 01, Clare, Smith, Wife, xx 01, Derek, Smith, Son, xx 02, Caroline, Gray, Wife, xx 02 Melaine Gray Daughter xx I would...
  7. S

    Add items in ListBox from recordset

    I have a recordset with a sql query like "select id, name, age from table_name". How is it possible to insert rows in a listbox with the three columns specified in the sql query? I know how to specify the number of columns in the UserForm, but not how I can add the rows. Thank you
  8. S

    Database handling across procedures

    I have some modules which contains some procedures which uses a database connection through ADODB. What is the best way to control all these procedures database connections? Can I somehow only write the username, password and such one time and then reuse this in the other modules?
  9. S

    Recordset - possible to choose a certain item?

    Hi guys, I got a question regarding a recordset. Is it possible to choose a certain item from a recordset, when I know the values of all the fields? Or do I have to loop through it? Cheers
  10. J

    Array into SQL Statement

    Hi, I'm working on a recordset that updates a table (an excel spreadsheet actually) based on the results from a custom form. The input from the form is an array with the codes of companies that should be included in the query. Example: Dim myArray(1 to 1) As Variant myArray(1)="001"What I'd like...
  11. I

    Recordset Condition

    Hi All, I have a function when the value is Null its stopped which is great but when the value in the field(date) value. it working great. The field which is checking its date value. But some time if the date value is old date meaning not equal to today's date(Now) it shouldn't be run but some...
  12. Jon von der Heyden

    ADO recordset null record displayed as 1

    Hi Another quirk I can't see reference to. I am pulling a small recordset out of an Access database. It is a single field recordset. Some records are null. If I try and load the recordset into an array I get a mismatch error. The field is set as a text fields. On closer inspection I...
  13. Jon von der Heyden

    ADO Stream Object sorts the field order - why?

    Hi All A little while back Andrew showed me that using the ADO Stream object I could preserve the recordset filter. I am using this: Public Function FilterRecordSet(ByVal objRecordSet As ADODB.RecordSet, ByVal strFilterText As String) As ADODB.RecordSet Dim objStream As ADODB.Stream...
  14. Jon von der Heyden

    ADO recordset filter doesn't seem to stick!

    Hi I have a recordset from a select * query to an access DB table. I want to be able to filter the recordset (using filter property). The users enter the filter expression in a textbox. After that they have a choice to take the data into a pivot table, or a csv file. The code runs without a...
  15. T

    REcordset wont work

    someone please help me i have created a recordset which is suppose to run an sql but it is giving me an error "duplicate declaration in current scope". all i have done is used: adodb.recordset again but what can i change it because i need abother recordset?? Public Sub Queries() Dim rst As...
  16. T

    PLEASE HELP:Recordset with SQL query

    So i want to create a recordset containing sql queries that i am going to call in a loop. but the thing is i am facing difficulty with the recordset, i know it is a stupid mistake that i am making please help : "Dim strSQL1 As String strSQL1 = "SELECT COUNT (INUNACPT) FROM AIS3AM4.KTPT80T WHERE...
  17. J

    Limits on ADODB.Recordset

    Hi. I'm running a query that basically aims to show the Market Value of a Portfolio Inventory (T for Transactions) based in Historical Prices (P for Prices) on a daily basis: Dim myConnection As ADODB.Connection Set myConnection = New ADODB.Connection myConnection.Open...
  18. S

    excel 2003 - vba - ADO recordset formatting

    Hi, I have an ADO recordset whereby the data returned is all text. When I pass the recordset to my pivotCache object, the pivot table will be created but since the data is all text...the pivotfield type is set to "Count of.. ". Question : is there a way to convert the recordset data to the...
  19. S

    Excel 2003 - VBA - use ADO recordset & create pivot table

    Hi, I have succesffuly imported data from my ADO connection to my worksheet. However, i would like to know 1 - how do I create a pivot table with my recordset object Thanks in advance :)
  20. T

    Getting Values out of a recordset

    Hi, I need to get values out of a recordset in order to filter a second sqlstring I constructed a filter query and get the records out of it in the first SQLstring in order to use the values to filter the second SQLstring. Unfortunately, when I set CountryCurveSelect =...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top