Can Excel Work like Access

B

Bostick73

My Question is....Can Excel Work Like Access

I need two people to be able to enter data into the same workbook a
one time. I do not want to deal with the hassle of access and the fac
that i do not have access on one computer, limits my options.

thanks for any help you can send my way
 
P

PDUK1

In essence the answer to your question is Yes. Excel can work LIKE Access,
however you need to remember that Access is a relational database management
system and Excel is a spreadsheet environment or known as a flat database.

Your question does not offer a great deal to be able to make a good
decision, however I have developed working models using excel functioning
well wthin a shared environment and so long as you understand that the first
person to open the system will 'lock' the other person from making any
changes, you will be fine. Excel will tell the users this.

There is a great deal that can be acheived using Excel, its a powerful tool,
but chose carefully and good luck.

Regards

Peter
 
J

Jamie Collins

PDUK1 said:
In essence the answer to your question is Yes. Excel can work LIKE Access,
however you need to remember that Access is a relational database management
system and Excel is a spreadsheet environment or known as a flat database.

To make a pedantic point, an .mdb file (which Windows Explorer tells
me is a 'Microsoft Office Access Application') is just a flat file but
to be useful must be accessed using Jet data engine, which is
'relational'.

One may access the data in an .xls using the very same Jet data
engine, so Excel can work a *lot* like MS Access. However, an .xls may
also be accessed via the Excel UI of course, so many of the usual Jet
features, such as strict data typing, constraints, indexes etc, must
be forsaken or reproduced for the native Excel environment

If you know what you are doing e.g. you speak SQL DDL or can
manipulate the objects in the ADOX library, you can create a fully
working Jet .mdb database. Plus the .mdb file format is freely
distributable, AFAIK. So, not having the MS Access app is no excuse
<g>. Here's a quick example:

Sub Test2()

Dim Cat As Object
Dim rs As Object
Dim strConJet As String
Dim strSql1 As String
Dim strSql2 As String

' Amend the following constants to suit
Const PATH As String = "" & _
"C:\"
Const FILENAME_JET As String = "" & _
"New_Jet_DB.mdb"

' Do not amend following constants
Const CONN_STRING_JET As String = "" & _
"Provider=Microsoft.Jet.OLEDB.4.0;" & _
"Data Source=<PATH><FILENAME>"

' Build connection string
strConJet = CONN_STRING_JET
strConJet = Replace(strConJet, "<PATH>", PATH)
strConJet = Replace(strConJet, "<FILENAME>", FILENAME_JET)

' Build sql statements
strSql1 = ""
strSql1 = strSql1 & "CREATE TABLE Pilots ("
strSql1 = strSql1 & " ID INTEGER NOT NULL PRIMARY KEY,"
strSql1 = strSql1 & " lname VARCHAR(35) NOT NULL,"
strSql1 = strSql1 & " fname VARCHAR(35) NOT NULL,"
strSql1 = strSql1 & " mname VARCHAR(35) NOT NULL"
strSql1 = strSql1 & " DEFAULT '{{NA}}'"
strSql1 = strSql1 & ");"

strSql2 = ""
strSql2 = strSql2 & "SELECT ID, lname, fname"
strSql2 = strSql2 & " FROM Pilots;"

' Create new Jet database
Set Cat = CreateObject("ADOX.Catalog")
Cat.CREATE strConJet

With Cat.ActiveConnection

' Create tables
.Execute strSql1

' Create some sample data
.Execute "INSERT INTO Pilots (ID, lname, fname)" & _
" VALUES (1, 'Livehulas', 'A')"
.Execute "INSERT INTO Pilots (ID, lname, fname)" & _
" VALUES (2, 'Katewudes', 'B')"
.Execute "INSERT INTO Pilots (ID, lname, fname)" & _
" VALUES (3, 'Hevitoxic', 'C')"
.Execute "INSERT INTO Pilots (ID, lname, fname)" & _
" VALUES (4, 'Norarules', 'D')"

' Query data
Set rs = .Execute(strSql2)
MsgBox rs.GetString

End With

End Sub


Jamie.

--
 
P

PDUK1

I did say 'in essence Yes'. I didn't feel I needed to write a whole article.
Overkil!!

Regards

Peter
 
J

Jamie Collins

PDUK1 said:
I did say 'in essence Yes'. I didn't feel I needed to write a whole article.
Overkil!!

I did say, 'To make a pedantic point...' Overreaction! <g>

Jamie.

--
 
A

ame12

You can also share over the web using a publishing feature - se
http://badblue.com/helpxls.htm . This will expose the workbook over th
web such that users only need browsers to view and modify. It is freel
triable and appears to be a good solution to getting ASP page/Acces
type functionality with a minimum of time and effort
 
Top