|
Thanks! You have clarified a number of things that always confused me. Appreciate it.
|
|
|
|
|
I think you are taking normalization too far.
Dont concern yourself as to storing addresses more than once.
The address in each table I create is usually just an attribute.
This means I would have an address for each company and person.
Same with phone.
Although it is possible that a company and person might have the same address or phone it isnt important that they are the same physical record in some table.
"Owning" a company - you work for it.
I see three tables in your entire post.
companies -> companies_people <- people
This way people can be part of a company or NOT.
Company table would have a main phone, fax etc and address(s)
People would have their own ID, address and phone.
YES you might have duplicated data but it certainly could not be called a transitive dependancy.
http://www.jasncab.com/huberblog :: Jason Huber
|
|
|
|
|
Thanks. I agree that the database does not heve to be normalised to the smallest detail as it would effect perfomance and make the queries more complex. But like Colin pointed out:
In otherwords, design the model as normalised as possible, then denormalise it afterwards if you find performance problems.
I want to take this one step further - not denormalise it but use its structure to dynamically create only the required tables/relations.
It might be a good idea to kind of explain what I am trying to do. The model I am trying to build will not actually contain any data, but its structure will be used (schema - which could be in xml format) to generate a database that will only contain the tables and structure required by the user. For example: User may want to store a telephone list - name and all the related phone numbers - so I would pick only the necessary tables (person,phonegroup,phone) and their relationships from the schema and create the database. Then he might want another DB to have all company info...
So the idea is to "morph". For this I need all the conceivable possibility for the schema. Now I know this may not be the best approach for this kind of application and suggestions are welcome.
Thanks!
|
|
|
|
|
HAs anybody out here used the Oracle 10G. I want to know the feasibility related to the this version of oracle and the ASP.NET compatibility with it.
|
|
|
|
|
I use 10G regularly in two environments installed on Windows 2003.
Works just fine. ASP.NET and the driver you currently use will work fine.
http://www.jasncab.com/huberblog :: Jason Huber
|
|
|
|
|
Hi
i have a db on sqlserver 2000;
How i can export tables and relations to a access db ?
I need it cause access has db documentor;
Thanks;
|
|
|
|
|
1) There are lots of good documentation tools for sql. Better yet, try the metadata server in sql.
2) I suppose you could just link the access table to sql server.
|
|
|
|
|
Hi,
You can do it by following the below steps:
1. Create a System DSN, giving the connectivity to the SQL Server database, which u want to import.
2. Create a new Acesss Databe(.mdb)
3. Goto files,select Get External Data -> Import.
4. Now from the file types, select the ODBC databases and locate the dsn whihc u have created.
5. Choose the tables which u want to import and click Ok.
This will import all the selected SQl tables to your Acess databse.
Indus_v
|
|
|
|
|
I have not relationship!!!!
|
|
|
|
|
Hi,
Although i have successfully implemented the Microsoft Data Access Application Blocks with Oracle 8i but i am suspicious reagrding the DAAB compatibility with Oracle 10G.
If anybody has used the DAAB with the Oracle 10g or has the knowledge regarding the same, kindly share it and help me our.
~Indus_v
|
|
|
|
|
hello
I want to use multiple database .They may be on different server?
can you help me about the problems that i will have?can you suggest one article?
|
|
|
|
|
Hi,
You can go for the Database Access Application Blocks, if you want to use multiple databases simultaneously in a single applications.
You can got to the Microsoft site for this:
ttp://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnpag2/html/daab.asp
Indus_v
|
|
|
|
|
|
First, in order to answer your question well we need to know what the database technology is and what it will be communicating with. The rest of the answer assumes SQL Server 2000 and .NET
If you are having the databases communicate with each other you can set up linked servers and then refer to them using the 4 part table notation like this:
[server].[database].[schema].[table]
[server].[database].[schema].[view]
[server].[database].[schema].[stored_procedure]
If you are communicating with .NET you can use the normal provider mechanism and open separate connections to each database you need. You can have multiple connections to multiple servers if your application requires it. Your ConnectionString will point to the relevant database and server.
If you need to connect to both databases through one SqlConnection you can link the servers and then connect to the server that has the link (this will be the local server, the server that has been linked to is the remote server). You can then use the 4 part names, see above, to work with the correct data on the correct server.
NOTE: If you are using data on the local server you don't need to use the full 4 part name, however, I've found that when dealing with linked servers that using the 4 part name always reduces ambiguity and makes tracking down bugs easier as I'm not left wondering what connection something was running on and which server is local and which is remote.
Does this help?
My: Blog | Photos | Next SQL Presentation
WDevs.com - Open Source Code Hosting, Blogs, FTP, Mail and More
|
|
|
|
|
I beleave you shoud create a linked server between database.
select article_id from samcpd05.online.dbo.dimensao_produto
left join samcpd29.onlinehist.dbo.produtos on ....
samcpd29 = server
onlinehist = database
if you need more examples my e-mail is: sadmilson@terra.com.br
|
|
|
|
|
I am running Access 2002.
I want to do something similar to the following:
SELECT * FROM tb1
LEFT JOIN
( SELECT tb2.ID AS tb2_ID, tb2.Author AS tb2_Author, tb2.Address AS tb3_Address
FROM tb2, tb3
WHERE tb2.Address = tb3.ID ) AS sb1
ON sb1.tb2_ID = tb1.Author
How can I do that?
----
to die is gain
|
|
|
|
|
Yes you can really close to what you have already.
You are joining from the sub out. and that should be ok.
Its called a correlated sub query..
The problem is I dont see your point in this particular example. It could be that I am just missing it.
But really you could just rewrite your example
SELECT tb1.namedfields, AS tb2_ID, tb2.Author AS tb2_Author, tb2.Address AS tb3_Address FROM tb1 LEFT JOIN tb2.author ON FROM tb2.id = tb1.id left join tb3 on tb2.Address = tb3.ID
http://www.jasncab.com/huberblog :: Jason Huber
|
|
|
|
|
Hi. I have some questions for you:
How the field, which has type "counter", can be read/write (in DB Access)?
How the program can get the unique number for this key-field (in DB Access)?
How the field, which has type "MEMO", can be read/write (in DB Access)?
|
|
|
|
|
Hi
How i can read rows From database DB1 -> Table T1 and insert rows into DB2->Table T2 ?
Thanks
|
|
|
|
|
|
This exemple I'm using SQL Server and reading Informix Database... If you are using SQL Server try "OpenQuery".
SELECT cd_EmpresaOPTV, dtfechamento
FROM
OpenQuery(infempfk, 'select E.cd_EmpresaOPTV, F.dtfechamento from geempresa E, fecctbilunid F where E.id_empresa=F.idempgrp And F.idmodulo=19 and E.cd_EmpresaOPTV is not null ')
|
|
|
|
|
If you using only Sql Server:
insert into samcpd05.online.dbo.invent
select name,phone from samcpd29.onlinehist.dbo.invent_hist
In this example we have two databases in two servers samcpd05 and samcpd29...
|
|
|
|
|
Dear all,
I am using FireBird .Net Adapter and able to create FB database using below code (C#):
Hashtable parameters = new Hashtable();
parameters.Add("User", UserName);
parameters.Add("Password", Password);
parameters.Add("Database", @FilePath);
parameters.Add("ServerType", 1);
FbConnection.CreateDatabase(parameters);
After creating the database, I am able to open it using FBConnection for the first time. But after that, whenever I open the database, I am getting this error:
internal gds software consistency check (Internal error code (165))
Any idea? Thanks.
regards,
vic
|
|
|
|
|
select (1/2)
How to get the result 0.5? Thanks
<italic>Work hard, Work effectively.
|
|
|
|
|