<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: hi doubt regarding select statement in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299746#M502494</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Surya,&lt;/P&gt;&lt;P&gt;    Select * from dbase table will select all records from the data base based on the where condition given.&lt;/P&gt;&lt;P&gt; When we use Distict&lt;/P&gt;&lt;P&gt; SINGLE is not specified and if columns does not contain only aggregate expressions, the resulting set has multiple lines. All database lines that are selected by the remaining additions of the SELECT command are included in the resulting list. If the ORDER BY addition is not used, the order of the lines in the resulting list is not defined and, if the same SELECT command is executed multiple times, the order may be different each time. A data object specified after INTO can be an internal table and the APPENDING addition can be used. If no internal table is specified after INTO or APPENDING, the SELECT command triggers a loop that has to be closed using ENDSELECT. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If multiple lines are read without SINGLE, the DISTINCT addition can be used to exclude duplicate lines from the resulting list. If DISTINCT is used, the SELECT command circumvents SAP buffering. DISTINCT cannot be used in the following situations: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If a column specified in columns has the type STRING, RAWSTRING, LCHAR or LRAW &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the system tries to access pool or cluster tables and single columns are specified in columns. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Sarath&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 23 May 2007 08:43:00 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-05-23T08:43:00Z</dc:date>
    <item>
      <title>hi doubt regarding select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299740#M502488</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi experts,&lt;/P&gt;&lt;P&gt;                I have doubt regarding select statement.&lt;/P&gt;&lt;P&gt;                1)If i use SELECT * FROM &amp;lt;DBTAB&amp;gt;&lt;/P&gt;&lt;P&gt;                All the columns are selected&lt;/P&gt;&lt;P&gt;                My doubt is all the lines of the &amp;lt;DBTAB&amp;gt; are selected or not?&lt;/P&gt;&lt;P&gt;                2)If i use SELECT DISTINCT  * FROM &amp;lt;DBTAB&amp;gt; &lt;/P&gt;&lt;P&gt;                  all the lines and all columns of &amp;lt;DBTAB&amp;gt; are selected or not?&lt;/P&gt;&lt;P&gt;                  Then if i remove DISTINCT addition in the above statement what is the result?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 May 2007 08:30:15 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299740#M502488</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-23T08:30:15Z</dc:date>
    </item>
    <item>
      <title>Re: hi doubt regarding select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299741#M502489</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;you will get the same result i.e all columns are selected.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2)If i use SELECT DISTINCT * FROM &amp;lt;DBTAB&amp;gt;&lt;/P&gt;&lt;P&gt; gives the same result because there are no duplicates in a database table.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 May 2007 08:32:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299741#M502489</guid>
      <dc:creator>dev_parbutteea</dc:creator>
      <dc:date>2007-05-23T08:32:20Z</dc:date>
    </item>
    <item>
      <title>Re: hi doubt regarding select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299742#M502490</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;      In the first case it will select all the entries from all fields in the table..Means you will get a clear replica of your table in your internal table...Select Distinct you can restrict table entries accordingly...If you are removing the Distinct addition the same thing will happen as of No.1....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward All Helpfull Answers.........&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 May 2007 08:34:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299742#M502490</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-23T08:34:51Z</dc:date>
    </item>
    <item>
      <title>Re: hi doubt regarding select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299743#M502491</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1.All the lines are selected from the Database in the First Statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2.Ths Select Distinct is used to exclude Duplcate Entries.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Padmam.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 May 2007 08:35:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299743#M502491</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-23T08:35:55Z</dc:date>
    </item>
    <item>
      <title>Re: hi doubt regarding select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299744#M502492</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;answers:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; 1) select * from tab&lt;/P&gt;&lt;P&gt;     all the lines are selected.&lt;/P&gt;&lt;P&gt;     number of the lines selected is equal to the number of entries present in the table no matter if the entries are repeated or not.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; 2) select distinct * from tab.&lt;/P&gt;&lt;P&gt;     here also, all the lines are selected, but duplicate entries are selected only once.&lt;/P&gt;&lt;P&gt;     if there are two or more similar entries, only once it will be selected. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks,&lt;/P&gt;&lt;P&gt;viji.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 May 2007 08:36:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299744#M502492</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-23T08:36:52Z</dc:date>
    </item>
    <item>
      <title>Re: hi doubt regarding select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299745#M502493</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Surya,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. The number of lines selected from database table depends on the conditions provided in the WHERE clause. If nothing is mentioned, then all records are fetched.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. If you say select DISTINCT for a field, all the records for different values for that field are selected. If you remove this DISTINCT, then you get multiple records for the same value of the field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Raj&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 May 2007 08:37:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299745#M502493</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-23T08:37:26Z</dc:date>
    </item>
    <item>
      <title>Re: hi doubt regarding select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299746#M502494</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Surya,&lt;/P&gt;&lt;P&gt;    Select * from dbase table will select all records from the data base based on the where condition given.&lt;/P&gt;&lt;P&gt; When we use Distict&lt;/P&gt;&lt;P&gt; SINGLE is not specified and if columns does not contain only aggregate expressions, the resulting set has multiple lines. All database lines that are selected by the remaining additions of the SELECT command are included in the resulting list. If the ORDER BY addition is not used, the order of the lines in the resulting list is not defined and, if the same SELECT command is executed multiple times, the order may be different each time. A data object specified after INTO can be an internal table and the APPENDING addition can be used. If no internal table is specified after INTO or APPENDING, the SELECT command triggers a loop that has to be closed using ENDSELECT. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If multiple lines are read without SINGLE, the DISTINCT addition can be used to exclude duplicate lines from the resulting list. If DISTINCT is used, the SELECT command circumvents SAP buffering. DISTINCT cannot be used in the following situations: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If a column specified in columns has the type STRING, RAWSTRING, LCHAR or LRAW &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the system tries to access pool or cluster tables and single columns are specified in columns. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Sarath&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 May 2007 08:43:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299746#M502494</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-23T08:43:00Z</dc:date>
    </item>
    <item>
      <title>Re: hi doubt regarding select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299747#M502495</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Surya,&lt;/P&gt;&lt;P&gt;If you use SELECT * FROM &amp;lt;DBTAB&amp;gt; all the lines of the &amp;lt;DBTAB&amp;gt; are selected.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you use SELECT DISTINCT * FROM &amp;lt;DBTAB&amp;gt; duplicates will not be selected.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;that means if some data is repeated it will not show the data twice.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ex: if 21 is there 2 times it will show only one time&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 May 2007 08:45:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299747#M502495</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-23T08:45:20Z</dc:date>
    </item>
    <item>
      <title>Re: hi doubt regarding select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299748#M502496</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1&amp;gt; Select * selects all the columns as well as rows from &amp;lt;DBTAB&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2&amp;gt;Select DISTINCT fetches unique records .but it is normally followed by a where clause.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;eg..I wish to retrive the DISTINCT "cities'" from EMP table..THe same city might be repeated for employees..but it will fetch the different cities with none repeated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Dev&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 May 2007 08:52:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299748#M502496</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-23T08:52:03Z</dc:date>
    </item>
    <item>
      <title>Re: hi doubt regarding select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299749#M502497</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. All lines of DBtab will be selected unless condition specified in where clause.&lt;/P&gt;&lt;P&gt;2. With distinct * clause  it will show distinct RECORD, with only * it will give all records.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Jogdand M B&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 May 2007 08:52:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299749#M502497</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-23T08:52:38Z</dc:date>
    </item>
    <item>
      <title>Re: hi doubt regarding select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299750#M502498</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Surya,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1.Ths Select Distinct  show only single value , remove duplicate entries.&lt;/P&gt;&lt;P&gt;2.All the lines are selected from the Database in the First Statement.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 May 2007 09:15:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/hi-doubt-regarding-select-statement/m-p/2299750#M502498</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-23T09:15:58Z</dc:date>
    </item>
  </channel>
</rss>

