-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path01. Queries - Examples in Ledger
48 lines (24 loc) · 1.73 KB
/
01. Queries - Examples in Ledger
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
Selecting all Ledger names
Select * from Ledger
Select $Name from Ledger
Ledger name with GSTIN
Select $Name, $PARTYGSTIN from ledger
Select $Name, $PARTYGSTIN from ledger where $Parent Like "%Sundry Debtors%"
Select $Name, $Parent, $PARTYGSTIN from ledger where $Parent Like "%Sundry Debtors%"
Select $Name, $Parent, $PARTYGSTIN from ledger where $Parent Like "%Sundry creditors"
Select $Name, $Parent, $PARTYGSTIN from ledger where $Parent Like "%Sundry creditors%" or $Parent Like "%Sundry Debtors%"
Select $Name, $Parent, $PARTYGSTIN from ledger where $Parent Like "%Sundry creditors%" or $Parent Like "%Sundry Debtors%" and $PartyGSTIN is not null
Select $Name, $Parent, $PARTYGSTIN from ledger where $Parent Like "%Sundry creditors%" or $Parent Like "%Sundry Debtors%" and $PartyGSTIN is null
Select $Name, $Parent, $_PrimaryGroup, $ClosingBalance from ledger
SELECT $Name, $ClosingBalance FROM Ledger WHERE $$IsDr:$ClosingBalance
Select $Name, $Parent, $_PrimaryGroup, $$AscrAmt:$ClosingBalance from ledger
Select $Name, $Parent, $_PrimaryGroup, $$AscrAmt:$ClosingBalance as Closing_Balance from ledger
***String Start with the word Sundry Creditors
Select $Name, $Parent, $PARTYGSTIN from ledger where $Parent Like "%Sundry creditors"
***String is contains the word Sundry Creditors
Select $Name, $Parent, $PARTYGSTIN from ledger where $Parent Like "%Sundry creditors%"
***String end with the word Sundry Creditors
Select $Name, $Parent, $PARTYGSTIN from ledger where $Parent Like "Sundry creditors%"
***String is contains the word S any where in the parent string
Select $Name, $Parent, $PARTYGSTIN from ledger where $Parent Like "%S%"
Select $Name, $Parent, $_PrimaryGroup, $OpeningBalance, $ClosingBalance, $Isrevenue from ledger