Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

populate fields in access through sql script

Status
Not open for further replies.

mancusoj

MIS
Jul 18, 2003
5
US
I have oracle tables connected in a access application. I have three fields on one of the forms merchant name, merchant id and pidm. I am trying to have two fields(id and pidm)populated based on a combo box selection(merchant name). The code I have used in an afterupdate procedure is

Private Sub FZTVEND_MERCHANT_NAME_AfterUpdate()
SQL = "Select Saturn_Spriden.spriden_pidm as pidm, saturn_Spriden.spriden_id as id"
FROM "saturn_spriden.SPRIDEN_LAST_NAME = " & FZTVEND_MERCHANT_NAME.Value & "'"
Set R = CurrentDb.OpenRecordset(SQL)
R.MoveFirst
ID = R("ID")
PIDM = R("PIDM")
Set R = Nothing
End Sub

Any suggestion would be great. Thank you
 
This is not an Oracle forum, this one is for Mmicrosoft SQL Server. T-SQl sysntax would most likely not be the same as the correct Oracle sysntax. Suggest you go to the Oracle forum.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top