473,480 Members | 2,157 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

table name as a column datatype

20 New Member
Hello all

Recently I was playing with column data types and found that you can have a table name as the column's datatype although it looks like an "array object". For ex. if I have table1 and table2, it seems something like the following is possible..

create table table2(id bigint,table1[]);

Am just interested in what are the situations one would go for such an option? Any example or a direction for reading on this topic would be much appreciated.

Thanks a lot.
Jun 14 '08 #1
1 2968
pravinasp
20 New Member
Hello all,

My bad, i should have mentioned it, am working on postgres. If anyone has used table as a columns datatype I would be glad to hear from you if you could tell me when to go for such an option.


Cheers
Jul 14 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

1
21237
by: Bruce | last post by:
Hi, I want to change the datatype of an existing column from char to varbinary. When I run the "Alter Table" statement, I get the following error message - Disallowed implicit conversion...
3
2173
by: Martin Mrazek | last post by:
Hi, I have tables named like ag97a027, ag98a027, ... where 97 and 98 is from year 1997, 1998 and a027 is just specification of product type. I need carry out repeated operataions over these...
2
3586
by: charles leviton | last post by:
Hi all, Just trying to get a feel here. THe shop I work at insists on prefixing all column names with the table name, so it is order_id in the ORDER table and Customer_id in the CUSTOMER table. ...
1
3520
by: keithb | last post by:
The following code sets a DataTable column DataType to "String" column.DataType = System.Type.GetType("System.String"); What is the corresponding statement when the data type is boolean? I...
0
2054
by: Joe Meng | last post by:
Greetings, I've seen this question asked and answered here, just not completely yet. I'm wondering how to use a column value as a table name in another query. So far it's looking like you must...
4
1918
by: ahmed222too | last post by:
when i use this quary to add new column, the engine reject the table name and focus on (-) in the table name alter table AH10-A1*1*1-101006 add column sss note: this schema of table name...
5
1772
by: Jim in Arizona | last post by:
I built a webpage using vb.net (.net 2.0) that creates a form letter. This letter pulls data from a database. Although I populate the address with the person's full name, which comes from the name...
4
1823
by: MGM | last post by:
Hello everyone, I once again have a problem :p I need to write a query to get the total amount of rows in a table. Problem is, the table name is dynamic and part of its value is stored in...
1
2759
by: pulavarthipraveen | last post by:
When I tried to change the datatype of the column through "Alter table tablename Alter column columnname Newdatatype" query it's is throw the error below: "The index 'IndexName' is dependent on...
0
7055
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7060
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
6760
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7022
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
5365
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,...
0
4501
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
1311
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
572
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
206
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.