I think this is a stored query ( query that I have on my list of query in the database windows). But I want the word "Note by" can be changed according to the language. My software is capable of making it many languages. I have the Form Label table. Aslo the Message Strings table.
Thanks for your enlighting.
Frank
Douglas J. Steele wrote:
Are you talking about a stored query that you are trying to run, or are
25-Jan-10
Are you talking about a stored query that you are trying to run, or are yo
building the SQL dynamically in VBA
For a stored query, you cannot refer to a variable. Your options would be t
refer to a control on an open form, or write a function that returns th
value of the variable. However, from your message it sounds like yo
actually want to set it to a constant value, which can be done
INSERT INTO Catatan ( NO_URTANGT, TGLCATATAN, WKTCATAT, Subject, Notes
SELECT a.NO_URTANGT, a.TGLCATATAN, a.WKTCATAT, a.Subject, a.Notes & "Dicata
Oleh
FROM [C:\Churchdata\Churchdataconso\BkEnd\Hahomion_be.mdb].Catatan AS a
To refer to a control MyControl on a form MyForm, you would us
INSERT INTO Catatan ( NO_URTANGT, TGLCATATAN, WKTCATAT, Subject, Notes
SELECT a.NO_URTANGT, a.TGLCATATAN, a.WKTCATAT, a.Subject, a.Notes & " "
Forms!MyForm!MyContro
FROM [C:\Churchdata\Churchdataconso\BkEnd\Hahomion_be.mdb].Catatan AS a
If you have written a function MyFunction that returns the value of th
variable, you would us
INSERT INTO Catatan ( NO_URTANGT, TGLCATATAN, WKTCATAT, Subject, Notes
SELECT a.NO_URTANGT, a.TGLCATATAN, a.WKTCATAT, a.Subject, a.Notes & " "
MyFunction(
FROM [C:\Churchdata\Churchdataconso\BkEnd\Hahomion_be.mdb].Catatan AS a
If you are building the SQL in VBA code, you would us
strSQL = "INSERT INTO Catatan ( NO_URTANGT, TGLCATATAN, " &
"WKTCATAT, Subject, Notes ) SELECT a.NO_URTANGT, " &
"a.TGLCATATAN, a.WKTCATAT, a.Subject, a.Notes & ' ' & '" &
MyVariable & "' " &
"FROM [C:\Churchdata\Churchdataconso\BkEnd\Hahomion_be.mdb].Catatan AS a;
Exagerated for clarity, that i
"a.TGLCATATAN, a.WKTCATAT, a.Subject, a.Notes & ' ' & ' " &
MyVariable & " ' " &
although you could get away wit
"a.TGLCATATAN, a.WKTCATAT, a.Subject, a.Notes & ' " &
MyVariable & "' " &
-
Doug Steele, Microsoft Access MV
http://www.AccessMVP.com/DJSteel
(no e-mails, please!)
Previous Posts In This Thread:
Submitted via EggHeadCafe - Software Developer Portal of Choice
Bar Graph With ASP And No Components
http://www.eggheadcafe.com/tutorial...9-60eb835185fa/bar-graph-with-asp-and-no.aspx