Once you have the application up and running configuring the app to access the database is something you should have no need to do again really. However should you require to either change the database location, alter the credentials for access or simply align with any password change, these notes guide you on what you should carry out. The steps are repeated from the Horse Racing Application page and to do so now we are looking at Points 5,6,7, & 8.
5. This is server where you have installed the SQL you wish to use. If it is the same PC or server as the application is then enter localhost
6. This is the name of the database as setup in SQL. If you go the start of this guide you will see that it is called RHFB for these instructions.
7. As part of setting up SQL you should have created the sa account. Use this here.
8. Similarly the Password used in setting up the sa account would be entered here.
9. To ensure the details are right then hit the Click to Test button. Provided this is successful then the App will communicate correctly with the Database.
This section is not about the app but is a general guide for those not familiar with MS SQL and it is well worth learning about this product, to get more from it.
The Management Console is great for doing some basic tasks.
You should have installed this as part of the SQL installation guide I did.
Start this and use credentials that have full access, either the SA (SQL account) or a Windows one, if you did Mixed Mode Authentication.
I would do this after every time the App has been run to update the database. I also do a new backup every time because it’s just the way I work. There are other ways but again there’s a wealth of information out there.
Go to the Databases area on the left hand side and expand it so you can see your database listed.
Right Click, select Tasks and choose the Back Up… option
From the next Screen clear the existing backup details by the Remove button and create a new one by clicking Add…
Either enter a name to call your backup at the end of the line after backup\ or choose a location name of your own choosing.
i.e. C:\Program Files\Microsoft SQL Server\MSSQL12.SQLEXPRESS\MSSQL\Backup\161022.bak
I would use the .bak at the end as good practice. The format I like to use here is yymmdd.bak
Click OK and OK again to start the backup. This will end with a successful message – normally.
I am aware there are better ways to Backup the database but I wish to keep this as simple as possible for those who have little knowledge of MS SQL.
Simple Query of the tables.
With the RHFB database selected and showing in the highlighted area below, click on New Query
Something straight forward is listing a set number of races from the Main table. Here with the text in place, clicking the !Execute button will return the 100,000 races and all the columns as well. In order from the first record at the top
The output in the bottom pane
Obviously this is just basic information intended for someone with little experience or knowledge of SQL. There is a lot of information on writing queries and maximizing the amount of benefit from databases on the internet.
There are also utilities form third parties that are designed to help query the data, including Free ones which maybe great to get you started.
If you find one that works well with the data and the database you use please follow this Contact Us link and will look at passing on to RHFB users for their use.
Simply put RacingFormBook will help inform and assist you to find winners and enjoyment from Horse Racing. Provide a unique rating method and racing results data.
To further anyone’s ambition to use the information, whether this is as a point of reference, a repository for their ratings or to enable the research into racing systems.