2

I like to know the proper way to give credit to another answer or a source (bibliography). Especially when we used them indirectly.

When answering a question especially on Stack Overflow, we might have to study (research) other sources, questions, and answers which are not directly related to the question, but they might help us build our own answer. We might even have to learn a few things along the way.

Therefore, when answering, if we have learned & studied some stuff and used them indirectly to build our own answer or a part of the answer (learning the methods and use it in our own way to answer the question), should we give credit to those sources? If so, what is the proper way/format to do it in the Stack Exchange community?

For example, refer to this piece of code:

WITH cte AS
(   SELECT column1, 
           column2, 
           column3,
           column4,
           columnN      
    FROM   table 
        ๐—จ๐—ก๐—ฃ๐—œ๐—ฉ๐—ข๐—ง ( ๐—ฐ๐—ผ๐—น๐˜‚๐—บ๐—ป๐Ÿฎ 
                ๐—™๐—ข๐—ฅ ๐—ฐ๐—ผ๐—น๐˜‚๐—บ๐—ป๐—ก๐—ฎ๐—บ๐—ฒ๐˜€ ๐—œ๐—ก (๐—ฐ๐—ผ๐—น๐˜‚๐—บ๐—ป๐˜€...) ) ๐˜‚๐—ป๐—ฝ๐˜ƒ๐˜ 
    GROUP  BY conditions... ) 


SELECT * 
FROM   cte 
WHERE  someconditions...
ORDER  someconditions...

If I write this code to answer a question on Stack Overflow, but some part (unpivot) were studied/learned from another question (not related to the original question), what is the proper way to give credit to those sources?

In some cases, we may have to refer many sources just to learn a new method. In these situations, it might not even practical to give credits to all the sources. What should we do then?

Note: References and bibliographies are different. According to Massey University article,

Reference lists contain a complete list of all the sources (books, journal articles, websites, etc.) that you have cited directly in a document. That means that if there are in-text citations for a source there is a reference list entry, and vice versa.

Bibliographies, on the other hand, contain all sources that you have used, whether they are directly cited or not. A bibliography includes sources that you have used to generate ideas or โ€˜read aroundโ€™ a topic, but have not referred to directly in the body of the document.

Reference: http://owll.massey.ac.nz/referencing/reference-list-vs-bibliography.php

5
  • 3
    This is confusing, why do you need a Bibliography? a link to your source(s) will suffice, in the answer you used them, no need for anything more. This may help you: meta.stackexchange.com/questions/94022/…
    – Mark Kirby
    Commented May 4, 2018 at 17:42
  • 1
    If you have hyperlinks you can just use them to build that up, if you don't have any, cite like done in Wikipedia articles. There's no established form at Stack Exchange AFAIK. Or are you asking how you should best format these? Commented May 4, 2018 at 18:02
  • 1
    @MarkKirby "why do you need a Bibliography?" To prevent being accused about plagiarism most probably. Commented May 4, 2018 at 18:03
  • 2
    "Bibliography" is not a verb. The word you're looking for is "cite". Possibly "reference".
    – ale
    Commented May 4, 2018 at 18:14
  • 1
    Related: Is it unethical to post code in answers without citing sources?
    – ale
    Commented May 4, 2018 at 18:17

1 Answer 1

6

There's not really an established or correct way to do so. The important thing is that you should give a link to another (Stack Overflow) answer, you have used to build yours, or to provide a bibliographical reference as i.e. done with Wikipedia articles.

As mentioned there isn't really an established format AFAIK, but you can use a number of markup supported HTML tags to setup your references section:

  • <sup> can be used to render superscript text:

    some text<sup>1</sup>
    

    renders as
    some text1

  • <a> can be used to setup external links within the answer:

    This is the Meta Stack Exchange <strong>Formatting Sandbox</strong><sup>
    <a href="https://meta.stackexchange.com/questions/3122/formatting-sandbox">2
    </a></sup>
    

    renders as
    This is the Meta Stack Exchange Formatting Sandbox 2

  • You can use a horizontal ruler --- (at least 3 -)

    ---
    

    to segregate your references section (as shown below)

  • <sub> can be used for subscript text in reference section to make them less prominent in your answer:

    <sub>Subscript text</sub>
    

    renders as
    Subscript text

  • For citing in general you can refer to the Wikipedia style in general3

You can take a look at the markup used in this answer by clicking the [edit] link below.

Note:

On page hyperlinks like <a href="#ref1" /> => <a name="ref1" /> aren't available with the restricted HTML tag and attributes subset supported with markup language.


Reference section:

1)Simple unlinked footnote
2)Formatting Sandbox
3)Taken from the Wikipedia article Page semi-protected Wikipedia:Citing Wikipedia

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .