Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
DSN on advantage database
Message
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows Server 2008
Miscellaneous
Thread ID:
01453262
Message ID:
01454368
Views:
36
Bonjour naomi,

No it do'nt work. See attachment.

It's only with the command AdvantageLocking=ON; ( Inside )


>I don't think you need to have double quotes inside the string when you build it... If you remove them and macro, would it work?
>
>>Hello Sergey,
>>
>>ok !
>>
>>
>>  TEXT To lcConnString NOSHOW TEXTMERGE PRETEXT 15
>>"driver=Advantage StreamlineSQL ODBC;
>>DataDirectory=C:\cdbk90\amline\AdsBob\JM;
>>SERVER=NotTheServer;Compression=;
>>DefaultType=Advantage;
>>Rows=False;
>>Language=ANSI;
>>AdvantageLocking=ON;
>>Locking=Record;
>>MemoBlockSize=64;
>>MaxTableCloseCache=5;
>>ServerTypes=6;
>>TrimTrailingSpaces=False"
>>  ENDTEXT
>>
>>
>> CREATE CONNECTION NORTHWINDCONNECTION CONNSTRING &lcConnString   
>>
>>
>>
>>This code give me a error ( Command contains unrecognized phrase/keyword (Error 36) )
>>
>>
>>
>>
>>  TEXT To lcConnString NOSHOW TEXTMERGE PRETEXT 15
>>"driver=Advantage StreamlineSQL ODBC;
>>DataDirectory=C:\cdbk90\amline\AdsBob\JM;
>>SERVER=NotTheServer;Compression=;
>>DefaultType=Advantage;
>>Rows=False;
>>Language=ANSI;
>>Locking=Record;
>>MemoBlockSize=64;
>>MaxTableCloseCache=5;
>>ServerTypes=6;
>>TrimTrailingSpaces=False"
>>  ENDTEXT
>>
>>
>> CREATE CONNECTION NORTHWINDCONNECTION CONNSTRING &lcConnString   
>>
>>
>>
>>This code do'nt give a error. ( until AdvantageLocking=ON; )
>>
>>do you know the reason ?
>>
>>bernhart
>>
>>
>>
>>>Create a file DSN, open it in any text editor and copy settings from there.
>>>
>>>>
>>>>i should like a sample to make a DSN advantage sybase
>>>>
>>>>
>>>>here is a sample with free VFP tables.
>>>>
>>>>
>>>>strDriver = "Microsoft Visual FoxPro Driver" 
>>>>
>>>>strAttributes = "DESCRIPTION=Temp DSN" 				+ CHR(0)
>>>>strAttributes = strAttributes + "DSN=AmlineFreeTables" 	+ CHR(0)
>>>>strAttributes = strAttributes + "SourceType=DBF" 	+ CHR(0)
>>>>strAttributes = strAttributes + "Deleted=Yes" 		+ Chr(0) 
>>>>strAttributes = strAttributes + "BackgroundFetch=No" + Chr(0)
>>>>strAttributes = strAttributes + "Collate=Machine" 	+ Chr(0)
>>>>strAttributes = strAttributes + "Exclusive=No" 	+ Chr(0)
>>>>strAttributes = strAttributes + "SourceDB =" + SYS(5) + CURDIR() + CHR(0)
>>>>*strAttributes = strAttributes + "UID=sa" + CHR(0)
>>>>*strAttributes = strAttributes + "PWD=" + CHR(0)
>>>>*'To show dialog, use Form1.Hwnd instead of vbAPINull.
>>>>intRet = SQLConfigDataSource( vbAPINull, ODBC_ADD_DSN, ;
>>>>   strDriver, strAttributes)
>>>>
>>>>
>>>>thank in advance for help
>>>>
>>>>
>>>>
>>>>bernhart
Previous
Reply
Map
View

Click here to load this message in the networking platform