[GENERAL] thank you

2013-08-19 Thread Basavaraj
Ya i got the answer here is the code


SELECT *
FROM (SELECT row_number() over(), * FROM employee) t1
right outer JOIN (SELECT row_number() over(), * FROM managers) t2 on
t1.row_number=t2.row_number



Thank you



--
View this message in context: 
http://postgresql.1045698.n5.nabble.com/Here-is-my-problem-tp5766954p5767787.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] need help

2013-08-18 Thread Basavaraj
thanks for ur help,this was the requirement which assigned for us,so i had to
ask even though we are having many options.thanks again



--
View this message in context: 
http://postgresql.1045698.n5.nabble.com/Here-is-my-problem-tp5766954p5767778.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] need help

2013-08-16 Thread Basavaraj
i have two unrelated tables as their is no common column to apply joins or
anything, so i want to join those tables using simple query(only two tables
should be used and no common table) can you pls help me out how to do that.
I am new user to postgres

this is table format

table1 table2

name| address|email| mobileNo|firstname|lastName|
--  --
abcsome1   mail1   1234564|def | 
: :
: :
  :
:
:5 records  10 records


finally the result shoule be

name| address|email|mobileNo|firstname|lastName|
--
abc   some1mail1   1234564 def  xyz

5 records   |   10 records

   |

Very thankful for solution





--
View this message in context: 
http://postgresql.1045698.n5.nabble.com/Here-is-my-problem-tp5766954p5767611.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] Here is my problem

2013-08-09 Thread Basavaraj
Now i want to insert data to the table
the format should be

id | marks
--
1  |50
1  |30
1  |30


2 |...


the actual query is 

insert into table(id,marks) values(1,unnest(array[marks])) 


But we should not use array and unnest but i want in this format

pls help..



--
View this message in context: 
http://postgresql.1045698.n5.nabble.com/Here-is-my-problem-tp5766954.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general