Public Function Stroka_Parametrov(ID_Films) As String
Dim db As DAO.Database 'ñîçäà¸ì dao. áàçó
Dim rs_TBL As DAO.Recordset 'ñîçäà¸ì dao. íàáîð çàïèñåé
Dim SQL_STRING As String
SQL_STRING = "SELECT Parametrs_Film_TBL.ID_Film, Parametrs_Film_TBL.Parameters_Film " _
& "FROM Parametrs_Film_TBL " _
& "WHERE (((Parametrs_Film_TBL.ID_Film) = " & ID_Films & ")) " _
& "WITH OWNERACCESS OPTION;"
Set db = CurrentDb ' áàçà òåêóùàÿ
Set rs_TBL = db.OpenRecordset(SQL_STRING, dbOpenDynaset) 'îòêðûâàåì "Peresechenie_Dat_Air"
With rs_TBL
Do Until .EOF = True 'Öèêë äî êîíöà òàáëèöû
Stroka_Parametrov = Stroka_Parametrov & !Parameters_Film & ","
.MoveNext
Loop
End With
rs_TBL.Close
Set rs_TBL = Nothing
db.Close
Set db = Nothing
End Function
|