Technical Help & Discussion > Website Design & Programming

delphi ado database connection

<< < (2/3) > >>

sam:
ok delphi 7.0 - gosh havent used delphi in a long time... umm needs some thought. Does delphi allow you to directly run sql commands or do you have to use your own?

Ok I have racked my brain a little and I think you might want to take a look at this page: http://delphi.about.com/od/database/l/aa050101a.htm - tell me if it is off use. Do you have any experience with sql?

Another interesting tool which might be useful is: http://www-106.ibm.com/developerworks/db2/library/techarticle/0210swart/0210swart.html

clarke:
well i figured delphi 7.0 does support sql commands.it should work even better than visual basic but am syet to figure it out nowonder i need some assistance.On the other hand maybe i can get someone can tell me the best way to make an application and connect to the database which is of ms sql server.I have used bde engine but the problem is that once the application is installed then you have to install in each machine which i think is cumbersome.i want an application where once am through i jus give it to the user and goes on with using it and found ado is independent so if there is anyway other than ado then please someone help me out.
On sql am familiar with it and thats why i want to use it as my backend.

my biggest problem is connecting to the database....well ave tried using the getconnection() and setconnection() adodb class methods though am geting no errors i still seem not to get connected.i also want to capture the error when my aplication cant establish the connection to the sql server.....then we can address the database records update and deletion :shock:  :shock:  :shock:

sam:
Ok.

umm I am not a delphi programmer so can't help you too much with the inbuilt classes. I am also not that familiar with ms sql.. only use it when forced.. and that was a one time deal! Sorry.

I may have found a useful site for you. Thinking back to when I used it before I remember looking at: http://www.functionx.com/sqlserver/Lesson07.htm

- down the bottom of the page is a section all about delphi... might have the answer you need.

One thing - surely all you need for your connection string is:


--- Code: ---Server=hostname;
 Database=databaseName;
 User ID=sqlServerUserid;
 Password=sqlServerPassword
--- End code ---


or if you are using an NT


--- Code: --- Server=hostname;
 Database=databaseName;
 User ID=windowsDomain\windowsUserid;
 Password=windowsPassword;
 Integrated Security=SSPI
--- End code ---

clarke:
well this code thing has got the better of me cant seem to get the connection right.i'll do it without code but the error especially is a nuiscance so someone help...sam thanks alot for the assistance keep it up

sam:
i am just sorry i cant really help you any more. i will ask around and see if i know anyone who uses this combination.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version