Link to home
Start Free TrialLog in
Avatar of hidrau
hidrauFlag for Brazil

asked on

How can I open a Sql file and run all the script in it?

Hello guys,

I'd like if it is possible to open a sql file with sql scripts on it and run all the code.

If so, how could I do this in access?

thanks
Alex
Avatar of Kelvin Sparks
Kelvin Sparks
Flag of New Zealand image

Is it possible to put all of the script into a stored procedure. You could then execute the stored procedure via ADODB or even via a pass through query.

Either that or setup some form of batch job to execute it.


Kelvin
Avatar of hidrau

ASKER

in access?
The sql file would have to be saved into sql server - or Oracle as stored procs..  (I assume that is what the sql file is for).

With sql server you can use a batch job to run a sql file.

I'm am not aware of ways to run .sql files against an Access database itself (if that is what your data is stored in).

You really need to give a little more detail of what your setup is - where the data is stored and so on.


Kelvin
(I assume that is what the sql file is for).
In that case I would request attention and ask moderator to add SQL Server or/and other databases as part of the topics.
Can you please confirm that SQL Server is the back end database - or advise if something else.
Avatar of hidrau

ASKER

Hello people,

I need to run the sql file in Access database.

Not in Microsoft SQL. Sorry for my lack of information
ASKER CERTIFIED SOLUTION
Avatar of Gustav Brock
Gustav Brock
Flag of Denmark image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of hidrau

ASKER

Thanks a lot
It helped me very very much
You are welcome!

/gustav