Hello All

Can anyone tell me how to combine primary keys into one single key

Previously, my database has just one primary key (PK). But the database has gone a change with 3 new fields acting as PK.

I am using SQL like –

SELECT primary_id as pk,
               secondary_field1,
               secondary_field2,
FROM schema.table
         WHERE primary_id = {0};

Where the primary_id is dynamically filled.

But Now I have following SQL –

SELECT secondary_field1,
  secondary_field2,
        secondary_field3 as pk,
secondary_field4,
secondary_field5
FROM schema.table WHERE secondary_field1= {0} and secondary_field2= {0} secondary_field3= {0};

How can I combine the above 3 PK’s (Char Datatype) into one PK (Integer Datatype). There is no EJB, it's simple MVC
Your suggestion is highly appreciated