Developer forum

Forum » Development » Reusing database code for sql

Reusing database code for sql


Reply
If i am building a module that i want to work wether the website is using an access database og an SQL database, then how do I make sure that the code will automatically get the data from the right place?



Is the database string simply ignored so that the tables are just fetched from a common SQL database instead?

Replies

 
Reply
Correct. The Database argument in e.g. Database.GetDataReader is ignored when running SQL server. It just queries the common database.

 

You must be logged in to post in the forum