Query: How can I combine several fields to one field

I have this Query:
SELECT T0.[Cardname], T1.[Street], T1.[ZipCode], T1.[City], T1.[Country] FROM OCRD T0  INNER JOIN CRD1 T1 ON T0.CardCode = T1.CardCode WHERE T0.[CardName] Like '%[%0]%'
I have two questions on it:
1)   Now I get two lines with the same results because each BusinessPartner has a billing-address and a shipment-address. How can I get one result with only the shipment-address fields.
2)   When I run this query as a Formatted Search on an addressfield I only get the first field (= CardName) in the Addressfield. How can I get Cardname, Street, Zipcode, City and Country in ONE field (ic Address2)?

Answer -1
T1.AdresType = 'S' for ship to address
T1.AdresType = 'B' for bill to address
SELECT T0.Cardname, T1.Street, T1.ZipCode, T1.City, T1.Country FROM OCRD T0 INNER JOIN CRD1 T1 ON T0.CardCode = T1.CardCode WHERE T0.CardName Like '%%[%0]%' AND T1.AdresType = 'S'
Answer-2
Modify this query
Select T1.Address + Char(12) + T1.ZipCode + Char(12) + T1.Street + Char(12) + T1.Block +Char(12) + T1.City + Char(12) + T1.County + Char(12) + T1.ZipCode
FROM CRD1 T1 INNER JOIN OCRD T0 ON T0.CardCode = T1.CardCode
Where T1.AdresType='S'
Hope this solves problem.
Edited by: Jeyakanthan A on May 28, 2009 1:45 PM

