Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SqlConnect(),SqlGetProp()
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Client/serveur
Divers
Thread ID:
00800681
Message ID:
00800699
Vues:
16
SQLCONNECT([cConnectionName | cDataSourceName [, cUserID [, cPassword ]][, lShared]])

Understanding the syntax and Process will help.

gnHandle = SQLCONNECT(gcDSN,'MRPSA')
In the above code
gcDSN is your DSN and
MRPSA is your Username at initial.

Login Dialog box at login is displayed only when the username,password,connection name is wrong. which is forced displayed by ODBC engiene

When you supply new user name it directly sends it to server for authentication and authenticates and did not communicate to VFP.

Though this New username is not provided to VFP . The vfp is not aware of it and sends you the OLD Username .

I hope this explains.

Aashish

>Hi All,
>
>In My Application , i am using SQLCONNECT() to connect SQL SERVER Database.
>
>After successful connect , i am using SQLGETPROP (gnHandle,'UserId'), function returning unexpected value.
>
>eg.
>STEP -
>gnHandle = SQLCONNECT(gcDSN,'MRPSA')
>
>Displayed login dialog, then i change user name 'sa' and blank password. it executed properly.
>
>Then i use
>=SQLGETPROP(gnHandle,'UserID')
>It is giving 'MRPSA'
>Here i am expecting 'sa'???????????????????
>
>=SQLGETPROP(gnHandle,'Password')
>It is blank password.
>
>=SQLGETPROP(gnHandle,'ConnectString')
>It is giving proper valus as i expected.
>
>
>TIA
>Ajay Mishra
--
--
Aashish Sharma
Tele Nos: +1-201-490-5405
Mobile: +91-9821053938
E-Mail:
aashish@aashishsharma.com
write2aashish@gmail.com

You better believe in yourself... if you don't, who else will ?
TODAY is a gift, that's why it's called PRESENT
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform