Page 1 of 1

Microsoft Access to web page. How?

Posted: Mon 23 Aug 2010 5:17 pm
by RayProudfoot
Having been inspired by Synewave's web pages I used my Access skills to create the following form. It gets its data from 44 separate queries but the results are displayed in less than 2 seconds.
Weather.jpg
How can this be achieved using web-compatible code? At this stage I'm only researching how it can be achieved rather than wanting to get stuck in to coding it. I doubt I have the skills anyway.

I imported dayfile.txt into an Access database to achieve the above.

Re: Microsoft Access to web page. How?

Posted: Mon 23 Aug 2010 5:27 pm
by steve
You can do it with PHP as described here: http://www.w3schools.com/php/php_db_odbc.asp

Re: Microsoft Access to web page. How?

Posted: Mon 23 Aug 2010 5:42 pm
by RayProudfoot
steve wrote:You can do it with PHP as described here: http://www.w3schools.com/php/php_db_odbc.asp
Brilliant, thanks Steve.

The following is the SQL for the all-time max temperature. I presume I can just paste this into the $sql parameter and it will run?

SELECT TOP 1 Max(MaxTemp) AS [All-Time Max Temp], MaxTempTime AS [Time], Date
FROM Dayfile
GROUP BY MaxTempTime, Date
ORDER BY Max(MaxTemp) DESC;

Re: Microsoft Access to web page. How?

Posted: Mon 23 Aug 2010 6:00 pm
by steve
RayProudfoot wrote:The following is the SQL for the all-time max temperature. I presume I can just paste this into the $sql parameter and it will run?
Yes, it should do. You'll have to change the other bits that refer to Company Name etc to match your names, of course.

The bit I'm not sure about is how you create a DSN on your web server...

There's info here about DSN-less connections: http://phplens.com/phpeverywhere/node/view/9#dsnless

Re: Microsoft Access to web page. How?

Posted: Mon 23 Aug 2010 6:10 pm
by RayProudfoot
Thanks Steve. DAJ is hosting my website so if you're reading this David could you confirm if it's possible to create a DSN please?