473,396 Members | 1,967 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Store program EXE in table?

HC
Hello, Folks. I am not sure if this can be done (and a brief search of
this group didn't yield any results that I thought would do the trick)
but if it can be done it would make my life easier so here goes.

First, what I am trying to accomplish is to make a program I've written
automatically update itself if there is a newer version on the network.
Second, my application runs on one or more computers at many
geographically separated locations. I have remote control software
that enables me to remotely update and troubleshoot my application but
I since I have to pay for this access per computer I don't have the
ability to control each and every computer that runs my software (for
those clients with more than one computer that uses my software).

Third, my application uses as its data storage system MSDE 2000 (with
current service pack).

Fourth, my users are not technical people and I want to rely on them as
little as possible.

Fifth, not all of the workstations are Internet enabled or connected,
so having the application check a website for an update is not
feasible.

Finally, to bring those different pieces together, what I want to be
able to do is connect to and control the "server" (the computer with
MSDE installed on it) and store in the database what the current
version number is along with the current program files. Then, when the
application launches, it will check that stored version number against
it's own version number to determine if there is a newer version
available. If there is a newer version available I want it to update
itself (that workstation) by retrieving that newer software from the
database. I want to avoid file sharing because it's problematic and
since I already have SQL Server (MSDE) running on the network I'd like
to use that.

Is there some way that I can either a) store my program files (one EXE
approximately 5MB in size and one OCX approximately 250KB in size) in a
table to be retrieved by my application so it can update itself or b) a
way to get SQL Server (MSDE) to read a file locally on the server and
return it to my application just like it would any recordset so I could
just tell it where the file was and let it read it from whichever
folder it's stored in?

I've looked at making a column of datatype Binary, and perhaps that's
the way I'll go (re-creating the field to the correct size each time I
do an update or perhaps making it really big so I don't have to worry
about the size). But I thought I'd ask around first since this isn't
anything I know much about.

Thank you for your time and help.

--HC

Jun 8 '06 #1
2 2476
HC wrote:
Hello, Folks. I am not sure if this can be done (and a brief search of
this group didn't yield any results that I thought would do the trick)
but if it can be done it would make my life easier so here goes.

First, what I am trying to accomplish is to make a program I've written
automatically update itself if there is a newer version on the network.
Second, my application runs on one or more computers at many
geographically separated locations. I have remote control software
that enables me to remotely update and troubleshoot my application but
I since I have to pay for this access per computer I don't have the
ability to control each and every computer that runs my software (for
those clients with more than one computer that uses my software).

Third, my application uses as its data storage system MSDE 2000 (with
current service pack).

Fourth, my users are not technical people and I want to rely on them as
little as possible.

Fifth, not all of the workstations are Internet enabled or connected,
so having the application check a website for an update is not
feasible.

Finally, to bring those different pieces together, what I want to be
able to do is connect to and control the "server" (the computer with
MSDE installed on it) and store in the database what the current
version number is along with the current program files. Then, when the
application launches, it will check that stored version number against
it's own version number to determine if there is a newer version
available. If there is a newer version available I want it to update
itself (that workstation) by retrieving that newer software from the
database. I want to avoid file sharing because it's problematic and
since I already have SQL Server (MSDE) running on the network I'd like
to use that.

Is there some way that I can either a) store my program files (one EXE
approximately 5MB in size and one OCX approximately 250KB in size) in a
table to be retrieved by my application so it can update itself or b) a
way to get SQL Server (MSDE) to read a file locally on the server and
return it to my application just like it would any recordset so I could
just tell it where the file was and let it read it from whichever
folder it's stored in?

I've looked at making a column of datatype Binary, and perhaps that's
the way I'll go (re-creating the field to the correct size each time I
do an update or perhaps making it really big so I don't have to worry
about the size). But I thought I'd ask around first since this isn't
anything I know much about.

Thank you for your time and help.

--HC


You could use IMAGE (SQL Server 2000) or VARBINARY(MAX) (SQL Server
2005).

Check out ClickOnce:
http://msdn.microsoft.com/netframewo...res/clickonce/

ClickOnce may be the solurtion for those that are online. For those
that aren't, I don't understand why you can't deploy the installer to a
file path and have the application execute it from there - seems like a
lot less trouble to me.

--
David Portas, SQL Server MVP

Whenever possible please post enough code to reproduce your problem.
Including CREATE TABLE and INSERT statements usually helps.
State what version of SQL Server you are using and specify the content
of any error messages.

SQL Server Books Online:
http://msdn2.microsoft.com/library/m...S,SQL.90).aspx
--

Jun 8 '06 #2
HC (hb*****@gte.net) writes:
Is there some way that I can either a) store my program files (one EXE
approximately 5MB in size and one OCX approximately 250KB in size) in a
table to be retrieved by my application so it can update itself or b) a
way to get SQL Server (MSDE) to read a file locally on the server and
return it to my application just like it would any recordset so I could
just tell it where the file was and let it read it from whichever
folder it's stored in?
No, SQL Server cannot (easily) read a file from the network and pass it on
the server. After all, SQL Server is a database server, not a file server.
I've looked at making a column of datatype Binary, and perhaps that's
the way I'll go (re-creating the field to the correct size each time I
do an update or perhaps making it really big so I don't have to worry
about the size). But I thought I'd ask around first since this isn't
anything I know much about.


You could have to use the image data type, as binary is restricted to
8000 bytes. The image data type is fairly kludgy to work with.

Overall, while this could be made working, this does not sound like a
good design to me. A solution that involves only the file system is a
lot better in the long run, although there appears to be some hassle
with it right now. Yet another alternative would be to write your own
server app that accepts a connection from the application, and sends
a binary in reply if there is a newer one.
--
Erland Sommarskog, SQL Server MVP, es****@sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pro...ads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinf...ons/books.mspx
Jun 8 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: F. Da Costa | last post by:
Hi, Does anybody know why IE5+ does *not* honour array objects (like a table) across a session? Example: Frame A contains a var tableVar which is set via form Frame B (on init) using...
1
by: Patrick | last post by:
I'm trying to create a link from Access 2003 to an Exchange 2000 Public Folder called "WMContacts" I choose File => Get External Data=> Link Tables. I choose Exchange() and the wizard give me the...
1
by: Hugo Lefevre | last post by:
Dear, I have a problem : I have a database which contains my data of hardware. The Id is a varchar and I want at my filling form that my user know which is the last one. So I made a store...
11
by: hoopsho | last post by:
Hi Everyone, I am trying to write a program that does a few things very fast and with efficient use of memory... a) I need to parse a space-delimited file that is really large, upwards fo a...
1
by: rdemyan via AccessMonster.com | last post by:
I'm trying to implement a licensing scheme. There are three types of licenses: Trial - good for 30 to 60 days Interim - good for 1 year Fully Paid - no expiration Everything is working fine...
10
by: Paul Cheetham | last post by:
Hi, I am developing an application that needs to store some machine-specific settings. The application is going to be published on the network in order to keep the clients on the latest version....
11
by: c676228 | last post by:
Hi everyone, I am just wodering in asp program, if there is anybody writing store procedure for inserting data into database since there are so many parameters need to be passed into store...
4
by: Dave | last post by:
I have some data values that will will rarely change over the life of the program. I don't think it is wise to save it in a database. Is it ok to save them in Properties.Settings if I have many...
6
by: snsanju | last post by:
Hi, I am trying to write a program to fetch the HTML table values and store in the array as they are in the table. <table> <tr><td>value1</td><td>value2</td><td>value3</td></tr>...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.