Link To A Query
Dec 7, 2005Hi
i would like to link to a query. when i go to file | Get External Data | Link Tables, i don't see my queries. is this possible??? and if so how?
sam
Hi
i would like to link to a query. when i go to file | Get External Data | Link Tables, i don't see my queries. is this possible??? and if so how?
sam
Please would someone be able to advise me how I could link an Access Query to an Excel spreadsheet. Also, is it possible for the Excel spreadsheet to be 'updated' automatically when the data in the Access Query is updated ?
Many Thanks
Richard
Hallo,
I'm quit new to Access.
I have an existing application. There is a form with some selection fields. When I press the button report then following is executed:
- The report object is called with DoCmd.OpenReport Rpt, acPreview
- This report has object dependencies with the query qryRptClient AND the form frmClient. This is the form with the selectia criteria.
The query "qryRptClient" has nested query's but in some of them, in the where clause fields are tested like: "WHERE (tblTempProject.country=forms!frmClientReq!cmbCoun try"
Generating of the report works correct ==> so far so good.!
Now the application must be extended by exporting this report result to XML file. So I have added on the form another button wich is calling the same query Like:
Application.ExportXML _
ObjectType:=acExportQuery, _
DataSource:="qryRptClient", _
DataTarget:="c:Projecten estexports" & FileName
But now I get for every selection criteria field which is used in the query's a popup window asking what the value is of this form object.
So, I understand with the report that there is a link between the report, query and the form but in the second occassion how do I get a link between the query and the form.
Can somebody help me? Thanks in advance.
Nico.
P.s. When I try this with northwind database, with the query invoices, it working correct and I get a XML file! So the export on itself is working.
Hi
I have an append query which runs from a command button. It transfers all the fields I want it to but when I run the query when in one particular record it not only appends the field for the current record but appends the fields for every other record in my table. I know I should be running the query using stLinkCriteria but I'm not sure on the syntax for the code, see below:
stDocName = "qryAppendOtherAdults"
stLinkCriteria = "[ApplicationNum]=" & "'" & Me![ApplicationNumber] & "'"
DoCmd.OpenQuery stDocName, acNormal, acEdit
Me.frmOtherMember.Requery
Can someone help me with this one please?
I want to create a drop list, so I can do that:
I select an item from the drop list. I detect the ID of the item and, depending of this ID, I select some records from a table.
Can somebody help me?
I am working on creating a query to base a form on. I've done it several times in this database, but today, for some reason I cannot figure out how to do it.how I did it before but it looks like the SQL statement got wonky:
Code:
SELECT tblEmpInfo.EmpInfoID, tblEmpInfo.EmpIDFK, tblEmpInfo.JobNumberFK, tblEmpInfo.EmpType AS Expr1, tblEmpInfo.CraftCode AS Expr2, tblJobs.JobSite
FROM tblJobs INNER JOIN tblEmpInfo ON tblJobs.JobNum = tblEmpInfo.JobNumberFK;
Basically I have a look up table and all I'm doing is making it so I don't see the Cert ID it just pops up with the description.
Basically what I am trying to do is to link the crosstab query to a Form. the crosstab query has the following SQL:
TRANSFORM Sum(SubQryTotalProductSales.SumOfQtyOrdered) AS SumOfSumOfQtyOrdered
SELECT SubQryTotalProductSales.fkProductID, SubQryTotalProductSales.ProductName
FROM SubQryTotalProductSales
GROUP BY SubQryTotalProductSales.fkProductID, SubQryTotalProductSales.ProductName, SubQryTotalProductSales.YrOrder
ORDER BY SubQryTotalProductSales.YrOrder DESC
PIVOT SubQryTotalProductSales.YrOrder In ("2015","2014","2013","2012");
The Main form was made from my Product table and contains all the product related fields. ProductID, ProductName, Description, X_Ref, ListPrice, OurCost, fkSupplier, Discontinued, ReorderLevel etc....
Then I made a Subform with the crosstab query, and tried to place it in the main form. So far everything seemed to work. The next thing was to make the Child and Master Link, I used the fkProductID from Child (Subform), and the ProductID from Master. So there are no errors, but I don't get the link to work, that is when I change the product Field in the Master the Subform does not change accordingly.
When I change the view to design view and then change again to Form view, it opens up with the correct product in both Master and sub. Except in the Sub the productName Shows the productID instead of product Name.
I am referencing a table output in excel and when I go into Access to see where the table is pulling data from I get stuck. I go into the table in design view but where the table is getting its data from. I need to know which queries it is getting its data.
Access 2003.
I'm trying to separate LastName, FirstName into separate fields : FirstName and LastName. The code I have is working for the most part. But I had to create a separate query with the replace statement to get rid of the ","... Looking at the data now, I had people with names like Mac Buren, Tony and I'm only picking up the Mac part in my query.
Code:
SELECT Left([Employee Name],InStr([Employee Name]," ")) AS qryLastName, Right([Employee Name],Len([Employee Name])-InStrRev([Employee Name]," ")) AS [First Name], Employees.*
FROM Employees
ORDER BY Left([Employee Name],InStr([Employee Name]," "));
Is it possible to link a field in Access to a footer in Word?
I have a field in Access that would look like the following;
G10E-PRO-001RevA
Additional data in access would have the document name, and revision, matching 2 lines of text in Word. I would like the footer in the document to be the above sample, which I assume could be a query that need to run to match the 2 fields of information.... not really sure if this is even possible?
Like the title says it:
Is it possible to link/export a query to a existing Word document?
I have several Word documents with text, and i want to place the data of a few query's in those documents in a certain place.
Is this possible true vba or another way?
I created a query that shows everyone who has a specific date field blank. Now want to make those names clickable so that it opens a specific form with a certain record related to that individual in the query. Each line with a different individual should open a different person on the form and their corresponding record.
View 3 Replies View RelatedI am trying to set up something to be able to take me to a folder that holds various forms for personnel. I have a query that generates the link for each person. I have tried to set it up as a hyperlink in ACCESS 2013 and it displays as one but doesn't act like one.
I want to be able to click the link and have it open up a personnel folder for that individual. I can't find a MACRO that I can create to do it. Example of my query is that it creates a link K:Main BreakdownSection BreakdownPersonnel FoldersName and the name is the variable part.
My next problem will be to have it create that folder when we have new personnel arriving.
I would also note that I have not worked with ACCESS in many years and much of what I was able to do with 2002 and 2003 doesn't work with the newer versions of ACCESS.
Folks,
i have a small problem wizzing my nut. I copy two tables from mycurrent database to an external database,now i am trying to link these two tables in the external database to the ones in the currentdb. I get a run-time error 3012 telling me that an object 'tblLanguage' is already present.which iam failing to track. Any ideas Please??
Here is my linking code.
Sub LinkMeUp()
Dim tbl As DAO.TableDef
Dim sTableName As String
Dim sThatTblpath As String
Dim dbName As String
dbName = "my_ExternalDatabase"
sThatTblpath = ";Database=" & db_Path & "" & dbName
For Each tbl In CurrentDb.TableDefs
sTableName = tbl.Name
Set tbl = CurrentDb.CreateTableDef(sTableName)
tbl.Connect = sThatTblpath
tbl.SourceTableName = sTableName
CurrentDb.TableDefs.Append tbl
Next tbl
End Sub
Hello,
The current database I am working on I made it by copying the one I was working on originally. I just realized on the VB window that there is still some relation between them. Because, if I look at the tree on the left of the code window I see it says "GCB (miniGCB)", being GCB the one I copied, and miniGCB the one I am working with.
How can I get rid of the link with GCB?? I want the tree to just say "miniGCB".
Thanks,
Hello all,
I created a table and linked a pdf file to one of the fields, but when I created a form to display the table contacts, I could not see the attachment or icon or any reference to the linked object. The field in my access table is an OLE object.
Thanks for helping out.
I have packaged an Access DB (Split) as a run time solution so I can distribute to users without Access.
When I install it on a PC it runs.
If I move the back end to a network, the solution can't find the back end because it has been moved.
Access run time does not include the linked table manager in the toolbar.
Is there code in VBA where I can refresh the link between front and back end.
Ideally I want to write an error handler that will call a sub to prompt the user for the new location of the back end if it has been moved. Then have the user browse to the network location and click on the back end and store that location as a string. Using that string refresh the links.
Any ideas on that?
Hi all,
I have added about 15 links on a form, linking to word and excel documents. The word documents open fine but all of my excel documents pop up with a messae saying the file cannot be open, yet when i just go to the document on my hard drive they all open fine...does anyone have any ideas please. Thanks
Hi,
I'm new to this so please go easy!
I have an excel document which automatically refreshes data gathered from an access db.
I need to put a button on the switchboard on the same db to open the excel document, basically to make it easy for others to find.
I have tried hyperlinks but it doesn't want to play. It locks the db and then won't refresh the information.
I know i'm missing something blindingly obvious, can someone help?!
:confused:
Thanks
elsiegee
Hi Forum,
I'm building a db to track computer and user problems for work, where I double as a Client Support Administrator (IT Guy).
I have these tables: (simplified list)
tblComputers
tblPeople
tblCompAssignment
tblProblems
I'm at a loss as to how to link the 'Problems' table. This is where I'll record trouble tickets reported by users.
Incoming trouble tickets could relate to the Computer or to the User's Network Login.
I thought I might have a field in the problems table for UserName and also one for ComputerID, but this seems problematic. Anyone got any ideas?
I am trying to link to a url from a message box with difficulty.
eg the user opens the form and a message box appears asking have the latest datasets been downloaded? If answered yes the form opens, if no links to web address.
has anybody any examples.
Thanks
I have a database which works as an information system for the upcomming olympics.
In tblAthletes is...
AthleteID (Primary Key)
FirstName
Surname
And Various other fields not needed in this problem
In tblResults is...
Gold
Silver
Bronze
Also other field in this table
What I am aiming for is to have Gold AND Silver AND Bronze all as foreign keys of the AthleteID field.
Is there a way to do this or can another way be suggested. I am working on the 2000 version of access.
Hi There
i am trying to link some more tables to my access front end from the sql server back end
when i select 'ODBC Databases' from the link pop up box, the pop up box just closes
any ideas why, or work arounds would be appreciated
Happy Christmas
Does anyone know how to link tables automatically/VBA?
I'm trying to import files from our DB2 database in which one file is created monthly and instead of manually importing / linking the files manually, I'm looking to have access link to the new file automatically.
The file names are structured as so..
ITM01 (Jan)
ITM02 (Feb)
ITM03 (March)
Thanks
Hello everybody,
I have one dbase with 3 tables wiht 3 forms. One is "custonmers" , "glass" and "lens".
Customers - CusID as primary Keys
Glass - GlasID and CusID primary keys
Lens - LensID and CusID Primary Keys
When I change a specific field (only) I am losing the records on the other tables of the specific customer.
Thanks in advance
xxx ΠΑΟ ΘΡΗΣΚΕΙΑ ΘΥΡΑ 13
Hi All
I enter data in a form "WIP" that is based on a table named "WIP" in the form I have a command button. When I activate the command button it takes me into another form "Materials" which is based on a table named "Materials".
The data that I enter into "Materials" is not linked to the data ie Customer details which I have entered into "WIP".
My aim is to be able to report the materials used.
I have tried variations of relationships but am obviously missing something.
Thanks in Advance
Geoffk