User Profile
Collapse
-
not really sure but how can[acct] be a value on a textbox? -
Apparently I Found The Solution, When There Is A Criteria With A Like * In A Query, Even If Other Queries Are Based On It, If You Run The Subsequent Queries In Excel VBA You Need To Put % Instead.
How Annoying And How Dangerous That Is!Leave a comment:
-
Hi thanks a lot for the reply,
the statements are massive so i trimmed them a bit:)
query ag3:
query myquery:Code:SELECT AG.[Portfolio Type], AG.ISIN WHERE (((AG.[Portfolio Type])=1) AND ((AG.ISIN) Not Like "*PV*")) OR (((AG.ISIN)="SP13"));
and then i call it from excel vba.Code:SELECT AG_3.KEYAN7, FROM AG_LAST3;
What i found out is that the...Leave a comment:
-
you probably need to run different sql statements for each pressing of the dropdown.
try something like"
...Code:strSQL = "UPDATE " & "[" & MyTabName & "]" & " SET " & "[" & ComboBox_FLD3.Value & "]" & "=" & "'" & ComboBox_FL3_RES_CHANGE & "'" & " WHERE " & "[" & ComboBox_FLD1.Value
Leave a comment:
-
try this:
[CODE=vb]Private Sub OK_Click()
Me.Visible = False
constr = "Provider=Micro soft.Jet.OLEDB. 4.0; Data Source=" & _
"mydb.mdb" & ";"
Dim con As ADODB.Connectio n
Dim db As Database
Set con = New ADODB.Connectio n
con.ConnectionS tring = constr
con.Open
INSstr = "INSERT INTO" &...Leave a comment:
-
Table Update Brings Wrong Number Of Records
Hello, I need some help please,
I am trying to insert all the fields from a query to a table. I use the following statement from vba:
however myquery depends on other queries which have criteria.Code:INSERT INTO [myTBL] select myquery.* from [myquery];
The number of records in [myquery] is 300 but when [mytbl] is loaded it comes up with more records. Any idea why this might be happenning??
thanks... -
RECORDS CONTAINING " ' "
HELLO,
I need to insert records to an access table with vba code but the records have the " ' " in them, so the statement cannot be executed. what can i do?
thanks a lot for your help. -
-
-
-
Sql Statement To Create Table With Fields Like A Query
Hello,
Is there a way to create a table with the same fields and field attributes that are in a query? i mean lets say field1 is Telephone and is text etc...
Thank you very much. -
hello,
Thnks for the answer!
with your help I came up with the following sql statement which works :
INSERT INTO [TBL] select * from [QUERY] ;
thanks a lot againLeave a comment:
-
i think you might need to use:
not just dirCode:Dir$(curr_dir & "*.*")
Leave a comment:
-
SQL STATEMENT to insert fields in a table from a query
Hello all,
can somebody help me out please, I try to create an sql statement to insert into a table everything that there is in a specific query. Including the Field names.
Thanks very very much! -
hi, thanks for the reply,
I just run a simple query from excel vba. Is there a way for excel to get this progress status from access. or even in access itself. How is it done?
Thanks againLeave a comment:
-
it can be done of course, but you need to used the command dir$(AB*.txt). check out help section.Leave a comment:
-
Progress Bar Moving While Running Query
Hello,
can somebody give me an idea on how to make a progressbar or something moving in an excel form while using vba to run a query in access that takes about 9 minutes to complete and excel freezes during the time...
Thanks you very much.. -
Yes ok,
I am trying to open a odbc con from Excel and use it for 2 specific subs.How do I make it global?Leave a comment:
-
Clear the data of certain tables:
...Code:Public Sub DELETE_PRODUCTS_TABLE() constr = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & _ "C:\DB.mdb" & ";" Dim con As ADODB.Connection Dim db As Database Set con = New ADODB.Connection con.ConnectionString = constr Dim recset As ADODB.Recordset con.Open mydb = "C:\DB.mdb"Leave a comment:
-
create an sql connection and use it from different subs and modules
Hello,
can somebody please help me with the following,
i want to create an sql connection and use it from different subs and modules.
for example:
constr = "Provider=Micro soft.Jet.OLEDB. 4.0; Data Source=" & _
FRM_BALCANOR.Te xtBoxDB.Text & "BOGGERDB.m db" & ";"
Dim con As ADODB.Connectio n
Set con = New ADODB.Connectio n
con.ConnectionS tring...
No activity results to display
Show More
Leave a comment: