Re: Define FROM target in Append Query
From: Duane Hookom (duanehookom_at_NO_SPAMhotmail.com)
Date: 02/15/04
- Next message: diesel: "Re: Counting"
- Previous message: Duane Hookom: "Re: group query help, please"
- In reply to: rbrandt: "Re: Define FROM target in Append Query"
- Messages sorted by: [ date ] [ thread ]
Date: Sun, 15 Feb 2004 14:49:43 -0600
Assuming you have code in the form frmProcessEditor perhaps you place code
in the after update event of tbxNewTable.
Dim db as DAO.Database
Dim qdf as DAO.QueryDef
Dim strSQL as String
Set db = CurrentDb
Set qdf = db.QueryDefs("qappQuery")
strSQL = "INSERT INTO [" & Me.tbxNewTable & "] ( PageKey, ShapeKey,
ShapeText )" & _
"SELECT tblP1.PageKey, tblP1.ShapeKey, tblP1.ShapeText " & _
"FROM tblP1 " & _
"WHERE PageKey=forms.frmProcessEditor.tbxPageKey " & _
"And ShapeKey =forms.frmProcessEditor.tbxShapeKey " & _
"And ShapeText=forms.frmProcessEditor.tbxShapeText;"
qdf.SQL = strSQL
Set qdf = Nothing
Set db = Nothing
You could resolve the other references to the form. I didn't do this since I
wasn't aware of the data types.
-- Duane Hookom MS Access MVP "rbrandt" <rbrandt2@flash.net> wrote in message news:0EDA856B-8B6C-48A5-BABB-B2AFF16DF2C2@microsoft.com... > Can you tell me/show me more please. Example? > thanx
- Next message: diesel: "Re: Counting"
- Previous message: Duane Hookom: "Re: group query help, please"
- In reply to: rbrandt: "Re: Define FROM target in Append Query"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|