Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Outlook / Programming VBA / August 2006

Tip: Looking for answers? Try searching our database.

Rule that runs an script that should call an SQL Server sentence

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Carlos - 26 Aug 2006 21:12 GMT
Hello all, I made an script that runs with a rule and I would like to get
database info from SQL server DB (not from an Access DB). I've added
Microsoft DAO 3.6 Object LIvary reference to be able to get the info.

So I wrote the following data but without thinking that will not work
because it does not say anything about the server and username/password
info...

Maybe someone can explain me wich are the options or correct functions in
order to get info from an SQL server DAtabase.

Thanks in advance
Carlos

Dim db As Database
Dim table As Recordset
Set db = OpenDatabase("QualitySurvey")
Set table = BDD.OpenRecordset("Test")
table.OpenRecordset ("SELECT * FROM Autos WHERE Patente = 589975")
Michael Bauer [MVP - Outlook] - 28 Aug 2006 05:43 GMT
Am Sat, 26 Aug 2006 13:12:02 -0700 schrieb Carlos:

SQLServer know two ways of authentication. Please google for
"connectionstring sqlserver dao" or ask in an SQLServer related group.

Signature

Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
 -- www.VBOffice.net --

> Hello all, I made an script that runs with a rule and I would like to get
> database info from SQL server DB (not from an Access DB). I've added
[quoted text clipped - 15 lines]
> Set table = BDD.OpenRecordset("Test")
> table.OpenRecordset ("SELECT * FROM Autos WHERE Patente = 589975")
Carlos - 29 Aug 2006 07:25 GMT
Thanks for the tip...

Rgds,

> Am Sat, 26 Aug 2006 13:12:02 -0700 schrieb Carlos:
>
[quoted text clipped - 20 lines]
> > Set table = BDD.OpenRecordset("Test")
> > table.OpenRecordset ("SELECT * FROM Autos WHERE Patente = 589975")
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.