10. Parameters in Power Query (and Other Kinds of Parameters)
Now a small but very useful topic – Parameters (a changeable value that you can use in many places). If you hard-code the file path, server name or date range, the report breaks on another laptop. In this module we make parameters, use them in M, and see the basics of templates and incremental refresh in very simple words.
आता एक छोटा पण खूप उपयोगी topic – Parameters (बदलता येणारं मूल्य, जे अनेक ठिकाणी वापरता येतं). File path, server name, date range हे सगळं hard-code केलं तर दुसऱ्या laptop वर report तुटतो. या module मध्ये parameters बनवणं, M मध्ये वापरणं, templates आणि incremental refresh चे basics अगदी सोप्या भाषेत बघू.
अब एक छोटा पर बहुत काम का topic – Parameters (बदला जा सकने वाला मान, जो कई जगह इस्तेमाल होता है). File path, server name, date range यह सब hard-code किया तो दूसरे laptop पर report टूट जाती है. इस module में parameters बनाना, M में इस्तेमाल करना, templates और incremental refresh के basics बिल्कुल आसान भाषा में देखेंगे.
What you will learn in this module
- Creating and managing Power Query parameters: types, suggested values, lists, queries
- Parameterising a file/folder path and a server/database name (Dev → Prod)
- Date-range parameters for filtering (with query folding)
- Using parameters inside M code and changing them in Desktop and the Service
- Templates (.pbit) that ask for parameter values
- Incremental refresh with RangeStart/RangeEnd (overview)
- How what-if and field parameters differ (they are covered in Module 21)
Live story: One report, many cities
Suppose the same report must run for Pune today and for Nagpur tomorrow. Changing the file path or the city in ten places is slow and risky. A parameter is one setting that every query reads. This chapter builds Power Query parameters, What-if parameters and field parameters.
All numbers in this story are fictional practice data.
Live story: एक report, अनेक शहरं
समजा तोच report आज Pune साठी आणि उद्या Nagpur साठी चालला पाहिजे. File path किंवा शहर दहा ठिकाणी बदलणं वेळखाऊ आणि धोक्याचं आहे. Parameter म्हणजे एक setting जी प्रत्येक query वाचते. हा chapter Power Query parameters, What-if parameters आणि field parameters बनवतो.
या story मधले सगळे आकडे काल्पनिक practice data आहेत.
Live story: एक report, कई शहर
मान लीजिए वही report आज Pune के लिए और कल Nagpur के लिए चलनी चाहिए. File path या शहर दस जगह बदलना धीमा और जोखिम भरा है. Parameter एक setting है जिसे हर query पढ़ती है. यह chapter Power Query parameters, What-if parameters और field parameters बनाता है.
इस story के सारे आँकड़े काल्पनिक practice data हैं.
Concepts in this chapter
- 10.1What Is a Parameter and Why Use It?
- 10.2Creating a Parameter (Manage Parameters Dialog)
- 10.3Parameterising a File or Folder Path
- 10.4Parameterising Server and Database (Dev → Prod)
- 10.5Date-range Parameters for Filtering
- 10.6Using Parameters Elsewhere in M
- 10.7Templates (.pbit) with Parameters
- 10.8Incremental Refresh with RangeStart and RangeEnd (Overview)
- 10.9What-if Parameters and Field Parameters Are Different
The chapter recap is at the end of the last concept page.
Ravi Sir's Cards: 13 revision, interview and comparison cards for this chapter · मराठी cards