Similar Messages

  • How can i combine several JFrame into one

    I has several JFrames running with different tasks eg. using
    various eventlistener and runnable. but when i try to combine all
    these JFrames into one, compiling is ok but running always has
    missing information. pls kindly advise the easiest method to use in
    combining.
    In addition, how can i display the JFrame in other
    location instead of top left corner (starting point)?

    yup, i used these layout FlowLayout, GridLayout and BorderLayout for
    each of my JFrame and JPanel.

  • HT1229 I have several iPhoto libraries. How can I combine them to make one?e new library?

    I have several iPhoto libraries. How can I combine them to make one?

    iPhoto Library Manager - http://www.fatcatsoftware.com/iplm/ - 
    or the current version of Aperture can merge libaries from the current version of iPhoto
    LN

  • I have photos I want to group together in one album, but can't do this because some may have the same number. How can I combine them all into one album?

    I have photos I want to group together in one album, but can't do this because some may have the same number. How can I combine them all into one album? I was trying to move several albums onto a USB drive and it stated all other files exist at this location.  They are pictures taken at different times and have the same number I guess.

    In iPhoto albums may contain photos with the same file name - iPhoto handles that just fine
    If you are exporting them to move somewhere else use the sequential file name feature of export to give each file a unique name
    LN

  • How Do I Combine Several Images Into One Image Which Contains Links To A Series Of Web Sites?

    How do I combine several images into one such that the combined image contains a series of web links? In particular, I’d like to create such an image and put it into my Outlook email signature. At present, as per the image below, I have at least six separate images in my email signature with each image containing a web link. Is Photoshop the best tool for this job? Or would it be easier to do this in some other package? I have three packages at my disposal: Photoshop, Ilustrator and Dreamweaver. Can someone please explain in detail how I would do this? Or perhaps someone could direct me to a link that explains how to do this. Thank you.

    Thank you for that correction, Hobotor. I admit I hadn't thought about an image map, in the context of someone who doesn't seem to know HTML very well...  My thinking was running along the use of the Photoshop Slice Tool to get most of the way there...
    To expand on the above, if you were to slice up your image using the Slice Tool, say like this:
    Save for Web & Devices will create the HTML and save all the sub-images.
    Then you edit the HTML and add a (hypertext link) elements surrounding the various images.  Only thing is you'll have to set the border-style of the images to none.
    For example:
    <!-- Save for Web Slices () -->
    <table id="Table_01" width="554" border="0" cellpadding="0" cellspacing="0">
    <tr>
      <td colspan="10">
       <img id="Sig_01" style="border-style:none" src="images/Sig_01.jpg" width="554" height="56" alt="" /></td>
    </tr>
    <tr>
      <td colspan="10">
       <a href="http://www.GrahamsWebSite.com"><img id="Sig_02" style="border-style:none" src="images/Sig_02.jpg"
            width="554" height="43" alt="" /></a></td>
    </tr>
    etc.
    A full copy of the HTML and images can be found here...  View Source to see it as an example:
    http://Noel.ProDigitalSoftware.com/temp/Graham/Sig.html
    -Noel

  • HT5538 how can I transfer several apps from one Apple ID to another?

    How can I transfer several apps from one Apple ID to another?

    Apps purchased by an Apple ID are forever associated with that ID.    Purchases can't be transfers to another Apple ID.

  • How can i creat several rectangles with one draw rect.vi

    how can i creat several rectangles with one draw rect.vi? thanks
    Solved!
    Go to Solution.

    You can call it in a for loop, with an array of the rectangle coordinates you want to draw. Is this what you mean?
    CLA, LabVIEW Versions 2010-2013
    Attachments:
    rectangle.png ‏11 KB

  • I have three different ipods with music on them and have had to replace our computer as it was in a fire. How can we combine the ipods into one ipod.

    We had to replace our computer due to a fire and lost many of the fiels which were on them. Many were music files for the ipods, we have thre. Also, do not have ID's and passwords to the iTunes store.
    How can we combine the information so that they are all in each one or at least compbine everything into one ipod?

    Just so you know the method suggested by Nelsonleee will cost your $29.95 USD, Yamipod is free.

  • How do I combine several pdfs into one document?

    I just switched to Yosemite, and now I cannot figure out how to combine several pdfs into one document. I rarely need to do this, so I looked at past tutorials, but nothing seems to work. Help!

    I don't understand - I've just tried it and it worked. I had 2 multi-page pdfs, opened both in Preview, followed my earlier post and saved the new pdf. The saved file is multi-page
    Odd

  • How can I combine 3 pictures in one using ligthroom

    How can I combine 3 pictures in one

    It will be necessary for you to send them to an external editor such as Photoshop or Photoshop Elements. Lightroom does not have that capability on its own.

  • How can I combine several Library Bundles?

    I updated my Projects and Events in 3 stages with the (unexpected by me)  result that I now have 3 separate Libraries on my WD 2TB drive (see screenshot).
    I would like to consolidate/combine them into the original "WD 2TB's projects and events"  Library but can't find any way of doing it.

    afai understand the concept, you don't/can not combine Libraries, but its contents.
    So, when the process of updating your yet material lead to three libs, you can only drag the CONTENT of lib2 + 3 into lib1. Content is Events and Projects and perhaps single files.
    After doing so, lib2 and 3 get obsolete. And could be erased.
    … what I can not answer: How can you be sure, the REAL content was moved, and not just hard-links?
    … in Finder, those hard-links/symLinks look&feel the same as the real file...
    Perhaps, you should do a backup first, try it with one Lib first, erase it, and look, what happens.
    You're my guinea pig! I haven't updated my Libs yet… and I do have some 'smart' scheme: Each Event is one game-day = simple. Each Project shows this game-day = simple. BUT each Project uses material from some 'generic Event' = should be simple too. And I'm using e.g. 'graphics' outside FinalCut, in my 'Pictures' folder. AND I do have some Events containing the real files, and I do have Events containing just links to some sources (=back-up copies of media) on other drives... having here 4TB of data makes it a bit 'unrealistic' to work with back-ups… keeping in mind I want to update before end of 2014 ....
    In theory, the actual Lib/Events/Project scheme exactly hits my personal needs. But will the update 'understand' my manual scheme, I did establish the last 2years........ ?
    My plan is: a Lib per season/One Event per game, containing material from 3-6 cams/ 1 game = 1 project. And one Lib containing 'shared' media in use for all game-reports …
    fingers crossed...
    … and what will happen, when 'our Doc' from India discovers this new scheme?
    Cupertino should use him and his arrays-of-drive-clones as 'worst case scenario' ...
    if FCPX manages to handle that, it handles everything!
    (no offense meant, somana!)

  • How can i send several emails at one time

    Im trying to send an email out to several addresses and im getting a mailer demon message. How can i send this one email to several addresses?

    How many addresses are you trying to send to at once? Normally you can send a message to a reasonable number of recipients at once, but your mail provider may impose limitations.
    What does the mailer message say? Is it bouncing on a specific email address? (In which case, make sure you typed it correctly)
    Matt

  • How can I have several products in one order (eg: prints + albums)?

    I'd like to order prints and several albums. But I don't want to make 2 or 3 seperate orders, I'd like to have one shipment, which presumably will save some shipping costs. There doesn't seem to be a "shopping cart" where I can add my prints, then my albums and then order everything in one go. But I find it suprising that someone at Apple hasn't thought of that. Help please!

    No. Multiple copies of one order can be combined, but not multiple orders.

  • How can i combine several backups together to restore my phone?

    I had two iphones and i am needing to put the back ups all on the same phone. How do i do this?

    You cannot.

  • How can I combine multiple calendars into one calendar?

    I've been using iCal for a very long time, upgraded to iCloud, when it was fully operational.  In addition to my personal calendar, I have used several different calendars for different kinds of  business activities.  However, I am not at a point, where tracking different business related activites is no longer necessary.  So, I would like to know how to combine all the unnecessary calendars into a single business calendar.  I want to be able to transfer my entire calendar history from all the calendars to a single calendar.
    Thanks in advance for your recommendations.

    For each calendar, from the File menu choose 'Export...' then 'Export...'; from the sub-menu. This will create an .ics file at the location chosen in the Export dialog.
    From the File menu choose 'Import...' then 'Import...' from the sub-menu. A navigation pane will open: navigate to and choose your exported .ics file.
    You will get a pane with a drop-down menu - choose the calendar you want to add this data to.
    Be aware that this procedure can't be undone.

Maybe you are looking for