>
>For SQL server see the parametric approach. It also handles headaches for conversion if field on VFP side is either date or datetime. ie:
>
>
>* f1: char, f2: datetime, f3:datetime
>cInsertCmd = "insert into myTable (f1, f2, f3) values (?m.Value1, ?m.Value2, ?m.Value3)"
>SQLPrepare(m.lnHandle,m.cInsertCmd)
>m.ldStart=date()
>for ix=1 to 5
> m.Value1 = cdow(m.ldStart+m.ix-1)
> m.VAlue2 = m.ldStart + m.ix - 1
> m.Value3 = datetime() - (m.ix * 3600)
> SQLExec(m.lnHandle)
>endfor
Cetin
Can you please explain what is the purpose of the "for ix=1" loop? Why do you call SQLExec without an insert command there? Can you do that?
Thank you.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham