-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: Selectierte Spalten im UNION-Statement kennzeichnen
PostPosted: Wed Aug 09, 2006 10:01 am 
Regular
Regular

Joined: Mon May 22, 2006 8:32 am
Posts: 67
Hi,

ich möchte ein Union-Statement zusammensetzen, wo ich die Reihen kennzeiche aus welcher Abfrage sie entsprungen sind:
Code:
select
         persacct.code,
         emppersacct.emp.empSk,
         emppersacct.nomDate,
         emppersacct.updTs,
         tcslogin.firstName,
         tcslogin.lastName,
         emppersacct.mi,
         'F'
      from
         EmpPersAcct emppersacct
         left join emppersacct.tcsLogin tcslogin
         inner join emppersacct.persAcct persacct
         
      where
         persacct.code='URLAUB'
         and
         emppersacct.emp.empSk=-979941237706
      
      union
         select
            persacct.code,
            sprstatehrses.id.empSk,
            sprstatehrses.id.nomDate,
            sprstatehrses.updTs,
            emp.firstName,
            emp.lastName,
            sprstatehrses.mi,
            'T'
         from
               PersAcct
                        ...


Wie baue ich das ganze in meinem Java code ein? Mit dem HQE der HibernateTools ist das kein Problem...?

_________________
Regards,
ak


Please don't forgat to rate


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.